Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
…y-configuration into prefer-name-value-pairs
  • Loading branch information
jack-berg committed Sep 18, 2024
2 parents 0fe5dbf + a377d99 commit ad50656
Show file tree
Hide file tree
Showing 6 changed files with 74 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@
# https://help.github.com/en/articles/about-code-owners
#

* @open-telemetry/configuration-maintainers
* @open-telemetry/configuration-approvers
41 changes: 41 additions & 0 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: "CodeQL Analysis"
on:
push:
branches: [main]
pull_request:

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref }}
cancel-in-progress: true

permissions:
contents: read

jobs:
CodeQL-Build:
permissions:
actions: read # for github/codeql-action/init to get workflow details
contents: read # for actions/checkout to fetch code
security-events: write # for github/codeql-action/autobuild to send a status report
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7

- name: Setup Go
uses: actions/setup-go@0a12ed9d6a96ab950c8f026ed9f722fe0da7ef32 # v5.0.2
with:
go-version: ~1.22

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@4dd16135b69a43b6c8efb853346f8437d92d3c93 # v3.26.6
with:
languages: go

- name: Autobuild
uses: github/codeql-action/autobuild@4dd16135b69a43b6c8efb853346f8437d92d3c93 # v3.26.6

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@4dd16135b69a43b6c8efb853346f8437d92d3c93 # v3.26.6
12 changes: 12 additions & 0 deletions examples/kitchen-sink.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,10 @@ logger_provider:
headers:
- name: api-key
value: "1234"
# Configure headers. Entries have lower priority than entries from .headers.
#
# The value is a list of comma separated key-value pairs, matching the format of OTEL_EXPORTER_OTLP_HEADERS, OTEL_EXPORTER_OTLP_LOGS_HEADERS. See https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/configuration/sdk-environment-variables.md#general-sdk-configuration for details.
headers_list: "api-key=1234"
# Configure compression.
#
# Environment variable: OTEL_EXPORTER_OTLP_COMPRESSION, OTEL_EXPORTER_OTLP_LOGS_COMPRESSION
Expand Down Expand Up @@ -189,6 +193,10 @@ meter_provider:
headers:
- name: api-key
value: "1234"
# Configure headers. Entries have lower priority than entries from .headers.
#
# The value is a list of comma separated key-value pairs, matching the format of OTEL_EXPORTER_OTLP_HEADERS, OTEL_EXPORTER_OTLP_METRICS_HEADERS. See https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/configuration/sdk-environment-variables.md#general-sdk-configuration for details.
headers_list: "api-key=1234"
# Configure compression.
#
# Environment variable: OTEL_EXPORTER_OTLP_COMPRESSION, OTEL_EXPORTER_OTLP_METRICS_COMPRESSION
Expand Down Expand Up @@ -317,6 +325,10 @@ tracer_provider:
headers:
- name: api-key
value: "1234"
# Configure headers. Entries have lower priority than entries from .headers.
#
# The value is a list of comma separated key-value pairs, matching the format of OTEL_EXPORTER_OTLP_HEADERS, OTEL_EXPORTER_OTLP_TRACES_HEADERS. See https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/configuration/sdk-environment-variables.md#general-sdk-configuration for details.
headers_list: "api-key=1234"
# Configure compression.
#
# Environment variable: OTEL_EXPORTER_OTLP_COMPRESSION, OTEL_EXPORTER_OTLP_TRACES_COMPRESSION
Expand Down
17 changes: 14 additions & 3 deletions examples/sdk-migration-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@
# - OTEL_EXPORTER_OTLP_CERTIFICATE
# - OTEL_EXPORTER_OTLP_CLIENT_KEY
# - OTEL_EXPORTER_OTLP_CLIENT_CERTIFICATE
# - OTEL_EXPORTER_OTLP_HEADERS, OTEL_EXPORTER_OTLP_{SIGNAL}_HEADERS
# - OTEL_EXPORTER_OTLP_COMPRESSION
# - OTEL_EXPORTER_OTLP_TIMEOUT

Expand Down Expand Up @@ -99,6 +98,10 @@ tracer_provider:
timeout: ${OTEL_EXPORTER_OTLP_TRACES_TIMEOUT:-10000}
# Configure headers:
headers: []
# Configure headers. Entries have lower priority than entries from .headers.
#
# The value is a list of comma separated key-value pairs, matching the format of OTEL_EXPORTER_OTLP_HEADERS, OTEL_EXPORTER_OTLP_TRACES_HEADERS. See https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/configuration/sdk-environment-variables.md#general-sdk-configuration for details.
headers_list: ${OTEL_EXPORTER_OTLP_TRACES_HEADERS}
# Configure span limits. See also attribute_limits.
limits:
# Configure max span attribute value size. Overrides attribute_limits.attribute_value_length_limit.
Expand Down Expand Up @@ -166,8 +169,12 @@ meter_provider:
compression: ${OTEL_EXPORTER_OTLP_METRICS_COMPRESSION:-gzip}
# Configure max time (in milliseconds) to wait for each export.
timeout: ${OTEL_EXPORTER_OTLP_METRICS_TIMEOUT:-10000}
# Configure headers:
# Configure headers.
headers: []
# Configure headers. Entries have lower priority than entries from .headers.
#
# The value is a list of comma separated key-value pairs, matching the format of OTEL_EXPORTER_OTLP_HEADERS, OTEL_EXPORTER_OTLP_METRICS_HEADERS. See https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/configuration/sdk-environment-variables.md#general-sdk-configuration for details.
headers_list: ${OTEL_EXPORTER_OTLP_METRICS_HEADERS}
# Configure temporality preference.
temporality_preference: ${OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCE:-cumulative}
# Configure default histogram aggregation.
Expand Down Expand Up @@ -205,8 +212,12 @@ logger_provider:
compression: ${OTEL_EXPORTER_OTLP_LOGS_COMPRESSION:-gzip}
# Configure max time (in milliseconds) to wait for each export.
timeout: ${OTEL_EXPORTER_OTLP_LOGS_TIMEOUT:-10000}
# Configure headers:
# Configure headers.
headers: []
# Configure headers. Entries have lower priority than entries from .headers.
#
# The value is a list of comma separated key-value pairs, matching the format of OTEL_EXPORTER_OTLP_HEADERS, OTEL_EXPORTER_OTLP_LOGS_HEADERS. See https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/configuration/sdk-environment-variables.md#general-sdk-configuration for details.
headers_list: ${OTEL_EXPORTER_OTLP_LOGS_HEADERS}
# Configure log record limits. See also attribute_limits.
limits:
# Configure max log record attribute value size. Overrides attribute_limits.attribute_value_length_limit.
Expand Down
3 changes: 3 additions & 0 deletions schema/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,9 @@
"$ref": "common.json#/$defs/NameStringValuePair"
}
},
"headers_list": {
"type": ["string", "null"]
},
"compression": {
"type": ["string", "null"]
},
Expand Down
3 changes: 3 additions & 0 deletions schema/meter_provider.json
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,9 @@
"$ref": "common.json#/$defs/NameStringValuePair"
}
},
"headers_list": {
"type": ["string", "null"]
},
"compression": {
"type": ["string", "null"]
},
Expand Down

0 comments on commit ad50656

Please sign in to comment.