Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Add host.id resource detector #57

Merged
merged 8 commits into from
Apr 2, 2024
Merged

Conversation

alvarocabanas
Copy link
Contributor

@alvarocabanas alvarocabanas commented Mar 22, 2024

Changes

Add the Host Resource detector retrieving the "host.id" as defined in: https://opentelemetry.io/docs/specs/semconv/resource/host/

Defined in #56

Merge requirement checklist

  • CONTRIBUTING guidelines followed
  • Unit tests added/updated (if applicable)
  • Appropriate CHANGELOG.md files updated for non-trivial, user-facing changes
  • Changes in public API reviewed (if applicable)

Co-authored-by: rogercoll rogercoll@users.noreply.github.com

@alvarocabanas alvarocabanas requested a review from a team March 22, 2024 17:25
Copy link

linux-foundation-easycla bot commented Mar 22, 2024

CLA Signed

The committers listed above are authorized under a signed CLA.

@alvarocabanas alvarocabanas changed the title feat: Add host.id resource detector (#56) feat: Add host.id resource detector Mar 22, 2024
@lalitb
Copy link
Member

lalitb commented Mar 22, 2024

The slackdriver build is unrelated to this PR changes - @djc if you know what could be causing this:

error[E0308]: `?` operator has incompatible types
   --> opentelemetry-stackdriver/src/lib.rs:417:28
    |
417 |             authenticator: authenticator.build().await?,
    |                            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `HttpsConnector<HttpConnector>`, found a different `HttpsConnector<HttpConnector>`
    |
    = note: `?` operator cannot convert from `Authenticator<yup_oauth2::hyper_rustls::HttpsConnector<HttpConnector>>` to `Authenticator<hyper_rustls::HttpsConnector<HttpConnector>>`
    = note: `HttpsConnector<HttpConnector>` and `HttpsConnector<HttpConnector>` have similar names, but are actually distinct types
note: `HttpsConnector<HttpConnector>` is defined in crate `hyper_rustls`
   --> /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/hyper-rustls-0.25.0/src/connector.rs:22:1
    |
22  | pub struct HttpsConnector<T> {
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
note: `HttpsConnector<HttpConnector>` is defined in crate `hyper_rustls`
   --> /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/hyper-rustls-0.24.2/src/connector.rs:19:1
    |
19  | pub struct HttpsConnector<T> {
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    = note: perhaps two different versions of crate `hyper_rustls` are being used?

@djc
Copy link
Contributor

djc commented Mar 22, 2024

I think that's because yup-oauth2 made a semver-compatibility mistake... I notified the maintainer.

@cijothomas cijothomas mentioned this pull request Mar 26, 2024
@cijothomas
Copy link
Member

@alvarocabanas Can you fix the CI failures, and we are good to merge. Thank you!

@cijothomas
Copy link
Member

@alvarocabanas Can you fix the CI failures, and we are good to merge. Thank you!

Ooops.. Sorry! CI failure is not your code !

Copy link

codecov bot commented Mar 27, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 52.3%. Comparing base (749bbbe) to head (4abefd8).

Additional details and impacted files
@@           Coverage Diff           @@
##            main     #57     +/-   ##
=======================================
+ Coverage   52.0%   52.3%   +0.2%     
=======================================
  Files         37      38      +1     
  Lines       4938    4967     +29     
=======================================
+ Hits        2569    2598     +29     
  Misses      2369    2369             

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

@cijothomas
Copy link
Member

@alvarocabanas one final lint issue and we are good!

@alvarocabanas
Copy link
Contributor Author

@alvarocabanas one final lint issue and we are good!

Fixed in last commit.

@cijothomas
Copy link
Member

@alvarocabanas one final lint issue and we are good!

Fixed in last commit.

looks like one more. I think the precommit.sh can help catch it locally.

@alvarocabanas
Copy link
Contributor Author

@alvarocabanas one final lint issue and we are good!

Fixed in last commit.

looks like one more. I think the precommit.sh can help catch it locally.

Sure, thanks, now it seems all are fixed.

@hdost hdost merged commit 56a6f45 into open-telemetry:main Apr 2, 2024
9 checks passed
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.

5 participants