Abstract:For the problem of data consistency in the construction of distributed micro-services, this paper summarizes the principles of data consistency in the process of distributed computing, analyzes the importance of idempotent design for realizing micro-services, and proposes a method of using transactional message queue to solve the problem of data consistency in typical application scenarios of distributed micro-services, and gives RocketMQ implementation method and principle. Experiments show that transactional messages can better solve the problem of distributed data consistency. Finally, the advantages and disadvantages of the above methods are analyzed. The data consistency processing method proposed in this study can be used for reference in the construction of distributed micro-services.