JVM (StatsD)¶
Configuration¶
Example: Collect JVM metrics through ddtrace
and receive JVM metrics sent by ddtrace
through the built-in Statsd of DataKit.
DataKit enables the collector¶
- Enables
Statsd
collector
Copy the sample
file without modifying the statsd.conf
- Restart DataKit
Application Configuration¶
- Adjusting startup parameters
-javaagent:/usr/local/datakit/data/dd-java-agent.jar \
-Ddd.service.name=<your-service> \
-Ddd.env=dev \
-Ddd.agent.port=9529
Start jar
using the java -jar
method and connect to DataKit on the local machine by default. If you need to connect to DataKit on a remote server, please use -Ddd.agent.host
and -Ddd.jmxfetch.statsd.host
to specify ip
.
For more detailed access to DDTrace, refer to the ddtrace java
document.