Skip to content

Comments

Add typed collector resource attributes based on declarative config#14412

Open
iblancasa wants to merge 22 commits intoopen-telemetry:mainfrom
iblancasa:14411
Open

Add typed collector resource attributes based on declarative config#14412
iblancasa wants to merge 22 commits intoopen-telemetry:mainfrom
iblancasa:14411

Conversation

@iblancasa
Copy link
Contributor

@iblancasa iblancasa commented Jan 12, 2026

Description

Implement OpenTelemetry configuration schema for OpenTelemetry Collector resource attributes.

It keeps backward compatibility.

Link to tracking issue

Updates #14411

@iblancasa iblancasa requested a review from a team as a code owner January 12, 2026 14:18
@iblancasa iblancasa requested a review from bogdandrutu January 12, 2026 14:18
@codecov
Copy link

codecov bot commented Jan 12, 2026

Codecov Report

❌ Patch coverage is 95.95960% with 4 lines in your changes missing coverage. Please review.
✅ Project coverage is 91.83%. Comparing base (95aacc1) to head (76c87b5).

Files with missing lines Patch % Lines
service/internal/resource/config.go 97.87% 1 Missing and 1 partial ⚠️
service/telemetry/otelconftelemetry/resource.go 60.00% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main   #14412   +/-   ##
=======================================
  Coverage   91.83%   91.83%           
=======================================
  Files         679      679           
  Lines       42921    43003   +82     
=======================================
+ Hits        39415    39493   +78     
- Misses       2438     2440    +2     
- Partials     1068     1070    +2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@iblancasa iblancasa force-pushed the 14411 branch 2 times, most recently from aebf0c4 to 81457be Compare January 13, 2026 09:52
@codspeed-hq
Copy link

codspeed-hq bot commented Jan 13, 2026

CodSpeed Performance Report

Merging this PR will not alter performance

Comparing iblancasa:14411 (13daa26) with main (53be17e)1

⚠️ Unknown Walltime execution environment detected

Using the Walltime instrument on standard Hosted Runners will lead to inconsistent data.

For the most accurate results, we recommend using CodSpeed Macro Runners: bare-metal machines fine-tuned for performance measurement consistency.

Summary

✅ 61 untouched benchmarks
⏩ 20 skipped benchmarks2

Footnotes

  1. No successful run was found on main (f857018) during the generation of this report, so 53be17e was used instead as the comparison base. There might be some changes unrelated to this pull request in this report.

  2. 20 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports.

@iblancasa iblancasa changed the title Add support for typed resource attributes in telemetry configuration Introduce new format for resource attributes in telemetry configuration Jan 13, 2026
Signed-off-by: Israel Blancas <iblancasa@gmail.com>
@jade-guiton-dd
Copy link
Contributor

jade-guiton-dd commented Feb 5, 2026

Do you think it would be possible to use configoptional.MapList instead of reimplementing the fallback logic? I'm not sure if it would work for your use case, but just in case you hadn't heard of it.

@iblancasa
Copy link
Contributor Author

Do you think it would be possible to use configoptional.MapList instead of reimplementing the fallback logic? I'm not sure if it would work for your use case, but just in case you hadn't heard of it.

Thanks for the suggestion. You comment actually points to configopaque.MapList.

I looked into it.configopaque.MapList only supports configopaque.String values and doesn’t allow nil. I find this can break backward compatibility. Maybe we can implement something like a configopaque.MapList to solve similar situations like this one?

@iblancasa iblancasa changed the title Introduce new format for resource attributes in telemetry configuration Add typed collector resource attributes based on declarative config Feb 16, 2026
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.

3 participants