Skip to content

Updated ECS detector containerID logic#7607

Merged
dmathieu merged 5 commits intoopen-telemetry:mainfrom
akats7:ecs-detector-fix
Jul 28, 2025
Merged

Updated ECS detector containerID logic#7607
dmathieu merged 5 commits intoopen-telemetry:mainfrom
akats7:ecs-detector-fix

Conversation

@akats7
Copy link
Copy Markdown
Contributor

@akats7 akats7 commented Jul 22, 2025

Update the ECS detector to properly extract the containerID from cgroup file.

Resolves #7500

Failing tests in opentelemetry-go-contrib/detectors/aws/ecs/test/ecs_test.go were due to incorrect logic pertaining to cgroup paths on valid ecs containers vs other non empty values

Added tests for extracting containerIDs from various cgroup path values

@akats7 akats7 requested a review from a team as a code owner July 22, 2025 01:50
@github-actions github-actions Bot requested a review from pyohannes July 22, 2025 01:50
@codecov
Copy link
Copy Markdown

codecov Bot commented Jul 22, 2025

Codecov Report

❌ Patch coverage is 87.50000% with 1 line in your changes missing coverage. Please review.
⚠️ Please upload report for BASE (main@9062a3c). Learn more about missing BASE report.
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
detectors/aws/ecs/ecs.go 87.5% 1 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@          Coverage Diff           @@
##             main   #7607   +/-   ##
======================================
  Coverage        ?   78.7%           
======================================
  Files           ?     186           
  Lines           ?   14818           
  Branches        ?       0           
======================================
  Hits            ?   11672           
  Misses          ?    2798           
  Partials        ?     348           
Files with missing lines Coverage Δ
detectors/aws/ecs/ecs.go 64.8% <87.5%> (ø)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Comment thread CHANGELOG.md Outdated
Comment thread CHANGELOG.md Outdated
Comment thread detectors/aws/ecs/ecs.go Outdated
Copy link
Copy Markdown
Member

@flc1125 flc1125 left a comment

Choose a reason for hiding this comment

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

Nice

@dmathieu dmathieu merged commit 593f386 into open-telemetry:main Jul 28, 2025
29 checks passed
@MrAlias MrAlias added this to the v1.38.0 milestone Aug 20, 2025
@MrAlias MrAlias mentioned this pull request Aug 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

detectors/aws/ecs tests are failing locally

5 participants