# 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/afwozpa
Go 命令模式實戰**
隨着分佈式應用越來越廣泛,數據操作的一致性需要由業務方來保證,兩個操作不在同一個事務操作失敗時,無法依靠數據庫事務直接回滾,這時需要業務方手動進行回滾。通過命令模式提供新舊數據初始化後,如果執行後有後續操作失敗,業務方可以通過調用 Undo方法進行回滾,無需再編寫數據庫操作代碼優點是減少了回滾代碼的重複編寫,只要提供新舊數據,通過 Do和 UnDo就可以完成對應操作。並且有些時候可能 Undo 方 ⌘ Read more