Skip to main content
The HAProxy integration requires CXDOT Collector 1.4.0 or greater. HAProxy is an open source load balancer and reverse proxy for TCP and HTTP applications. Use the HAProxy integration with the Chronosphere XDOT Collector to collect connection, request, and session metrics from HAProxy servers running in your environment. The HAProxy integration supports HAProxy 3.0 or greater.

Supported telemetry types

The HAProxy integration supports these telemetry types:

Prerequisites

The HAProxy integration has the following prerequisites:
  • An HAProxy stats page that exposes the CSV export.
  • Make the HAProxy stats page reachable from the collector.

Configure

To configure the HAProxy integration, follow these steps:
  1. Configure HAProxy to expose statistics at /stats on port 8404. For example, add the following frontend to the HAProxy configuration:
  2. For HAProxy pods that expose the stats page on port 8404, add the app.kubernetes.io/name: haproxy label to the pod template. For instances that use another port or stats path, provide the stats URL through autodiscovery annotations. For more information, see autodiscovery.
  3. Optional: Configure static targets for HAProxy servers that autodiscovery doesn’t reach. For example, add the following to the values.yaml for your Helm chart:

Validate

To validate the HAProxy integration, follow these steps:
  1. In the Live Telemetry Analyzer, filter for cxdot.integration.name=haproxy. Confirm that the HAProxy metric names appear.
  2. In Metrics Explorer, run the following query:
    Confirm that the query returns the expected time series for each target.
For more information about diagnosing a failing integration, see Troubleshooting.

Configuration reference

Configure one HAProxy integration instance with the following settings. In Helm values, place these settings under config.integrations.haproxy. In a Collector configuration file, place them under cxdot.integrations.haproxy.

Optional settings

  • enabled Type: boolean. Optional. Default: true. Whether to enable this HAProxy integration instance. If true, the Collector collects metrics from HAProxy targets. If false, it doesn’t run this integration instance.
  • endpoints Type: array of object. Optional. Static HAProxy stats listeners as host:port values. The Collector requests the /stats path over HTTP and reads its CSV output. A nonempty list disables automatic discovery for this integration instance, and the Collector scrapes only the listed targets.
  • endpoints[].endpoint Type: string. Required. HAProxy statistics listener as host:port. The Collector requests /stats over HTTP and reads its CSV output.
  • collection_interval Type: duration. Optional. Default: 10s. How often the Collector requests statistics from each HAProxy target.
  • timeout Type: duration. Optional. Default: 10s. Maximum time the Collector waits for an HAProxy statistics request to complete.
  • disable_keep_alives Type: boolean. Optional. Default: true. Whether to close the connection after each statistics request. If true, the Collector closes the connection so that an idle connection doesn’t increase haproxy.sessions.count. If false, the Collector keeps the connection open for reuse. Annotation-discovered endpoints instead take connection persistence from the annotation’s persist_connections, tls_use_host_header, headers, and extra_headers fields.