Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

RocketMQ architecture is mainly divided into several parts.

2025-02-02 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >

Share

Shulou(Shulou.com)06/02 Report--

This article mainly introduces the RocketMQ architecture is mainly divided into several parts, the article is very detailed, has a certain reference value, interested friends must read it!

Technical architecture

The RocketMQ architecture is mainly divided into four parts, as shown in the figure above:

Producer: the role of message publishing, which supports distributed cluster deployment. Producer selects the corresponding Broker cluster queue for message delivery through the load balancing module of MQ. The delivery process supports rapid failure and low latency.

Consumer: the role of message consumption, which supports distributed cluster deployment. Push push and pull pull modes are supported to consume messages. At the same time, it also supports the consumption of cluster mode and broadcast mode, it provides real-time message subscription mechanism, which can meet the needs of most users.

NameServer:NameServer is a very simple Topic routing registry, its role is similar to zookeeper in Dubbo, and supports dynamic registration and discovery of Broker. It mainly includes two functions: Broker management, NameServer accepts the registration information of the Broker cluster and saves it as the basic data of routing information. Then a heartbeat detection mechanism is provided to check whether the Broker is still alive; routing information management, each NameServer will hold the entire routing information about the Broker cluster and queue information for client queries. Then Producer and Conumser can know the routing information of the entire Broker cluster through NameServer, thus delivering and consuming messages. NameServer is also usually deployed in a cluster manner, with no information communication between instances. Broker registers its own routing information with each NameServer, so a complete routing information is stored on each NameServer instance. When a NameServer goes offline for some reason, Broker can still synchronize its routing information to other NameServer, and Producer,Consumer can still dynamically perceive the routing information of Broker.

BrokerServer:Broker is mainly responsible for the storage, delivery and query of messages and the guarantee of high service availability.

Broker, in order to achieve these functions, includes the following important sub-modules.

Remoting Module: the entire Broker entity responsible for processing requests from the clients side.

Client Manager: responsible for managing clients (Producer/Consumer) and maintaining Topic subscription information for Consumer

Store Service: provides a convenient and simple API interface to process messages and store messages to the physical hard disk and query functions.

HA Service: a highly available service that provides data synchronization between Master Broker and Slave Broker.

Index Service: a service to index messages delivered to Broker according to a specific Message key to provide quick query of messages.

The above is all the content of the article "RocketMQ architecture is mainly divided into several parts". Thank you for reading! Hope to share the content to help you, more related knowledge, welcome to follow the industry information channel!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Development

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report