-
Notifications
You must be signed in to change notification settings - Fork 62
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
Expose internal statistics of GreedyBalancer
via JMX
#1095
Conversation
common/src/main/java/org/astraea/common/balancer/algorithms/GreedyBalancer.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@garyparrot 感謝實作這個方便的功能
@chaohengstudent 也麻煩看一下,之後Sensor 要能跟 JmX結合
common/src/main/java/org/astraea/common/balancer/algorithms/GreedyBalancer.java
Outdated
Show resolved
Hide resolved
common/src/main/java/org/astraea/common/balancer/algorithms/GreedyBalancer.java
Outdated
Show resolved
Hide resolved
common/src/main/java/org/astraea/common/balancer/algorithms/GreedyBalancer.java
Outdated
Show resolved
Hide resolved
common/src/main/java/org/astraea/common/metrics/jmx/DynamicMbean.java
Outdated
Show resolved
Hide resolved
Failed test traced at #1096. |
Failed test traced at #1096. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@garyparrot 感謝精簡功能,這樣不複雜用符合我們近期的用途,幾個建議請看一下
common/src/main/java/org/astraea/common/metrics/jmx/MBeanRegister.java
Outdated
Show resolved
Hide resolved
common/src/main/java/org/astraea/common/metrics/jmx/MBeanRegister.java
Outdated
Show resolved
Hide resolved
BeanQuery.builder().domainName(domainName).property("id", id).build()); | ||
|
||
// register | ||
MBeanRegister.local() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
麻煩試著用MBeanClient
把剛剛註冊的資訊撈回來比對一下內容
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
PR Context: #1084
Previous Discussion: #1089 (comment)
This PR does the following:
DynamicMbean
to ease the process of publishing an MBean on the local JVM.GreedyBalancer
. Currently, support theiteration
counter andminCost
gauge.