Supported telemetry types
The Consul integration supports these telemetry types:Prerequisites
The Consul integration has the following prerequisites:- Make each Consul agent’s HTTP API reachable from the collector.
- If Consul access control lists are enabled, create a token with read access to the agent, catalog, and health endpoints.
Configure
To configure the Consul integration, follow these steps:-
For Consul pods that expose the HTTP API on port
8500, add theapp: consullabel to the pod template. For instances that require a different URL, access control list token, or transport layer security settings, provide them through autodiscovery annotations. For more information, see autodiscovery. -
Optional: Configure static targets for Consul agents that autodiscovery doesn’t
reach. For example, add the following to the
values.yamlfor your Helm chart:
Validate
To validate the Consul integration, follow these steps:-
In Live Telemetry Analyzer, filter for
cxdot.integration.name=consul. Confirm that Consul metric names appear. -
In Metrics Explorer, run the following query:
Confirm that every Consul agent you expect appears in the results.
Troubleshooting
- Consul metrics don’t appear and collector logs report HTTP
403responses: Confirm that the Consul access control list token has read access to the agent, catalog, and health endpoints. - Catalog metrics are missing for an agent, but
consul.peersappears: Only the Raft leader for a data center reports catalog metrics. Other agents report peer count only.
Configuration reference
Configure one Consul integration instance with the following settings. In Helm values, place these settings underconfig.integrations.consul. In a Collector configuration file, place them
under cxdot.integrations.consul.
Optional settings
-
enabledType:boolean. Optional. Default:true. Whether to enable this Consul integration instance. If true, the Collector runs the instance. If false, the Collector doesn’t run it. -
endpointsType:array of object. Optional. Static Consul targets. A nonempty list disables automatic discovery for this integration instance, and the Collector collects metrics from only the listed targets. Specify a target ashost:portto use HTTP. Specify a full HTTP or HTTPS URL to control the scheme. -
endpoints[].endpointType:string. Required. Consul target as eitherhost:portor a full HTTP or HTTPS URL. -
acl_tokenType:string. Optional. Consul access control list token sent in theX-Consul-Tokenheader. Provide a token with read access to the agent, catalog, and health endpoints when access control lists are enabled. The Collector masks this sensitive value in diagnostic output, logs, and errors. Discovery annotations can provide a target-specific token. -
collection_intervalType:duration. Optional. Default:15s. How often the Collector collects metrics from each Consul target. -
timeoutType:duration. Optional. Default:15s. Maximum time allowed to collect metrics from one Consul target. The value must not exceedcollection_interval. -
max_servicesType:integer. Optional. Default:50. Minimum:1. Cap on how many catalog services one collection interrogates. Each service costs one health-endpoint request, so an unbounded catalog would turn a single collection into thousands of requests against the agent. Services are taken in name order once the catalog exceeds the cap, so the truncated set stays the same between collections rather than shifting with the agent’s response ordering. -
tlsType:object. Optional. Transport layer security (TLS) settings for static HTTPS targets. Certificate verification is enabled unlessinsecure_skip_verifyis true. These settings don’t apply to HTTP targets. Discovery annotations can provide target-specific TLS settings. -
tls.ca_fileType:string. Optional. Path to the CA cert. For a client this verifies the server certificate. For a server this verifies client certificates. If empty uses system root CA. (optional) -
tls.ca_pemType:string. Optional. In memory PEM encoded cert. (optional) -
tls.cert_fileType:string. Optional. Path to the TLS cert to use for TLS required connections. (optional) -
tls.cert_pemType:string. Optional. In memory PEM encoded TLS cert to use for TLS required connections. (optional) -
tls.cipher_suitesType:array of string. Optional. CipherSuites is a list of TLS cipher suites that the TLS transport can use. If left blank, a safe default list is used. See https://go.dev/src/crypto/tls/cipher_suites.go for a list of supported cipher suites. -
tls.curve_preferencesType:array of string. Optional. contains the elliptic curves that will be used in an ECDHE handshake, in preference order Defaults to empty list and “crypto/tls” defaults are used, internally. -
tls.include_system_ca_certs_poolType:boolean. Optional. If true, load system CA certificates pool in addition to the certificates configured in this struct. -
tls.insecureType:boolean. Optional. In gRPC and HTTP when set to true, this is used to disable the client transport security. See https://godoc.org/google.golang.org/grpc#WithInsecure for gRPC. Please refer to https://godoc.org/crypto/tls#Config for more information. (optional, default false) -
tls.insecure_skip_verifyType:boolean. Optional. InsecureSkipVerify will enable TLS but not verify the certificate. -
tls.key_fileType:string. Optional. Path to the TLS key to use for TLS required connections. (optional) -
tls.key_pemType:string. Optional. In memory PEM encoded TLS key to use for TLS required connections. (optional) -
tls.max_versionType:string. Optional. MaxVersion sets the maximum TLS version that is acceptable. If not set, refer to crypto/tls for defaults. (optional) -
tls.min_versionType:string. Optional. MinVersion sets the minimum TLS version that is acceptable. If not set, TLS 1.2 will be used. (optional) -
tls.reload_intervalType:duration. Optional. ReloadInterval specifies the duration after which the certificate will be reloaded If not set, it will never be reloaded (optional) -
tls.server_name_overrideType:string. Optional. ServerName requested by client for virtual hosting. This sets the ServerName in the TLSConfig. Please refer to https://godoc.org/crypto/tls#Config for more information. (optional) -
tls.tpmType:object. Optional. Trusted platform module configuration -
tls.tpm.authType:string. Optional. Authorization value for the trusted platform module key. -
tls.tpm.enabledType:boolean. Optional. Whether to use a trusted platform module for the TLS private key. If true, the Collector loads the key from the configured device or socket. If false, the Collector uses the configured key file or in-memory key. -
tls.tpm.owner_authType:string. Optional. Owner authorization value for the trusted platform module. -
tls.tpm.pathType:string. Optional. The path to the TPM device or Unix domain socket. For instance /dev/tpm0 or /dev/tpmrm0.

