Allenhuangrui opened a new pull request, #11624: URL: https://github.com/apache/rocketmq/pull/11624
### Which Issue(s) This PR Fixes Fixes #11623 ### Brief Description Allow proxy integrations to propagate optional consumer metadata through heartbeat synchronization without duplicating the heartbeat sender/receiver or overloading protocol-specific channel data. - Add an optional `Map<String, String> extInfo` to `HeartbeatSyncerData`. - Add optional sender and receiver callbacks, configurable through `HeartbeatSyncer` and `ClusterConsumerManager`. The sender runs before broadcasting registration/unregistration; the receiver runs on the actual cached or newly decoded `RemoteChannel` before consumer registration/unregistration. - Log callback exceptions and continue the existing heartbeat operation. Existing constructors and the behavior with no callbacks remain unchanged. Messages without extensions remain supported, and the core does not interpret extension keys. ### How Did You Test This Change? - Ran the 9 new tests in `HeartbeatSyncerDataTest` and `HeartbeatSyncerExtInfoTest` in a remote Kubernetes test environment on JDK 21, using the available dependency classpath. All passed. - Covered extension round trips, legacy messages without extensions, cached-channel reuse, callback ordering for registration/unregistration, failure isolation, self-broadcast filtering, and manager callback configuration. - Compiled the changed production classes with `javac --release 8`. - Checked all five changed/new Java files with the repository's `style/rmq_checkstyle.xml` (Checkstyle 9.3); no violations. `git diff --check` also passed. The full Maven reactor build and a live multi-proxy rollout have not been run for this upstream change. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
