# I am the Watcher. I am your guide through this vast new twtiverse.
# 
# Usage:
#     https://watcher.sour.is/api/plain/users              View list of users and latest twt date.
#     https://watcher.sour.is/api/plain/twt                View all twts.
#     https://watcher.sour.is/api/plain/mentions?uri=:uri  View all mentions for uri.
#     https://watcher.sour.is/api/plain/conv/:hash         View all twts for a conversation subject.
# 
# Options:
#     uri     Filter to show a specific users twts.
#     offset  Start index for quey.
#     limit   Count of items to return (going back in time).
# 
# twt range = 1 1
# self = https://watcher.sour.is/conv/proqxaa
StampedLock,一種比讀寫鎖更快的鎖!**
01、背景介紹-------在上一篇文章中,我們講到了使用ReadWriteLock可以解決多線程同時讀,但只有一個線程能寫的問題。如果繼續深入的分析ReadWriteLock,從鎖的角度分析,會發現它有一個潛在的問題:如果有線程正在讀數據,寫線程準備修改數據的時候,需要等待讀線程釋放鎖後才能獲取寫鎖,簡單的說就是,讀的過程中不允許寫,這其實是一種悲觀的讀鎖。爲了進一步的提升程序併發執行效率,Ja ⌘ Read more