RongtongJin opened a new pull request, #9720:
URL: https://github.com/apache/rocketmq/pull/9720

   <!-- Please make sure the target branch is right. In most case, the target 
branch should be `develop`. -->
   
   ### Which Issue(s) This PR Fixes
   
   <!-- Please ensure that the related issue has already been created, and 
[link this pull request to that issue using 
keywords](<https://docs.github.com/en/issues/tracking-your-work-with-issues/linking-a-pull-request-to-an-issue#linking-a-pull-request-to-an-issue-using-a-keyword>)
 to ensure automatic closure. -->
   
   Fixes #9719
   
   ### Brief Description
   
   1. **Convert Static Variables to Instance Variables**
      - Transform all static fields in metrics managers to instance fields
      - Each broker instance will have its own metrics manager instance
      - Remove static method dependencies
   
   2. **Instance-Based Metrics Management**
      - `BrokerMetricsManager` creates and manages individual instances of 
metrics managers
      - Each broker gets its own `RemotingMetricsManager`, `PopMetricsManager`, 
and `RocksDBStoreMetricsManager`
      - Metrics are collected and stored per-broker instance
   
   3. **Dependency Injection Pattern**
      - Pass metrics manager instances to classes that need them
      - Update `NettyRemotingAbstract` to accept `RemotingMetricsManager` 
instance
      - Modify processor classes to use instance-based metrics calls
   
   4. **Interface Updates**
      - Add instance-based methods to `RemotingServer` interface
      - Update `NettyRemotingServer` to delegate to instance methods
      - Maintain backward compatibility where possible
   
   <!-- Write a brief description for your pull request to help the maintainer 
understand the reasons behind your changes. -->
   
   ### How Did You Test This Change?
   
   <!-- In order to ensure the code quality of Apache RocketMQ, we expect every 
pull request to have undergone thorough testing. -->
   


-- 
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]

Reply via email to