Fix Container Insights logs - #2221
Open
Paamicky wants to merge 3 commits into
Open
Conversation
Paamicky
marked this pull request as ready for review
July 30, 2026 18:11
Contributor
Binary Size Reportlinux/amd64
linux/arm64
windows/amd64
Investigating size changesUse go-size-analyzer to compare binaries: GOEXPERIMENT=jsonv2 go install github.com/Zxilly/go-size-analyzer/cmd/gsa@latest
gsa diff --old <baseline-binary> --new <new-binary> |
jefchien
reviewed
Jul 30, 2026
Comment on lines
+4
to
+23
| otlphttp/cw_k8s_ci_v0_app_logs_dest: | ||
| auth: | ||
| authenticator: headers_setter/cw_k8s_ci_v0_app_logs | ||
| compression: none | ||
| endpoint: https://logs.us-east-1.amazonaws.com:443 | ||
| sending_queue: | ||
| num_consumers: 10 | ||
| queue_size: 500 | ||
| tls: | ||
| insecure: false | ||
| otlphttp/cw_k8s_ci_v0_node_logs_dest: | ||
| auth: | ||
| authenticator: headers_setter/cw_k8s_ci_v0_node_logs | ||
| compression: none | ||
| endpoint: https://logs.us-east-1.amazonaws.com:443 | ||
| sending_queue: | ||
| num_consumers: 10 | ||
| queue_size: 500 | ||
| tls: | ||
| insecure: false |
Contributor
There was a problem hiding this comment.
Any reason why we have separate exporters for this?
Contributor
Author
There was a problem hiding this comment.
fixed to use shared logs pipelines
Comment on lines
+64
to
+81
| headers_setter/cw_k8s_ci_v0_app_logs: | ||
| additional_auth: awscloudwatchlogsprovisioner/cw_k8s_ci_v0_logs | ||
| headers: | ||
| - action: upsert | ||
| from_context: aws.log.group.name | ||
| key: x-aws-log-group | ||
| - action: upsert | ||
| from_context: aws.log.stream.name | ||
| key: x-aws-log-stream | ||
| headers_setter/cw_k8s_ci_v0_node_logs: | ||
| additional_auth: awscloudwatchlogsprovisioner/cw_k8s_ci_v0_logs | ||
| headers: | ||
| - action: upsert | ||
| from_context: aws.log.group.name | ||
| key: x-aws-log-group | ||
| - action: upsert | ||
| from_context: aws.log.stream.name | ||
| key: x-aws-log-stream |
Contributor
There was a problem hiding this comment.
These are exactly the same.
Contributor
Author
There was a problem hiding this comment.
fixed to use shared logs pipelines
Comment on lines
+87
to
+89
| sigv4auth/cw_k8s_ci_v0_logs_dest: | ||
| region: us-east-1 | ||
| service: logs |
Contributor
There was a problem hiding this comment.
Should use the shared sigv4auth extension.
Contributor
Author
There was a problem hiding this comment.
fixed to use shared logs pipelines
Paamicky
force-pushed
the
mcommey/containerinsights
branch
from
July 31, 2026 17:38
6e5be83 to
71244d2
Compare
Paamicky
force-pushed
the
mcommey/containerinsights
branch
from
July 31, 2026 17:55
fc9cd9b to
c80cee5
Compare
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.
Description of changes
Container Insights logs enabled via the OTEL path (role: node + logs.enabled: true) never reach CloudWatch, the exporter 400s with "log group cannot be null or empty" and records are dropped. Root cause:
batch/cw_k8s_ci_v0_logs_desthad nometadata_keys, so the batch processor discards the request context. That dropsaws.log.group.name/aws.log.stream.name, so headers_setter emits an empty x-aws-log-group headerTo fix this, we refactor the CI log pipelines into source pipelines that forward into the existing shared
logs/opentelemetryexport pipeline. That shared pipeline already has the correct batch withmetadata_keyswhich fixes the bugs and CI logs reach CloudWatch now.Changes:
awscloudwatchlogsprovisioner, otlphttp/*_logs_dest, batch, andattributestocontext.containerinsights.HasLogPipelinescontainer_insights_node_config(role node, logs on) andcontainer_insights_cluster_config(role cluster) and regenerate expected YAMLs.License
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
Tests
/aws/otel/containerinsights/mcommey-otelci-shared/applicationcreated,