How to read Aeron counters programmatically¶
You want to feed Aeron Counter data to a metrics system, such as DataDog or Prometheus.
Read the counter data using
CountersReader is available on the Aeron client or via a
1 2 3 4 5 6 7 8
- If you're writing into something with a blocking API, it may be beneficial to run this within a dedicated agent that runs on a relatively slow schedule (for example once a second)
- Using the CncFileReader allows you to read Aeron counter data from an external process. See the AeronStat source code (link below) for an example on how to do this.
- Avoid reading this data if the Aeron client is closed.