Add OTLP protocol telemetry options#1648
Draft
loganrosen wants to merge 1 commit into
Draft
Conversation
Expose OTLP HTTP protocol selection through each SDK telemetry config and map the values to the standard OpenTelemetry protocol environment variables when spawning the Copilot CLI. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
OTEL_EXPORTER_OTLP_PROTOCOL,OTEL_EXPORTER_OTLP_TRACES_PROTOCOL, andOTEL_EXPORTER_OTLP_METRICS_PROTOCOLwhen the SDK spawns the Copilot CLI.Testing
just installjust formatcd java && mvn spotless:applycd java && mvn verifycd nodejs && npm test -- --run test/telemetry.test.ts test/e2e/client_options.e2e.test.ts -t "TelemetryConfig env var mapping|should propagate process options"cd nodejs && npm test -- --run test/e2e/client_options.e2e.test.ts -t "should only set configured otlp protocol env vars|should propagate process options"cd python && uv run pytest ../python/test_telemetry.py -qcd python && uv run pytest ../python/e2e/test_client_options_e2e.py::TestClientOptions::test_should_propagate_process_options_to_spawned_cli -qcd python && uv run pytest ../python/e2e/test_client_options_e2e.py::TestClientOptions::test_should_only_set_configured_otlp_protocol_env_vars ../python/e2e/test_client_options_e2e.py::TestClientOptions::test_should_propagate_process_options_to_spawned_cli -qcd go && go test . && go test ./internal/e2e -run 'TestTelemetryConfigUnit|TestClientOptionsE2E'cd go && go test ./internal/e2e -run 'TestClientOptionsE2E/should_(only_set_configured_OTLP_protocol_env_vars|propagate_process_options_to_spawned_cli)'cd dotnet && dotnet test test/GitHub.Copilot.SDK.Test.csproj --filter "FullyQualifiedName~GitHub.Copilot.Test.Unit.TelemetryTests|FullyQualifiedName~Should_Propagate_Process_Options_To_Spawned_Cli"cd dotnet && dotnet test test/GitHub.Copilot.SDK.Test.csproj --filter "FullyQualifiedName~Should_Only_Set_Configured_Otlp_Protocol_Env_Vars|FullyQualifiedName~Should_Propagate_Process_Options_To_Spawned_Cli"cd rust && cargo test --features test-support --libcd rust && cargo test --features test-support --lib telemetry_config && cargo test --features test-support --lib build_commandNote: full auth-dependent local E2E runs hit harness/auth isolation without
GITHUB_ACTIONS=true, so validation focused on the affected telemetry mapping paths.