How to Disable possuindo. netflix. servo. distribute. jmxmetricpoller Using log4j2. yml
How to Turn off com. netflix. domestico. publish. jmxmetricpoller through log4j2. yml
Introduction
The com. netflix. servo. publish. jmxmetricpoller
will be a JMX metric poller that is usually used by this Netflix Servo supervising library to collect metrics from some sort of Java application. Within some cases, a person may want to disable this poller, for example, if you are employing a different checking solution or when you are encountering performance issues.
Disabling typically the poller using log4j2. yml
One way to disable the com. netflix. servo. publish. jmxmetricpoller
is usually to use the particular log4j2 logging construction. Log4j2 allows a person to configure typically the logging level for individual classes or packages, and anyone can use this kind of to disable this logging for the particular com. netflix. servo. submit. jmxmetricpoller
class.
To do this kind of, add the following configuration to the log4j2. yml document:
logging: level: contendo. netflix. servo. post. jmxmetricpoller: OFF
This specific will disable just about all logging for typically the possuindo. netflix. servo. post. jmxmetricpoller
class, including typically the logging that is used to begin the poller. Seeing that a result, the particular poller will not be started and will not gather any metrics.
Disabling typically the poller using a system property
Another means to disable the particular contendo. netflix. servo. post. jmxmetricpoller
is to set the servo. jmx. allowed
method property to false
. This will prevent the poller by being started, perhaps if logging is definitely enabled for the apresentando. netflix. servo. post. jmxmetricpoller
class.
To set the particular system property, an individual can use the following command:
coffee beans -Dservo. jmx. enabled=false...
You can in addition set the program property in the code, using this following code:
System. setProperty("servo. jmx. enabled", "false");
Conclusion
Disabling the particular contendo. netflix. servo. submit. jmxmetricpoller
can be useful in certain conditions, such as if you are working with a different monitoring solution or when you are suffering from performance issues. A person can disable the particular poller using log4j2. yml or simply by setting the servo. jmx. enabled
system property.