Nonlocal Datadog Agent Does not Get Properly Configured
- Dominant language
- Go
- Stars
- 30.1k
- Forks
- 4.6k
- Avg merge
- 1d 18h
- Merged PRs (30d)
- 39
Description
#### Overview of the Issue
Currently, we have a telemetry config such as:
```hcl
telemetry = {
dogstatsd_addr = "EXTERNAL_DNS_NAME"
}
```
And it seems as though, the datadog cluster in envoy still gets configured as `127.0.0.1`:
```json
{
"name": "datadog_local",
"connect_timeout": "3s",
"dns_lookup_family": "V4_ONLY",
"load_assignment": {
"cluster_name": "datadog_local",
"endpoints": [
{
"lb_endpoints": [
{
"endpoint": {
"address": {
"socket_address": {
"address": "127.0.0.1",
"port_value": 8126
}
}
}
}
]
}
```
It seems the telemetry attribute is not respecting the external datadog configuration, and datadog is not getting consul or envoy metrics.
#### Reproduction Steps
Steps to reproduce this issue, eg:
1. Create an external datadog agent
1. start a consul agent with connect and an envoy sidecar, configuring telemetry `dogstatsd_addr` for the external datadog agent
1. Datadog will not receive metrics, and the envoy configuration will have the datadog cluster configured for 127.0.0.1.
### Consul info for both Client and Server
Consul 1.15.3
Consul 1.15.3
### Operating system and Environment details
AWS Fargate
Contributor guide
Research direction
Start by reproducing the telemetry configuration with dogstatsd_addr set to an external Datadog agent on Consul 1.15.3 with Connect and an Envoy sidecar. Trace how that setting produces the datadog_local Envoy cluster; done means the cluster uses the external address instead of 127.0.0.1 and Datadog receives Consul and Envoy metrics.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- networking, observability
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100