Architecting Cloud Native Applications
上QQ阅读APP看书,第一时间看更新

Data life cycle

Another useful strategy for decomposing a system into components is based on the life cycle of the data in the system. This is similar in concept to dividing the system based on the value streams or business processes of the system, but stretches out over a longer period. For example, how long must data be retained before it can be deleted? Data may have to live long after a business process or value stream is complete. A case in a case management system is created, assigned, and ultimately completed, but the records of the case will need to be retained and managed for an extended period. A product in an e-commerce system is authored, published, offered, sold, and discontinued, but so long as a customer still owns the product there is still a reason to keep the product detail information available. Furthermore, as the data moves through its life cycle, it may be best to store the data in different formats and in different types of storage. Retention policies may vary between different stages of the life cycle, such as allowing high transaction volume stages to purge old data to free up resources and improve performance. Each stage in the data life cycle will typically be its own component, with different requirements and a different user base. The data will flow through these stages and components based on the life cycle events that are published as the data ages.