The Agent's Kong check tracks total requests, response codes, client connections, and more.
The Kong check is included in the Datadog Agent package, so you don't need to install anything else on your Kong servers.
Follow the instructions below to configure this check for an Agent running on a host. For containerized environments, see the Containerized section.
-
Add this configuration block to your
kong.d/conf.yaml
file in theconf.d/
folder at the root of your Agent's configuration directory to start gathering your Kong Metrics. See the sample kong.d/conf.yaml for all available configuration options.init_config: instances: ## @param kong_status_url - string - required ## URL where Kong exposes its status. # - kong_status_url: http://localhost:8001/status/
Available for Agent versions >6.0
Kong access logs are generated by NGINX, so the default location is the same as for NGINX files.
-
Collecting logs is disabled by default in the Datadog Agent, enable it in your
datadog.yaml
file:logs_enabled: true
-
Add this configuration block to your
kong.d/conf.yaml
file to start collecting your Kong Logs:logs: - type: file path: /var/log/nginx/access.log service: '<SERVICE>' source: kong - type: file path: /var/log/nginx/error.log service: '<SERVICE>' source: kong
Change the
path
andservice
parameter values and configure them for your environment. See the sample kong.d/conf.yaml for all available configuration options.
For containerized environments, see the Autodiscovery Integration Templates for guidance on applying the parameters below.
Parameter | Value |
---|---|
<INTEGRATION_NAME> |
kong |
<INIT_CONFIG> |
blank or {} |
<INSTANCE_CONFIG> |
{"kong_status_url": "http://%%host%%:8001/status/"} |
Available for Agent versions >6.0
Collecting logs is disabled by default in the Datadog Agent. To enable it, see Kubernetes log collection documentation.
Parameter | Value |
---|---|
<LOG_CONFIG> |
{"source": "kong", "service": "<SERVICE_NAME>"} |
Run the Agent's status subcommand and look for kong
under the Checks section.
See metadata.csv for a list of metrics provided by this integration.
The Kong check does not include any events.
kong.can_connect:
Returns CRITICAL
if the Agent cannot connect to Kong to collect metrics, otherwise returns OK
.
Need help? Contact Datadog support.