opentelemetry-dotnet icon indicating copy to clipboard operation
opentelemetry-dotnet copied to clipboard

[shared] Remove TagTransformer and improve TagWriter

Open CodeBlanch opened this issue 1 year ago • 1 comments

Follow-up to #5476 Relates to #5475

Changes

  • Removes TagTransformer as everything is now using TagWriter
  • Converts JsonStringArray tests to use TagWriter and fix bugs that manifested
  • Uses ReadOnlySpan<char> for strings in TagWriter to make it possible to bypass allocations when writing chars orstrings which get trimmed due to length limits

Merge requirement checklist

  • [X] CONTRIBUTING guidelines followed (license requirements, nullable enabled, static analysis, etc.)
  • [X] Unit tests added/updated

CodeBlanch avatar May 10 '24 05:05 CodeBlanch

Codecov Report

Attention: Patch coverage is 66.66667% with 1 lines in your changes are missing coverage. Please review.

Project coverage is 85.69%. Comparing base (6250307) to head (f2adebc). Report is 223 commits behind head on main.

:exclamation: Current head f2adebc differs from pull request most recent head eb86a50. Consider uploading reports for the commit eb86a50 to get more accurate results

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #5602      +/-   ##
==========================================
+ Coverage   83.38%   85.69%   +2.30%     
==========================================
  Files         297      254      -43     
  Lines       12531    10979    -1552     
==========================================
- Hits        10449     9408    -1041     
+ Misses       2082     1571     -511     
Flag Coverage Δ
unittests ?
unittests-Solution-Experimental 85.64% <66.66%> (?)
unittests-Solution-Stable 85.65% <66.66%> (?)
unittests-Unstable-Core 19.91% <ø> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Coverage Δ
...nTelemetryProtocol/Implementation/OtlpTagWriter.cs 100.00% <100.00%> (ø)
....Exporter.Zipkin/Implementation/ZipkinTagWriter.cs 63.63% <ø> (ø)
...xporter.Console/Implementation/ConsoleTagWriter.cs 11.53% <0.00%> (ø)

... and 112 files with indirect coverage changes

codecov[bot] avatar May 10 '24 05:05 codecov[bot]