Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add attributesBuilderSupplier for BrokerMetricsManager #6901

Merged
merged 3 commits into from
Jun 15, 2023

Conversation

drpmma
Copy link
Contributor

@drpmma drpmma commented Jun 14, 2023

Which Issue(s) This PR Fixes

Fixes #6900

Brief Description

Add attributesBuilderSupplier for BrokerMetricsManager for the extension.

How Did You Test This Change?

Unit test

Copy link
Contributor

@xdkxlk xdkxlk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@codecov-commenter
Copy link

Codecov Report

Merging #6901 (1d2771e) into develop (aaa4a4b) will increase coverage by 0.01%.
The diff coverage is 100.00%.

❗ Current head 1d2771e differs from pull request most recent head af9ae23. Consider uploading reports for the commit af9ae23 to get more accurate results

@@              Coverage Diff              @@
##             develop    #6901      +/-   ##
=============================================
+ Coverage      42.64%   42.66%   +0.01%     
- Complexity      9106     9109       +3     
=============================================
  Files           1127     1127              
  Lines          79942    79944       +2     
  Branches       10392    10392              
=============================================
+ Hits           34094    34107      +13     
+ Misses         41572    41563       -9     
+ Partials        4276     4274       -2     
Impacted Files Coverage Δ
.../rocketmq/broker/metrics/BrokerMetricsManager.java 12.23% <100.00%> (+0.54%) ⬆️

... and 26 files with indirect coverage changes

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@ferrirW
Copy link
Contributor

ferrirW commented Jun 14, 2023

What are the benefits?

@drpmma
Copy link
Contributor Author

drpmma commented Jun 15, 2023

What are the benefits?

It is merely for the sake of facilitating the expansion of the attributesBuilderSupplier. Furthermore, it has already been present within the codebase.

For instance, consider

public class PopMetricsManager {
public static Supplier<AttributesBuilder> attributesBuilderSupplier;
and
public class DefaultStoreMetricsManager {
public static Supplier<AttributesBuilder> attributesBuilderSupplier;

Simply perform the identical action for the BrokerMetricsManager.

@drpmma drpmma merged commit 2246c32 into apache:develop Jun 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Enhancement] Add attributesBuilderSupplier for BrokerMetricsManager
4 participants