This essay is a follow up introduction on IM Architecutre. We will discuss some common consistency, avilability and partition tolerance issues we face in a multi-datacenter, distributed architecture of the IM system. We will also discuss how we tackle with thess issues in the service implementation to acieve high avaliblity and parition tolerance meanwhile achieving final consistency.
This essay takes me one month to finish writing, drawing figures. I will start from the view of a PM to define what user’s need for a simple instant messaging service as well as the perspective of an SWE to elaborate how to implement these features (backend) in a robust and reliable way.