-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
Added new SysMonitor based on Oshi library #14359
Conversation
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.
This is good. I am not fully done yet but there is some feedback that can be addressed right away.
processing/src/main/java/org/apache/druid/java/util/metrics/SysMonitorOshi.java
Outdated
Show resolved
Hide resolved
processing/src/main/java/org/apache/druid/java/util/metrics/SysMonitorOshi.java
Outdated
Show resolved
Hide resolved
processing/src/main/java/org/apache/druid/java/util/metrics/SysMonitorOshi.java
Outdated
Show resolved
Hide resolved
processing/src/main/java/org/apache/druid/java/util/metrics/SysMonitorOshi.java
Outdated
Show resolved
Hide resolved
processing/src/test/java/org/apache/druid/java/util/metrics/SysMonitorOshiTest.java
Outdated
Show resolved
Hide resolved
the 'check-licenses' script we have to help us ensure that we collect all the correct licensing information for our source distributions to meet apache requirements has entries for the licenses it is aware of to normalize them into standard buckets, it looks like maybe something is reporting a string that it hasn't seen before, which looks like what this error is perhaps:
I think if you add that entry into the script and bucket it into the other MIT licenses then it should probably be ok? Also if there are any transitive dependencies pulled in by this new library they might also need added to the licenses.yaml file. I know this stuff is somewhat tedious, so apologies for that, and still not a perfect system by any means because it is prone to becoming stale, but it does significantly reduce the burden of doing releases. |
I also unlinked the community roadmap issue from this PR so that the issue doesn't get closed after this PR is merged :) |
processing/src/main/java/org/apache/druid/java/util/metrics/SysMonitorOshi.java
Outdated
Show resolved
Hide resolved
processing/src/main/java/org/apache/druid/java/util/metrics/OshiSysMonitor.java
Outdated
Show resolved
Hide resolved
processing/src/main/java/org/apache/druid/java/util/metrics/OshiSysMonitor.java
Outdated
Show resolved
Hide resolved
processing/src/main/java/org/apache/druid/java/util/metrics/OshiSysMonitor.java
Outdated
Show resolved
Hide resolved
processing/src/main/java/org/apache/druid/java/util/metrics/OshiSysMonitor.java
Outdated
Show resolved
Hide resolved
processing/src/main/java/org/apache/druid/java/util/metrics/OshiSysMonitor.java
Outdated
Show resolved
Hide resolved
processing/src/main/java/org/apache/druid/java/util/metrics/OshiSysMonitor.java
Outdated
Show resolved
Hide resolved
processing/src/main/java/org/apache/druid/java/util/metrics/OshiSysMonitor.java
Outdated
Show resolved
Hide resolved
processing/src/main/java/org/apache/druid/java/util/metrics/OshiSysMonitor.java
Show resolved
Hide resolved
processing/src/main/java/org/apache/druid/java/util/metrics/OshiSysMonitor.java
Outdated
Show resolved
Hide resolved
processing/src/main/java/org/apache/druid/java/util/metrics/OshiSysMonitor.java
Show resolved
Hide resolved
processing/src/main/java/org/apache/druid/java/util/metrics/OshiSysMonitor.java
Outdated
Show resolved
Hide resolved
processing/src/main/java/org/apache/druid/java/util/metrics/OshiSysMonitor.java
Outdated
Show resolved
Hide resolved
processing/src/main/java/org/apache/druid/java/util/metrics/OshiSysMonitor.java
Outdated
Show resolved
Hide resolved
processing/src/main/java/org/apache/druid/java/util/metrics/OshiSysMonitor.java
Outdated
Show resolved
Hide resolved
Approved and will merge once CI passes. Thank you @hardikbajaj for your contribution. |
Thanks @abhishekagarwal87 for giving me this great learning opportunity, in form of a very meaningful Good First issue :). Also thanks for being super supportive and helping me out with your reviews, and teachings. |
Merged. Appreciate the persistency @hardikbajaj :) |
Fixes one of the issues in #14157. (SysMonitor on ARM in roadmap)
Description
SysMonitor uses Sigar library, which not only is not maintained and doesn't run on ARM64 arch. A JNA based oshi library was proposed by @abhishekagarwal87 in slack community which is well maintained, used by projects like Apache flink, and also works well on ARM architecture too. Here I introduce v0 of
SysMonitorOshi
, oshi based SysMonitor for Druid.This monitor monitors most of the metrics emitted by
SysMonitor.java
but is a v0 implementation which just consumes metrics emitted by Oshi directly, without modifying/mapping it.Fixed the bug ...
SysMonitor not usable in ARM architecture
Release note
Added a new monitor
SysMonitorOshi
to replaceSysMonitor
. The new monitor has a wider support for different machine architectures including ARM instances. Please switch to SysMonitorOshi asSysMonitor
is now deprecated and will be removed in future releases.Key changed/added classes in this PR
SysMonitorOshi.java
NoopSysMonitorOshi.java
SysMonitorOshiTest.java
This PR has: