open-telemetry / opentelemetry-dotnet-contrib

This repository contains set of components extending functionality of the OpenTelemetry .NET SDK. Instrumentation libraries, exporters, and other components can find their home here.
https://opentelemetry.io
Apache License 2.0
454 stars 273 forks source link

[Instrumentation.ConfluentKafka] Add instrumentation helper methods #1975

Closed g7ed6e closed 1 week ago

g7ed6e commented 2 months ago

Fixes # Design discussion issue #

Changes

Please provide a brief description of the changes here.

Merge requirement checklist

github-actions[bot] commented 1 month ago

This PR was marked stale due to lack of activity. It will be closed in 7 days.

github-actions[bot] commented 1 month ago

Closed as inactive. Feel free to reopen if this PR is still being worked on.

g7ed6e commented 1 month ago

@Kielek we should be able to avoid using reflection if that change in Confluent Kafka get merged. https://github.com/confluentinc/confluent-kafka-dotnet/pull/2023

g7ed6e commented 1 month ago

@vishweshbankwar Can you please re-open this PR ? We still need to add extensibility points before publishing the component.

github-actions[bot] commented 1 month ago

This PR was marked stale due to lack of activity. It will be closed in 7 days.

github-actions[bot] commented 3 weeks ago

This PR was marked stale due to lack of activity. It will be closed in 7 days.

Kielek commented 3 weeks ago

@g7ed6e, could you please resolve conflicts?

codecov[bot] commented 3 weeks ago

Codecov Report

Attention: Patch coverage is 94.31818% with 5 lines in your changes missing coverage. Please review.

Project coverage is 13.32%. Comparing base (71655ce) to head (5071e55). Report is 429 commits behind head on main.

Files with missing lines Patch % Lines
...nstrumentation.ConfluentKafka/ReflectionHelpers.cs 77.77% 4 Missing :warning:
...entKafka/OpenTelemetryProducerBuilderExtensions.cs 97.05% 1 Missing :warning:
Additional details and impacted files [![Impacted file tree graph](https://app.codecov.io/gh/open-telemetry/opentelemetry-dotnet-contrib/pull/1975/graphs/tree.svg?width=650&height=150&src=pr&token=DG2DEROH83&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-telemetry)](https://app.codecov.io/gh/open-telemetry/opentelemetry-dotnet-contrib/pull/1975?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-telemetry) ```diff @@ Coverage Diff @@ ## main #1975 +/- ## =========================================== - Coverage 73.91% 13.32% -60.60% =========================================== Files 267 17 -250 Lines 9615 653 -8962 =========================================== - Hits 7107 87 -7020 + Misses 2508 566 -1942 ``` | [Flag](https://app.codecov.io/gh/open-telemetry/opentelemetry-dotnet-contrib/pull/1975/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-telemetry) | Coverage Δ | | |---|---|---| | [unittests-Instrumentation.ConfluentKafka](https://app.codecov.io/gh/open-telemetry/opentelemetry-dotnet-contrib/pull/1975/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-telemetry) | `13.32% <94.31%> (?)` | | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-telemetry#carryforward-flags-in-the-pull-request-comment) to find out more. | [Files with missing lines](https://app.codecov.io/gh/open-telemetry/opentelemetry-dotnet-contrib/pull/1975?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-telemetry) | Coverage Δ | | |---|---|---| | [...uentKafka/ConfluentKafkaConsumerInstrumentation.cs](https://app.codecov.io/gh/open-telemetry/opentelemetry-dotnet-contrib/pull/1975?src=pr&el=tree&filepath=src%2FOpenTelemetry.Instrumentation.ConfluentKafka%2FConfluentKafkaConsumerInstrumentation.cs&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-telemetry#diff-c3JjL09wZW5UZWxlbWV0cnkuSW5zdHJ1bWVudGF0aW9uLkNvbmZsdWVudEthZmthL0NvbmZsdWVudEthZmthQ29uc3VtZXJJbnN0cnVtZW50YXRpb24uY3M=) | `0.00% <ø> (ø)` | | | [...uentKafka/ConfluentKafkaProducerInstrumentation.cs](https://app.codecov.io/gh/open-telemetry/opentelemetry-dotnet-contrib/pull/1975?src=pr&el=tree&filepath=src%2FOpenTelemetry.Instrumentation.ConfluentKafka%2FConfluentKafkaProducerInstrumentation.cs&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-telemetry#diff-c3JjL09wZW5UZWxlbWV0cnkuSW5zdHJ1bWVudGF0aW9uLkNvbmZsdWVudEthZmthL0NvbmZsdWVudEthZmthUHJvZHVjZXJJbnN0cnVtZW50YXRpb24uY3M=) | `0.00% <ø> (ø)` | | | [...tion.ConfluentKafka/InstrumentedConsumerBuilder.cs](https://app.codecov.io/gh/open-telemetry/opentelemetry-dotnet-contrib/pull/1975?src=pr&el=tree&filepath=src%2FOpenTelemetry.Instrumentation.ConfluentKafka%2FInstrumentedConsumerBuilder.cs&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-telemetry#diff-c3JjL09wZW5UZWxlbWV0cnkuSW5zdHJ1bWVudGF0aW9uLkNvbmZsdWVudEthZmthL0luc3RydW1lbnRlZENvbnN1bWVyQnVpbGRlci5jcw==) | `28.57% <ø> (ø)` | | | [...tion.ConfluentKafka/InstrumentedProducerBuilder.cs](https://app.codecov.io/gh/open-telemetry/opentelemetry-dotnet-contrib/pull/1975?src=pr&el=tree&filepath=src%2FOpenTelemetry.Instrumentation.ConfluentKafka%2FInstrumentedProducerBuilder.cs&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-telemetry#diff-c3JjL09wZW5UZWxlbWV0cnkuSW5zdHJ1bWVudGF0aW9uLkNvbmZsdWVudEthZmthL0luc3RydW1lbnRlZFByb2R1Y2VyQnVpbGRlci5jcw==) | `50.00% <ø> (ø)` | | | [...ntKafka/MeterProviderBuilderExtensions.Consumer.cs](https://app.codecov.io/gh/open-telemetry/opentelemetry-dotnet-contrib/pull/1975?src=pr&el=tree&filepath=src%2FOpenTelemetry.Instrumentation.ConfluentKafka%2FMeterProviderBuilderExtensions.Consumer.cs&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-telemetry#diff-c3JjL09wZW5UZWxlbWV0cnkuSW5zdHJ1bWVudGF0aW9uLkNvbmZsdWVudEthZmthL01ldGVyUHJvdmlkZXJCdWlsZGVyRXh0ZW5zaW9ucy5Db25zdW1lci5jcw==) | `0.00% <ø> (ø)` | | | [...ntKafka/MeterProviderBuilderExtensions.Producer.cs](https://app.codecov.io/gh/open-telemetry/opentelemetry-dotnet-contrib/pull/1975?src=pr&el=tree&filepath=src%2FOpenTelemetry.Instrumentation.ConfluentKafka%2FMeterProviderBuilderExtensions.Producer.cs&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-telemetry#diff-c3JjL09wZW5UZWxlbWV0cnkuSW5zdHJ1bWVudGF0aW9uLkNvbmZsdWVudEthZmthL01ldGVyUHJvdmlkZXJCdWlsZGVyRXh0ZW5zaW9ucy5Qcm9kdWNlci5jcw==) | `0.00% <ø> (ø)` | | | [...entKafka/OpenTelemetryConsumerBuilderExtensions.cs](https://app.codecov.io/gh/open-telemetry/opentelemetry-dotnet-contrib/pull/1975?src=pr&el=tree&filepath=src%2FOpenTelemetry.Instrumentation.ConfluentKafka%2FOpenTelemetryConsumerBuilderExtensions.cs&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-telemetry#diff-c3JjL09wZW5UZWxlbWV0cnkuSW5zdHJ1bWVudGF0aW9uLkNvbmZsdWVudEthZmthL09wZW5UZWxlbWV0cnlDb25zdW1lckJ1aWxkZXJFeHRlbnNpb25zLmNz) | `100.00% <100.00%> (ø)` | | | [...tKafka/TracerProviderBuilderExtensions.Consumer.cs](https://app.codecov.io/gh/open-telemetry/opentelemetry-dotnet-contrib/pull/1975?src=pr&el=tree&filepath=src%2FOpenTelemetry.Instrumentation.ConfluentKafka%2FTracerProviderBuilderExtensions.Consumer.cs&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-telemetry#diff-c3JjL09wZW5UZWxlbWV0cnkuSW5zdHJ1bWVudGF0aW9uLkNvbmZsdWVudEthZmthL1RyYWNlclByb3ZpZGVyQnVpbGRlckV4dGVuc2lvbnMuQ29uc3VtZXIuY3M=) | `0.00% <ø> (ø)` | | | [...tKafka/TracerProviderBuilderExtensions.Producer.cs](https://app.codecov.io/gh/open-telemetry/opentelemetry-dotnet-contrib/pull/1975?src=pr&el=tree&filepath=src%2FOpenTelemetry.Instrumentation.ConfluentKafka%2FTracerProviderBuilderExtensions.Producer.cs&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-telemetry#diff-c3JjL09wZW5UZWxlbWV0cnkuSW5zdHJ1bWVudGF0aW9uLkNvbmZsdWVudEthZmthL1RyYWNlclByb3ZpZGVyQnVpbGRlckV4dGVuc2lvbnMuUHJvZHVjZXIuY3M=) | `0.00% <ø> (ø)` | | | [...entKafka/OpenTelemetryProducerBuilderExtensions.cs](https://app.codecov.io/gh/open-telemetry/opentelemetry-dotnet-contrib/pull/1975?src=pr&el=tree&filepath=src%2FOpenTelemetry.Instrumentation.ConfluentKafka%2FOpenTelemetryProducerBuilderExtensions.cs&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-telemetry#diff-c3JjL09wZW5UZWxlbWV0cnkuSW5zdHJ1bWVudGF0aW9uLkNvbmZsdWVudEthZmthL09wZW5UZWxlbWV0cnlQcm9kdWNlckJ1aWxkZXJFeHRlbnNpb25zLmNz) | `97.05% <97.05%> (ø)` | | | ... and [1 more](https://app.codecov.io/gh/open-telemetry/opentelemetry-dotnet-contrib/pull/1975?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-telemetry) | | ... and [273 files with indirect coverage changes](https://app.codecov.io/gh/open-telemetry/opentelemetry-dotnet-contrib/pull/1975/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-telemetry)
Kielek commented 2 weeks ago

@birojnayak, could you please help with review?

Kielek commented 2 weeks ago

@open-telemetry/dotnet-contrib-approvers, I would relay on @birojnayak review. If there will be no other comments I will merge it on Monday.