Configure Apache Kafka® metrics sent to Datadog#
For each Apache Kafka® topic and partition, the following metrics are currently supported:
All the above metrics are tagged with
partition allowing you to monitor each topic and partition independently.
These are the placeholders you will need to replace in the code samples.
Aiven for Apache Kafka® service name
ID of the integration between the Aiven for Apache Kafka service and Datadog
INTEGRATION_ID parameter can be found by issuing:
avn service integration-list SERVICE_NAME
Customise Apache Kafka® metrics sent to Datadog#
Before customising the metrics, make sure that you have a Datadog endpoint configured and enabled in your Aiven for Apache Kafka service. For details on how to set up the Datadog integration, check the dedicated article.
To customise the metrics sent to Datadog, you can use the
service integration-update passing the following customised parameters:
kafka_custom_metrics: defining the comma separated list of custom metrics to include (within
include_topics: defining the comma separated list of topics to include
By default, all topics are included.
exclude_topics: defining the comma separated list of topics to exclude
include_consumer_groups: defining the comma separated list of consumer groups to include
exclude_consumer_groups: defining the comma separated list of consumer groups to include
As example to sent the
kafka.log.log_end_offset metrics for
topic2 execute the following code:
avn service integration-update \ -c kafka_custom_metrics=kafka.log.log_size,kafka.log.log_end_offset \ -c include_topics=topic1,topic2 \ INTEGRATION_ID
Once the update is successful and metrics have been collected and pushed, you should see them in your Datadog explorer.
Learn more about Datadog and Aiven.