Skip to content

Commit

Permalink
[internal/aws/proxy] adopt component.UseLocalHostAsDefaultHost feat…
Browse files Browse the repository at this point in the history
…ure gate (open-telemetry#30987)

Description:
internal/aws/proxy adopts `component.UseLocalHostAsDefaultHost` feature
gate

Link to tracking Issue:

open-telemetry#30702

Fixes
open-telemetry#30986

Documentation:
Updated docs.

---------

Co-authored-by: Pablo Baeyens <pbaeyens31+github@gmail.com>
Co-authored-by: Pablo Baeyens <pablo.baeyens@datadoghq.com>
  • Loading branch information
3 people authored and cparkins committed Feb 1, 2024
1 parent 142c1e9 commit 0879118
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 1 deletion.
1 change: 1 addition & 0 deletions .chloggen/mx-psi_internal-localhostgate.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ subtext: |
- extension/awsproxy
- extension/health_check
- extension/jaegerremotesampling
- internal/aws/proxy
- processor/remotetap
- receiver/awsfirehose
- receiver/awsxray
Expand Down
4 changes: 3 additions & 1 deletion internal/aws/proxy/cfg.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ package proxy // import "github.com/open-telemetry/opentelemetry-collector-contr
import (
"go.opentelemetry.io/collector/config/confignet"
"go.opentelemetry.io/collector/config/configtls"

"github.com/open-telemetry/opentelemetry-collector-contrib/internal/common/localhostgate"
)

// Config is the configuration for the local TCP proxy server.
Expand Down Expand Up @@ -43,7 +45,7 @@ type Config struct {
func DefaultConfig() *Config {
return &Config{
TCPAddr: confignet.TCPAddr{
Endpoint: "0.0.0.0:2000",
Endpoint: localhostgate.EndpointForPort(2000),
},
ProxyAddress: "",
TLSSetting: configtls.TLSClientSetting{
Expand Down
2 changes: 2 additions & 0 deletions receiver/awsxrayreceiver/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,8 @@ The TCP address and port on which this receiver listens for calls from the X-Ray

Default: `0.0.0.0:2000`

The `component.UseLocalHostAsDefaultHost` feature gate changes this to localhost:2000. This will become the default in a future release.

### proxy_address (Optional)
Defines the proxy address that the local TCP server forwards HTTP requests to AWS X-Ray backend through. If left unconfigured, requests will be sent directly.

Expand Down

0 comments on commit 0879118

Please sign in to comment.