Microservice Patterns - 用 Saga 管理交易 - 4.3 處理缺乏隔離性的問題
參考資料 https://www.amazon.com/Microservices-Patterns-examples-Chris-Richardson/dp/1617294543 ACID 交易的隔離性確保同時執行多個交易的結果,跟以某種串行順序執行它們的結果相同 隔離性讓撰寫同時執行...
參考資料 https://www.amazon.com/Microservices-Patterns-examples-Chris-Richardson/dp/1617294543 ACID 交易的隔離性確保同時執行多個交易的結果,跟以某種串行順序執行它們的結果相同 隔離性讓撰寫同時執行...
Reference https://www.amazon.com/Microservices-Patterns-examples-Chris-Richardson/dp/1617294543 Sagas process Saga init by system command Coordina...
參考資料 https://www.amazon.com/Microservices-Patterns-examples-Chris-Richardson/dp/1617294543 Saga 流程 Saga 由系統命令啟動 協調邏輯選擇並告訴第一個 Saga 參與者執行本地交易 完成後,...
Reference https://www.amazon.com/Microservices-Patterns-examples-Chris-Richardson/dp/1617294543 Challenges In a monolithic system, a createOrder oper...
參考資料 https://www.amazon.com/Microservices-Patterns-examples-Chris-Richardson/dp/1617294543 挑戰 在單體系統中,createOrder 操作只需要依賴帶有 transactional annotation 的...
Introduction One day, Cassandra stop listening for thrift client until restart it manually. After checking Cassandra log, found it encountered OutOfMemory...
前言 某天,Cassandra 停止監聽 thrift client 的連線,直到手動重啟才恢復。 檢查 Cassandra log 之後,發現遇到了 OutOfMemoryError ERROR [Thrift-Selector_27] 2020-03-31 06:00:44,020 TDisrupt...
Reference https://www.amazon.com/Microservices-Patterns-examples-Chris-Richardson/dp/1617294543 synchronous communication with other services as part ...
參考資料 https://www.amazon.com/Microservices-Patterns-examples-Chris-Richardson/dp/1617294543 在處理請求時與其他服務做同步通訊會降低應用程式的可用性 因此,你應該盡可能設計服務使用非同步 messaging ...
Reference Notes 應該 知道該停止做甚麼 => 認清沉沒成本, 勇敢不做 調整成中立的 => 不用當混蛋, 不用太討好人. 甚麼都不做 不該 贏太多 => 太專注於贏別人 加值過度 => 聽到好的提案, 應該說謝謝以及考慮執行, 不用再加上自己的...
參考資料 筆記 應該 知道該停止做甚麼 => 認清沉沒成本, 勇敢不做 調整成中立的 => 不用當混蛋, 不用太討好人. 甚麼都不做 不該 贏太多 => 太專注於贏別人 加值過度 => 聽到好的提案, 應該說謝謝以及考慮執行, 不用再加上自己的意見, 以為會讓...
Reference https://www.amazon.com/Microservices-Patterns-examples-Chris-Richardson/dp/1617294543 Using a message broker broker-based architecture b...
參考資料 https://www.amazon.com/Microservices-Patterns-examples-Chris-Richardson/dp/1617294543 使用 Message Broker 基於 broker 的架構 基於 brokerless 的 messagi...
Reference https://www.amazon.com/Microservices-Patterns-examples-Chris-Richardson/dp/1617294543 Pattern: Messaging A client invokes a service us...
參考資料 https://www.amazon.com/Microservices-Patterns-examples-Chris-Richardson/dp/1617294543 Pattern: Messaging Client 使用非同步 messaging 來呼叫服務。參見 ht...
Purpose: Original value is origVal, we want to use increase/decrease to update to a specified number How? origValue = origValue + expectedValue diff...
目的:原始值是 origVal,我們想要透過增加/減少來更新到指定的數字 怎麼做? origValue = origValue + expectedValue diff = expectedValue - origValue origValue = origValue + diff ...
Reference https://www.amazon.com/Microservices-Patterns-examples-Chris-Richardson/dp/1617294543 in order for one service to invoke another service usin...
參考資料 https://www.amazon.com/Microservices-Patterns-examples-Chris-Richardson/dp/1617294543 為了讓一個服務能用 RPI 呼叫另一個服務,它需要知道服務實例的網路位置。=> Service Discovery...
Reference https://www.amazon.com/Microservices-Patterns-examples-Chris-Richardson/dp/1617294543 Remote procedure invocation A client invokes a s...