Add OpenTelemetry tracing instrumentation for SqlClient
Open
area-integrations
sqlserver
- Dominant language
- C#
- Stars
- 6.3k
- Forks
- 991
- Avg merge
- 2d 15h
- Merged PRs (30d)
- 196
Description
SqlClient itself doesn't emit OpenTelemetry tracing, but an [instrumentation package](https://github.com/open-telemetry/opentelemetry-dotnet/blob/main/src/OpenTelemetry.Instrumentation.SqlClient/README.md) exists for that; this emits traces for each command executed.
Aspire.Microsoft.Data.SqlClient currently wires up [event counter-based metrics](https://github.com/dotnet/aspire/blob/main/src/Components/Aspire.Microsoft.Data.SqlClient/AspireSqlServerSqlClientExtensions.cs#L95), but does not wire up tracing - we should add that to get traces out-of-the-box.
/cc @AndriySvyryd
Contributor guide
Assessment
This issue has not been assessed yet.