-
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
OshiSysMonitor: Add ability to skip emitting metrics #16972
OshiSysMonitor: Add ability to skip emitting metrics #16972
Conversation
processing/src/main/java/org/apache/druid/java/util/metrics/OshiSysMonitor.java
Outdated
Show resolved
Hide resolved
The changes looks reasonable. The property name can be simpler and generic. |
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.
left some suggestions.
server/src/main/java/org/apache/druid/server/metrics/OshiSysConfig.java
Outdated
Show resolved
Hide resolved
server/src/main/java/org/apache/druid/server/metrics/OshiSysConfig.java
Outdated
Show resolved
Hide resolved
server/src/main/java/org/apache/druid/server/metrics/MetricsModule.java
Outdated
Show resolved
Hide resolved
processing/src/main/java/org/apache/druid/java/util/metrics/OshiSysMonitor.java
Outdated
Show resolved
Hide resolved
server/src/main/java/org/apache/druid/server/metrics/OshiSysConfig.java
Outdated
Show resolved
Hide resolved
21ccdef
to
7088d3e
Compare
7088d3e
to
7bff962
Compare
|
||
public class OshiSysMonitorConfig | ||
{ | ||
public static final String PREFIX = "druid.monitoring.oshisys"; |
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.
there is no need to have oshi
in there. OshiSysMonitor is the default sys monitor now. We will likely get rid of SysMonitor completely and make that a symlink to OshiSysMonitor. We will not be able to change these prefixes later.
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.
But, As of this commit what do you suggest naming it ?
We will not be able to change these prefixes later.
Because , we don't want to update the docs later ?
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.
druid.monitoring.sys
Because , we don't want to update the docs later ?
Because people would have already set the config and we can't change it without breaking their setup.
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.
If this is universally the case with sys metrics emitted in the containerized environments, should Druid automatically set the useful categories in the K8sTaskAdapter
while launching the task in the container? This will modify the default behavior, but if the metrics are useless (everytime), then it should be fine to make the change.
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.
druid.monitoring.sys
done.
Regarding K8sTaskAdapter
I think it depends on the type of installation and requirements of user to specify which categories to specify and hence I would not enforce anything. Also K8sTaskAdapter
is just for peons ?
looks like a unrelated test failure, going to merge this |
* OshiSysMonitor: Add ability to skip emitting metrics * comments * static checks * remove oshi
Description
While running druid in containerized (or any other customized) environments, not all of the metrics emitted by OshiSysMonitor are applicable. This PR adds ability to skip a category of metrics from this monitor so as to reduce computation in calculating/emitting/storing such metrics through specifying
druid.monitoring.oshisys.skipEmitting
config.Release note
Ability to skip emitting metrics by category in OshiSysMonitor.
Key changed/added classes in this PR
OshiSysMonitor
MetricsModule
This PR has: