diff --git a/krakend/README.md b/krakend/README.md index 4748239baaf8f..db9a13fd1c009 100644 --- a/krakend/README.md +++ b/krakend/README.md @@ -2,39 +2,121 @@ ## Overview -This check monitors [KrakenD][1] through the Datadog Agent. +This check monitors [KrakenD][1] through the Datadog Agent. -Include a high level overview of what this integration does: -- What does your product do (in 1-2 sentences)? -- What value will customers get from this integration, and why is it valuable to them? -- What specific data will your integration monitor, and what's the value of that data? +KrakenD is a high-performance API Gateway that provides a single entry point for microservices. This integration collects metrics using KrakenD's [OpenTelemetry exporter with Prometheus format][2] and supports [log collection][3] for comprehensive monitoring. -**Minimum Agent version:** 7.69.0 +### What This Integration Monitors + +The integration collects metrics across multiple [layers][4] of the KrakenD gateway: + +- **HTTP Server Layer**: Request durations, response sizes, and status codes for client-facing traffic +- **Proxy Layer**: Processing times and performance metrics for KrakenD's internal proxy operations +- **Backend Layer**: Connection times, response durations, error rates, DNS resolution, TLS handshakes, timeouts, and connection details for upstream service calls +- **Go Runtime**: Garbage collection, memory usage, goroutines, and Go-specific performance metrics +- **System Process**: CPU usage, memory consumption, file descriptors, and network I/O + +In addition to metrics, you can collect access and application logs from KrakenD. + +### Deployment Support + +This integration works with KrakenD in both containerized (Docker, Kubernetes) and traditional deployment environments. -## Setup -Follow the instructions below to install and configure this check for an Agent running on a host. For containerized environments, see the [Autodiscovery Integration Templates][3] for guidance on applying these instructions. +## Setup ### Installation -The KrakenD check is included in the [Datadog Agent][2] package. -No additional installation is needed on your server. +The KrakenD check is included in the [Datadog Agent][6] package. No additional installation is needed on your server. ### Configuration -1. Edit the `krakend.d/conf.yaml` file, in the `conf.d/` folder at the root of your Agent's configuration directory to start collecting your krakend performance data. See the [sample krakend.d/conf.yaml][4] for all available configuration options. - -2. [Restart the Agent][5]. +### Metrics +The KrakenD integration uses the OpenTelemetry component in KrakenD with a Prometheus exporter to parse and emit metrics to Datadog. Make sure that your KrakenD installation is configured appropriately following the [instructions provided by KrakenD][7] and use the `prometheus` exporter. + +The snippet below configures KrakenD to emit metrics for [all layers][4] including Go and process metrics, exposing the Prometheus metrics endpoint on port 9090 on all network interfaces (`0.0.0.0`). The specific endpoint URL you configure in the integration as the `openmetrics_endpoint` option depends on your deployment: + +- **Same host**: `http://localhost:9090/metrics` +- **Docker containers and Kubernetes**: With Autodiscovery you can use the template variable `%%host%%`: `http://%%host%%:9090/metrics`. + +```json +{ + "extra_config": { + "telemetry/opentelemetry": { + "service_name": "krakend-gateway", + "service_version": "1.0.0", + "exporters": { + "prometheus": [ + { + "name": "krakend_metrics", + "port": 9090, + "listen_ip": "0.0.0.0", + "process_metrics": true, + "go_metrics": true + } + ] + }, + "layers": { + "global": { + "disable_metrics": false + }, + "proxy": { + "disable_metrics": false + }, + "backend": { + "metrics": { + "disable_stage": false, + "round_trip": true, + "read_payload": true, + "detailed_connection": true, + "static_attributes": [ + { + "key": "backend_type", + "value": "test_api" + } + ] + } + } + } + } + } +} +``` + +In KrakenD, emitting Go and process metrics is optional and can be disabled by setting `go_metrics` and `process_metrics` to `false`. For debugging purposes, to emit these metrics but not send them to Datadog, you can set the same options to `false` in the integration configuration. By default, they are enabled to respect the configuration set up in KrakenD. + +To configure the integration with KrakenD deployed on a host: + +1. Edit the `krakend.d/conf.yaml` file, in the `conf.d/` folder at the root of your Agent's configuration directory to start collecting your KrakenD performance data. See the sample [`krakend.d/conf.yaml`][9] for all available configuration options. + +2. [Restart the Agent][10]. + +For containerized environments, see the [Autodiscovery Integration Templates][5] for guidance. + +### Logs + +Ensure the agent is configured to load logs following the instructions about [Log Collection and Integrations][3]. + +To enable collection of KrakenD access and application logs, uncomment this section in the integration configuration file, replacing `` with the service to associate the logs with: + +```yaml +logs: + - type: docker + source: krakend + service: +``` + +Alternatively, in containerized environments, you can use Autodiscovery (for example, see [Docker][11] or [Kubernetes][12]) to add the logs configuration through annotations to the container or node where KrakenD is running. ### Validation -[Run the Agent's status subcommand][6] and look for `krakend` under the Checks section. +[Run the Agent's status subcommand][13] and look for `krakend` under the Checks section. ## Data Collected ### Metrics -See [metadata.csv][7] for a list of metrics provided by this integration. +See [metadata.csv][14] for a list of metrics provided by this integration. ### Events @@ -42,21 +124,26 @@ The KrakenD integration does not include any events. ### Service Checks -The KrakenD integration does not include any service checks. - -See [service_checks.json][8] for a list of service checks provided by this integration. +See [service_checks.json][15] for a list of service checks provided by this integration. ## Troubleshooting -Need help? Contact [Datadog support][9]. - - -[1]: **LINK_TO_INTEGRATION_SITE** -[2]: https://app.datadoghq.com/account/settings/agent/latest -[3]: https://docs.datadoghq.com/agent/kubernetes/integrations/ -[4]: https://github.com/DataDog/integrations-core/blob/master/krakend/datadog_checks/krakend/data/conf.yaml.example -[5]: https://docs.datadoghq.com/agent/guide/agent-commands/#start-stop-and-restart-the-agent -[6]: https://docs.datadoghq.com/agent/guide/agent-commands/#agent-status-and-information -[7]: https://github.com/DataDog/integrations-core/blob/master/krakend/metadata.csv -[8]: https://github.com/DataDog/integrations-core/blob/master/krakend/assets/service_checks.json -[9]: https://docs.datadoghq.com/help/ +Need help? Contact [Datadog support][16]. + + +[1]: https://www.krakend.io/ +[2]: https://www.krakend.io/docs/telemetry/prometheus/ +[3]: https://docs.datadoghq.com/logs/log_collection/ +[4]: https://www.krakend.io/docs/telemetry/opentelemetry-layers-metrics/ +[5]: https://docs.datadoghq.com/agent/kubernetes/integrations/ +[6]: https://app.datadoghq.com/account/settings/agent/latest +[7]: https://www.krakend.io/docs/telemetry/opentelemetry/ +[8]: https://www.krakend.io/docs/telemetry/opentelemetry-layers-metrics/ +[9]: https://github.com/DataDog/integrations-core/blob/master/krakend/datadog_checks/krakend/data/conf.yaml.example +[10]: https://docs.datadoghq.com/agent/guide/agent-commands/#start-stop-and-restart-the-agent +[11]: https://docs.datadoghq.com/containers/docker/log +[12]: https://docs.datadoghq.com/containers/kubernetes/log/ +[13]: https://docs.datadoghq.com/agent/guide/agent-commands/#agent-status-and-information +[14]: https://github.com/DataDog/integrations-core/blob/master/krakend/metadata.csv +[15]: https://github.com/DataDog/integrations-core/blob/master/krakend/assets/service_checks.json +[16]: https://docs.datadoghq.com/help/ \ No newline at end of file diff --git a/krakend/images/IMAGES_README.md b/krakend/images/IMAGES_README.md deleted file mode 100644 index 443f3c45e3385..0000000000000 --- a/krakend/images/IMAGES_README.md +++ /dev/null @@ -1,41 +0,0 @@ -# Marketplace Media Carousel Guidelines - -## Using the media gallery - -Please upload images to use the media gallery. Integrations require a minimum of 3 images. Images should highlight your product, your integration, and a full image of the Datadog integration dashboard. The gallery -can hold a maximum of 8 pieces of media total, and one of these pieces of media -can be a video (guidelines and submission steps below). Images should be -added to your /images directory and referenced in the manifest.json file. - - -## Image and video requirements - -### Images - -``` -File type : .jpg or .png -File size : ~500 KB per image, with a max of 1 MB per image -File dimensions : The image must be between 1440px and 2880px width, with a 16:9 aspect ratio (for example: 1440x810) -File name : Use only letters, numbers, underscores, and hyphens -Color mode : RGB -Color profile : sRGB -Description : 300 characters maximum -``` - -### Video - -To display a video in your media gallery, please send our team the zipped file -or a link to download the video at `marketplace@datadog.com`. In addition, -please upload a thumbnail image for your video as a part of the pull request. -Once approved, we will upload the file to Vimeo and provide you with the -vimeo_id to add to your manifest.json file. Please note that the gallery can -only hold one video. - -``` -File type : MP4 H.264 -File size : Max 1 video; 1 GB maximum size -File dimensions : The aspect ratio must be exactly 16:9, and the resolution must be 1920x1080 or higher -File name : partnerName-appName.mp4 -Run time : Recommendation of 60 seconds or less -Description : 300 characters maximum -```