Closed mxsm closed 4 months ago
The changes optimize RocketMQ's message-pulling process. A new boolean flag notify_message_arrive_in_batch
has been introduced in multiple structs to control batch notifications for message arrival. Additionally, a helper function is_lmq
and other constants have been added for better metadata and group topic handling. These modifications enhance overall efficiency and functionality in message processing and notifying.
File/Module | Change Summary |
---|---|
rocketmq-broker/src/broker_runtime.rs |
Added a new boolean argument false to a function call in BrokerRuntime . |
rocketmq-common/src/common/mix_all.rs |
Introduced is_lmq function and corresponding test cases. |
rocketmq-store/src/message_store/default_message_store.rs |
Added imports, new field notify_message_arrive_in_batch , updated constructors, and methods to handle this new field. |
sequenceDiagram
participant Client
participant BrokerRuntime
participant DefaultMessageStore
participant ReputMessageService
Note over Client: Enhanced Pull Message Flow
Client->>BrokerRuntime: Request messages
BrokerRuntime->>DefaultMessageStore: Fetch messages (with notify_message_arrive_in_batch)
DefaultMessageStore-->>ReputMessageService: Notify message arrival
ReputMessageService-->>DefaultMessageStore: Batch process based on notify_message_arrive_in_batch
DefaultMessageStore->>BrokerRuntime: Return messages
BrokerRuntime->>Client: Deliver messages
Objective | Addressed | Explanation |
---|---|---|
Optimize pull message process (#729) | ✅ |
In RocketMQ's grand domain,
Optimized paths now reign,
Messages pull with ease,
Batching brings the breeze,
Brokers and stores align,
Efficiency we enshrine.
Code evolved, a pure gain.
[!TIP]
AI model upgrade
## `gpt-4o` model for reviews and chat is now live OpenAI claims that this model is better at understanding and generating code than the previous models. Please join our [Discord Community](https://discord.com/invite/GsXnASn26c) to provide any feedback or to report any issues.
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
🚀Thanks for your contribution🎉. CodeRabbit(AI) will review your code first🔥
Which Issue(s) This PR Fixes(Closes)
Fixes #729
Brief Description
How Did You Test This Change?
Summary by CodeRabbit
New Features
notify_message_arrive_in_batch
to enhance message arrival notifications in batch mode.Improvements
DefaultMessageStore
to accommodate batch message notifications.ReputMessageService
to support the new message notification feature.Bug Fixes