Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enabling shared pipeline for profiling by default #1181

Merged
merged 3 commits into from
Feb 11, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 16 additions & 18 deletions cmd/otelcol/config/collector/ecs_ec2_config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -125,12 +125,12 @@ exporters:
access_token: "${SPLUNK_ACCESS_TOKEN}"
realm: "${SPLUNK_REALM}"
correlation:
# # Logs
# splunk_hec:
# token: "${SPLUNK_HEC_TOKEN}"
# endpoint: "${SPLUNK_HEC_URL}"
# source: "otel"
# sourcetype: "otel"
# Logs + Profiling
splunk_hec:
token: "${SPLUNK_HEC_TOKEN}"
endpoint: "${SPLUNK_HEC_URL}"
Copy link
Contributor

@rmfitzpatrick rmfitzpatrick Feb 1, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

these env vars aren't documented in the deployment instructions, and if they are now intended to be used for profiling we probably want to have a templated endpoint like we do w/ the sapm exporter and use SPLUNK_ACCESS_TOKEN*. imo we should have a dedicated splunk_hec/profiling exporter.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

these env vars aren't documented in the deployment instructions, and if they are now intended to be used for profiling we probably want to have a templated endpoint like we do w/ the sapm exporter and use SPLUNK_ACCESS_TOKEN*

We compose these env vars from SPLUNK_ACCESS_TOKEN and SPLUNK_REALM by default. Using these env vars leaves an option for users to send logs to another Splunk endpoint instead of o11y without providing a custom config. Also it's consistent with other configs that we have

imo we should have a dedicated splunk_hec/profiling exporter.

The profiling data shares the same pipeline including otlp receiver. Profiling libraries use the same OTLP port by default. So we cannot split it and create another exporter.

Copy link
Contributor

@rmfitzpatrick rmfitzpatrick Feb 1, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the autosetting pass is ok where users aren't setting these env vars for Splunk Cloud* usage. Otherwise wouldn't profiling data be sent directly to Splunk Cloud? (APM/Profiling + Splunk Cloud instead of LO)** Not sure how common this would be.

Copy link
Contributor

@dmitryax dmitryax Feb 2, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Otherwise wouldn't profiling data be sent directly to Splunk Cloud?

Yes they would, and Splunk Cloud backend can digest and show them is some way, not as good as Splunk O11y tho.

Use case when user wants logs flowing to Splunk Cloud and Profiling data to Splunk O11y will require separate pipelines and changing logs and profiling libraries to send to different ports. So it using SPLUNK_ACCESS_TOKEN instead of SPLUNK_HEC_TOKEN doesn't help.

I think we should use SPLUNK_HEC_TOKEN at least for consistency with other default configs.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@rmfitzpatrick please let us know if you're ok to merge it

source: "otel"
sourcetype: "otel"

service:
extensions: [health_check, http_forwarder, zpages, memory_ballast]
Expand All @@ -151,15 +151,13 @@ service:
receivers: [prometheus/internal]
processors: [memory_limiter, batch, resourcedetection/internal]
exporters: [signalfx]
# logs:
# receivers: [otlp]
# processors:
# - memory_limiter
# - batch
# - resourcedetection
# #- resource/add_environment
# exporters: [splunk_hec]
# # Use instead when sending to gateway
# #exporters: [otlp]


logs:
receivers: [otlp]
processors:
- memory_limiter
- batch
- resourcedetection
#- resource/add_environment
exporters: [splunk_hec]
# Use instead when sending to gateway
#exporters: [otlp]
32 changes: 16 additions & 16 deletions cmd/otelcol/config/collector/fargate_config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -103,12 +103,12 @@ exporters:
access_token: "${SPLUNK_ACCESS_TOKEN}"
realm: "${SPLUNK_REALM}"
correlation:
# # Logs
# splunk_hec:
# token: "${SPLUNK_HEC_TOKEN}"
# endpoint: "${SPLUNK_HEC_URL}"
# source: "otel"
# sourcetype: "otel"
# Logs + Profiling
splunk_hec:
token: "${SPLUNK_HEC_TOKEN}"
endpoint: "${SPLUNK_HEC_URL}"
source: "otel"
sourcetype: "otel"

service:
extensions: [health_check, http_forwarder, zpages, memory_ballast]
Expand All @@ -125,13 +125,13 @@ service:
receivers: [signalfx, smartagent/signalfx-forwarder, smartagent/ecs-metadata, prometheus/internal]
processors: [memory_limiter, batch, resourcedetection]
exporters: [signalfx]
# logs:
# receivers: [otlp]
# processors:
# - memory_limiter
# - batch
# - resourcedetection
# #- resource/add_environment
# exporters: [splunk_hec]
# # Use instead when sending to gateway
# #exporters: [otlp]
logs:
receivers: [otlp]
processors:
- memory_limiter
- batch
- resourcedetection
#- resource/add_environment
exporters: [splunk_hec]
# Use instead when sending to gateway
#exporters: [otlp]