Skip to content

Commit 71c43dd

Browse files
Remove experimental from dogstatsd stream socket option. (#53828)
<!--Please give us some feedback on your experience writing this PR ! https://app.datadoghq.com/forms/43db4c02-6837-400c-8083-692e141b1b88 !--> ### What does this PR do? Removes the warning and exposes the `dogstatsd_stream_socket` configuration option. ### Motivation The `dogstatsd_stream_socket` option has been available in the agent since 7.50. [PR](#20002). It has been hidden and a warning `dogstatsd_stream_socket is not yet supported, run it at your own risk` was shown when it was used. We have dogfooded the option extensively and successfully, so there is no reason to not support this option. ### Describe how you validated your changes ### Additional Notes Co-authored-by: stephen.wakely <stephen.wakely@datadoghq.com>
1 parent 8a100fc commit 71c43dd

5 files changed

Lines changed: 39 additions & 11 deletions

File tree

comp/dogstatsd/server/impl/server.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -418,7 +418,6 @@ func (s *dsdServer) start(context.Context) error {
418418
}
419419

420420
if len(socketStreamPath) > 0 {
421-
s.log.Warnf("dogstatsd_stream_socket is not yet supported, run it at your own risk")
422421
unixListener, err := listeners.NewUDSStreamListener(packetsChannel, sharedPacketPoolManager, sharedUDSOobPoolManager, s.config, s.tCapture, s.wmeta, s.pidMap, s.listernersTelemetry, s.packetsTelemetry, s.telemetry)
423422
if err != nil {
424423
s.log.Errorf("Can't init listener: %s", err.Error())

pkg/config/config_template.yaml

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2492,15 +2492,24 @@ api_key:
24922492

24932493
## @param dogstatsd_socket - string - optional - default: {{ if (or (eq .OS "linux") (eq .OS "aix")) }}"/var/run/datadog/dsd.socket"{{else}}""{{end}}
24942494
## @env DD_DOGSTATSD_SOCKET - string - optional - default: {{ if (or (eq .OS "linux") (eq .OS "aix")) }}"/var/run/datadog/dsd.socket"{{else}}""{{end}}
2495-
## Listen for Dogstatsd metrics on a Unix Socket (*nix only).
2495+
## Listen for Dogstatsd metrics on a Unix domain socket (*nix only).
24962496
## Set to a valid and existing filesystem path to enable.
24972497
## Set to "" to disable this feature.
24982498
##
24992499
## Please note that UDS receiver is not available in Windows.
2500-
## Enabling this setting may result in unexpected behavior.
25012500
#
25022501
# dogstatsd_socket: {{ if (or (eq .OS "linux") (eq .OS "aix")) }}"/var/run/datadog/dsd.socket"{{else}}""{{end}}
25032502

2503+
## @param dogstatsd_stream_socket - string - optional - default: ""
2504+
## @env DD_DOGSTATSD_STREAM_SOCKET - string - optional - default: ""
2505+
## Listen for Dogstatsd metrics on a Unix domain socket using stream mode (SOCK_STREAM, *nix only).
2506+
## Set to a valid and existing filesystem path to enable.
2507+
## Set to "" to disable this feature.
2508+
##
2509+
## Please note that this is not available in Windows.
2510+
#
2511+
# dogstatsd_stream_socket: ""
2512+
25042513
## @param dogstatsd_origin_detection - boolean - optional - default: false
25052514
## @env DD_DOGSTATSD_ORIGIN_DETECTION - boolean - optional - default: false
25062515
## When using Unix Socket, DogStatsD can tag metrics with container metadata.

pkg/config/schema/yaml/core_schema.yaml

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2207,18 +2207,30 @@ properties:
22072207
type: string
22082208
visibility: public
22092209
description: |-
2210-
Listen for Dogstatsd metrics on a Unix Socket (*nix only).
2210+
Listen for Dogstatsd metrics on a Unix domain socket (*nix only).
22112211
Set to a valid and existing filesystem path to enable.
22122212
Set to "" to disable this feature.
22132213
22142214
Please note that UDS receiver is not available in Windows.
2215-
Enabling this setting may result in unexpected behavior.
22162215
tags:
22172216
- template_section:Dogstatsd
22182217
platform_default:
22192218
linux: /var/run/datadog/dsd.socket
22202219
aix: /var/run/datadog/dsd.socket
22212220
other: ''
2221+
dogstatsd_stream_socket:
2222+
node_type: setting
2223+
type: string
2224+
default: ''
2225+
visibility: public
2226+
description: |-
2227+
Listen for Dogstatsd metrics on a Unix domain socket using stream mode (SOCK_STREAM, *nix only).
2228+
Set to a valid and existing filesystem path to enable.
2229+
Set to "" to disable this feature.
2230+
2231+
Please note that this is not available in Windows.
2232+
tags:
2233+
- template_section:Dogstatsd
22222234
dogstatsd_origin_detection:
22232235
node_type: setting
22242236
type: boolean
@@ -7965,11 +7977,6 @@ properties:
79657977
node_type: setting
79667978
type: boolean
79677979
default: false
7968-
dogstatsd_stream_socket:
7969-
node_type: setting
7970-
type: string
7971-
default: ''
7972-
comment: 'Experimental || Notice: empty means feature disabled'
79737980
dogstatsd_string_interner_size:
79747981
node_type: setting
79757982
type: integer

pkg/config/setup/common_settings.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1606,7 +1606,7 @@ func dogstatsd(config pkgconfigmodel.Setup) {
16061606
"other": "",
16071607
}))
16081608

1609-
config.BindEnvAndSetDefault("dogstatsd_stream_socket", "") // Experimental || Notice: empty means feature disabled
1609+
config.BindEnvAndSetDefault("dogstatsd_stream_socket", "")
16101610
config.BindEnvAndSetDefault("dogstatsd_stream_log_too_big", false)
16111611
config.BindEnvAndSetDefault("dogstatsd_pipeline_autoadjust", false)
16121612
config.BindEnvAndSetDefault("dogstatsd_pipeline_count", 1)
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# Each section from every release note are combined when the
2+
# CHANGELOG.rst is rendered. So the text needs to be worded so that
3+
# it does not depend on any information only available in another
4+
# section. This may mean repeating some details, but each section
5+
# must be readable independently of the other.
6+
#
7+
# Each section note must be formatted as reStructuredText.
8+
---
9+
enhancements:
10+
- |
11+
The ``dogstatsd_stream_socket`` configuration option, which lets DogStatsD
12+
listen for metrics on a Unix domain socket using stream mode (``SOCK_STREAM``),
13+
is now considered stable.

0 commit comments

Comments
 (0)