Skip to content

HBASE-27890 Expose a getter on Connection/AsyncConnection for getting… #5257

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

frostruan
Copy link
Contributor

… public access to connection metrics

@frostruan
Copy link
Contributor Author

hi @bbeaudreault

I have completed a simple version. I believe there must be a lot of improvement. If you have time, would you mind taking a look and giving me some comments and suggestions?

@Apache-HBase
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 0s Docker mode activated.
-1 ❌ patch 0m 2s #5257 does not apply to master. Rebase required? Wrong Branch? See https://yetus.apache.org/documentation/in-progress/precommit-patchnames for help.
Subsystem Report/Notes
GITHUB PR #5257
Console output https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-5257/1/console
versions git=2.25.1
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

1 similar comment
@Apache-HBase
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 0s Docker mode activated.
-1 ❌ patch 0m 2s #5257 does not apply to master. Rebase required? Wrong Branch? See https://yetus.apache.org/documentation/in-progress/precommit-patchnames for help.
Subsystem Report/Notes
GITHUB PR #5257
Console output https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-5257/1/console
versions git=2.25.1
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 0s Docker mode activated.
-1 ❌ patch 0m 3s #5257 does not apply to master. Rebase required? Wrong Branch? See https://yetus.apache.org/documentation/in-progress/precommit-patchnames for help.
Subsystem Report/Notes
GITHUB PR #5257
Console output https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-5257/1/console
versions git=2.17.1
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase
Copy link

🎊 +1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 28s Docker mode activated.
_ Prechecks _
+1 💚 dupname 0m 0s No case conflicting files found.
+1 💚 hbaseanti 0m 0s Patch does not have any anti-patterns.
+1 💚 @author 0m 0s The patch does not contain any @author tags.
_ master Compile Tests _
+0 🆗 mvndep 0m 14s Maven dependency ordering for branch
+1 💚 mvninstall 2m 58s master passed
+1 💚 compile 3m 8s master passed
+1 💚 checkstyle 0m 48s master passed
+1 💚 spotless 0m 44s branch has no errors when running spotless:check.
+1 💚 spotbugs 2m 15s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 10s Maven dependency ordering for patch
+1 💚 mvninstall 2m 41s the patch passed
+1 💚 compile 3m 5s the patch passed
+1 💚 javac 3m 5s the patch passed
+1 💚 checkstyle 0m 47s the patch passed
+1 💚 whitespace 0m 0s The patch has no whitespace issues.
+1 💚 hadoopcheck 10m 13s Patch does not cause any errors with Hadoop 3.2.4 3.3.5.
+1 💚 spotless 0m 42s patch has no errors when running spotless:check.
+1 💚 spotbugs 2m 24s the patch passed
_ Other Tests _
+1 💚 asflicense 0m 15s The patch does not generate ASF License warnings.
37m 29s
Subsystem Report/Notes
Docker ClientAPI=1.43 ServerAPI=1.43 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-5257/2/artifact/yetus-general-check/output/Dockerfile
GITHUB PR #5257
Optional Tests dupname asflicense javac spotbugs hadoopcheck hbaseanti spotless checkstyle compile
uname Linux 8fc00b2a1d35 5.4.0-1097-aws #105~18.04.1-Ubuntu SMP Mon Feb 13 17:50:57 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality dev-support/hbase-personality.sh
git revision master / 79c985f
Default Java Eclipse Adoptium-11.0.17+8
Max. process+thread count 79 (vs. ulimit of 30000)
modules C: hbase-client hbase-server U: .
Console output https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-5257/2/console
versions git=2.34.1 maven=3.8.6 spotbugs=4.7.3
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 52s Docker mode activated.
-0 ⚠️ yetus 0m 3s Unprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗 mvndep 0m 11s Maven dependency ordering for branch
+1 💚 mvninstall 2m 47s master passed
+1 💚 compile 1m 6s master passed
+1 💚 shadedjars 4m 42s branch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 0m 44s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 13s Maven dependency ordering for patch
+1 💚 mvninstall 2m 40s the patch passed
+1 💚 compile 1m 7s the patch passed
+1 💚 javac 1m 7s the patch passed
+1 💚 shadedjars 4m 36s patch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 0m 42s the patch passed
_ Other Tests _
+1 💚 unit 1m 27s hbase-client in the patch passed.
-1 ❌ unit 223m 23s hbase-server in the patch failed.
249m 22s
Subsystem Report/Notes
Docker ClientAPI=1.43 ServerAPI=1.43 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-5257/2/artifact/yetus-jdk11-hadoop3-check/output/Dockerfile
GITHUB PR #5257
Optional Tests javac javadoc unit shadedjars compile
uname Linux d6d6efbfc16f 5.4.0-144-generic #161-Ubuntu SMP Fri Feb 3 14:49:04 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality dev-support/hbase-personality.sh
git revision master / 79c985f
Default Java Eclipse Adoptium-11.0.17+8
unit https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-5257/2/artifact/yetus-jdk11-hadoop3-check/output/patch-unit-hbase-server.txt
Test Results https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-5257/2/testReport/
Max. process+thread count 4616 (vs. ulimit of 30000)
modules C: hbase-client hbase-server U: .
Console output https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-5257/2/console
versions git=2.34.1 maven=3.8.6
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 16s Docker mode activated.
-0 ⚠️ yetus 0m 3s Unprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗 mvndep 0m 11s Maven dependency ordering for branch
+1 💚 mvninstall 2m 23s master passed
+1 💚 compile 0m 58s master passed
+1 💚 shadedjars 4m 32s branch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 0m 39s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 13s Maven dependency ordering for patch
+1 💚 mvninstall 2m 21s the patch passed
+1 💚 compile 0m 56s the patch passed
+1 💚 javac 0m 56s the patch passed
+1 💚 shadedjars 5m 21s patch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 0m 53s the patch passed
_ Other Tests _
+1 💚 unit 1m 51s hbase-client in the patch passed.
-1 ❌ unit 245m 38s hbase-server in the patch failed.
270m 49s
Subsystem Report/Notes
Docker ClientAPI=1.43 ServerAPI=1.43 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-5257/2/artifact/yetus-jdk8-hadoop3-check/output/Dockerfile
GITHUB PR #5257
Optional Tests javac javadoc unit shadedjars compile
uname Linux c5ba642bab99 5.4.0-144-generic #161-Ubuntu SMP Fri Feb 3 14:49:04 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality dev-support/hbase-personality.sh
git revision master / 79c985f
Default Java Temurin-1.8.0_352-b08
unit https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-5257/2/artifact/yetus-jdk8-hadoop3-check/output/patch-unit-hbase-server.txt
Test Results https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-5257/2/testReport/
Max. process+thread count 4206 (vs. ulimit of 30000)
modules C: hbase-client hbase-server U: .
Console output https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-5257/2/console
versions git=2.34.1 maven=3.8.6
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

Copy link
Contributor

Choose a reason for hiding this comment

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

Better make an interface and let the MetricsConnection implements it, where we only expose read only methods. Like OnlineRegions and MutableOnlineRegions

Copy link
Contributor

Choose a reason for hiding this comment

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

I'm also wondering if we want to try to avoid exposing the codahale metrics Snapshot directly? It might make compatibility tricky in the future, if the upstream api there changes? Just a thought

@Apache9
Copy link
Contributor

Apache9 commented Jul 5, 2023

Any updates here?

Thanks.

@frostruan
Copy link
Contributor Author

Sorry, got a little stuck here. I haven't thought of a good way to expose the metric information in a read-only mode without introducing too many new data structures. I will continue to try.

Thanks Duo.

@bbeaudreault
Copy link
Contributor

How many do you think we need to introduce?

@Apache9
Copy link
Contributor

Apache9 commented Jul 6, 2023

I do not think we need to introduce new 'data structures', instead, we need to introduce new 'interfaces', where the current data structures will implement these interfaces, and provide read only access to the metrics. Anyway, maybe we need to add lots of new methods.

Thanks.

@frostruan
Copy link
Contributor Author

Thanks all for the comments. @Apache9 @bbeaudreault

Many of our metrics are Histogram or Timer types. In order to avoid user code updating metrics, we can only provide interfaces similar to snapshots. As we can imagine, our metric interfaces need to define getMin, getMax, getMean, getMedian, get99thPercentile, get999thPercentile .... , as Duo said, a lot of new methods need to be added, and I am still thinking about how to add them. Thanks.

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.

4 participants