Skip to content

Commit 7fecacb

Browse files
author
Hyunuk Lim
authored
fix: remove squash on configtls.TLSClientSetting for splunkhecexporter (#5541)
This PR removes squash on`configtls.TLSClientSetting` and update corresponding yaml file for splunkhecexporter. See history [here](#5454) **Link to tracking Issue:** #5433
1 parent 6415fe6 commit 7fecacb

File tree

4 files changed

+16
-13
lines changed

4 files changed

+16
-13
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
## 🛑 Breaking changes 🛑
66

7+
- Remove squash on configtls.TLSClientSetting for splunkhecexporter (#5541)
78
- Remove squash on configtls.TLSClientSetting for elastic components (#5539)
89
- Remove squash on configtls.TLSClientSetting for observiqexporter (#5540)
910
- Remove squash on configtls.TLSClientSetting for AWS components (#5454)

exporter/splunkhecexporter/README.md

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -61,14 +61,15 @@ exporters:
6161
disable_compression: false
6262
# HTTP timeout when sending data. Defaults to 10s.
6363
timeout: 10s
64-
# Whether to skip checking the certificate of the HEC endpoint when sending data over HTTPS. Defaults to false.
65-
insecure_skip_verify: false
66-
# Path to the CA cert to verify the server being connected to.
67-
ca_file: /certs/ExampleCA.crt
68-
# Path to the TLS cert to use for client connections when TLS client auth is required.
69-
cert_file: /certs/HECclient.crt
70-
# Path to the TLS key to use for TLS required connections.
71-
key_file: /certs/HECclient.key
64+
tls:
65+
# Whether to skip checking the certificate of the HEC endpoint when sending data over HTTPS. Defaults to false.
66+
insecure_skip_verify: false
67+
# Path to the CA cert to verify the server being connected to.
68+
ca_file: /certs/ExampleCA.crt
69+
# Path to the TLS cert to use for client connections when TLS client auth is required.
70+
cert_file: /certs/HECclient.crt
71+
# Path to the TLS key to use for TLS required connections.
72+
key_file: /certs/HECclient.key
7273
# Application name is used to track telemetry information for Splunk App's using HEC by App name.
7374
splunk_app_name: "OpenTelemetry-Collector Splunk Exporter"
7475
# Application version is used to track telemetry information for Splunk App's using HEC by App version.

exporter/splunkhecexporter/config.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ type Config struct {
7676
MaxContentLengthLogs uint `mapstructure:"max_content_length_logs"`
7777

7878
// TLSSetting struct exposes TLS client configuration.
79-
TLSSetting configtls.TLSClientSetting `mapstructure:",squash"`
79+
TLSSetting configtls.TLSClientSetting `mapstructure:"tls,omitempty"`
8080

8181
// App name is used to track telemetry information for Splunk App's using HEC by App name. Defaults to "OpenTelemetry Collector Contrib".
8282
SplunkAppName string `mapstructure:"splunk_app_name"`

exporter/splunkhecexporter/testdata/config.yaml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,11 @@ exporters:
1414
source: "otel"
1515
sourcetype: "otel"
1616
index: "metrics"
17-
insecure_skip_verify: false
18-
ca_file: ""
19-
cert_file: ""
20-
key_file: ""
17+
tls:
18+
insecure_skip_verify: false
19+
ca_file: ""
20+
cert_file: ""
21+
key_file: ""
2122
timeout: 10s
2223
sending_queue:
2324
enabled: true

0 commit comments

Comments
 (0)