Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,12 @@ protected override void WriteArrayTag(ref ConsoleTag consoleTag, string key, Arr
consoleTag.Value = Encoding.UTF8.GetString(arrayUtf8JsonBytes.Array!, 0, arrayUtf8JsonBytes.Count);
}

protected override void WriteKvlistTag(ref ConsoleTag consoleTag, string key, ArraySegment<byte> kvlistUtf8JsonBytes)
{
consoleTag.Key = key;
consoleTag.Value = Encoding.UTF8.GetString(kvlistUtf8JsonBytes.Array!, 0, kvlistUtf8JsonBytes.Count);
}

protected override void OnUnsupportedTagDropped(
string tagKey,
string tagValueTypeFullName)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,6 @@ internal static class ProtobufOtlpCommonFieldNumberConstants
internal const int AnyValue_Bytes_Value = 7;

internal const int ArrayValue_Value = 1;

internal const int KeyValueList_Values = 1;
}

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
<ItemGroup>
<Compile Include="$(RepoRoot)\src\Shared\PeriodicExportingMetricReaderHelper.cs" Link="Includes\PeriodicExportingMetricReaderHelper.cs" />
<Compile Include="$(RepoRoot)\src\Shared\TagWriter\ArrayTagWriter.cs" Link="Includes\TagWriter\ArrayTagWriter.cs" />
<Compile Include="$(RepoRoot)\src\Shared\TagWriter\KvlistTagWriter.cs" Link="Includes\TagWriter\KvlistTagWriter.cs" />
<Compile Include="$(RepoRoot)\src\Shared\TagWriter\TagWriter.cs" Link="Includes\TagWriter\TagWriter.cs" />
</ItemGroup>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,12 @@ protected override void WriteArrayTag(ref Utf8JsonWriter writer, string key, Arr
writer.WriteStringValue(arrayUtf8JsonBytes);
}

protected override void WriteKvlistTag(ref Utf8JsonWriter writer, string key, ArraySegment<byte> kvlistUtf8JsonBytes)
{
writer.WritePropertyName(key);
writer.WriteStringValue(kvlistUtf8JsonBytes);
}

protected override void OnUnsupportedTagDropped(
string tagKey,
string tagValueTypeFullName)
Expand Down
132 changes: 130 additions & 2 deletions src/Shared/TagWriter/JsonStringArrayTagWriter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@

namespace OpenTelemetry.Internal;

internal abstract class JsonStringArrayTagWriter<TTagState> : TagWriter<TTagState, JsonStringArrayTagWriter<TTagState>.JsonArrayTagWriterState>
internal abstract class JsonStringArrayTagWriter<TTagState> : TagWriter<TTagState, JsonStringArrayTagWriter<TTagState>.JsonArrayTagWriterState, JsonStringArrayTagWriter<TTagState>.JsonKvlistTagWriterState>
where TTagState : notnull
{
protected JsonStringArrayTagWriter()
: base(new JsonArrayTagWriter())
: base(new JsonArrayTagWriter(), new JsonKvlistTagWriter())
{
}

Expand All @@ -23,8 +23,19 @@
this.WriteArrayTag(ref writer, key, buffer);
}

protected sealed override void WriteKvlistTag(ref TTagState writer, string key, ref JsonKvlistTagWriterState kvlist)
{
var result = kvlist.Stream.TryGetBuffer(out var buffer);

Debug.Assert(result, "result was false");

this.WriteKvlistTag(ref writer, key, buffer);
}

protected abstract void WriteArrayTag(ref TTagState writer, string key, ArraySegment<byte> arrayUtf8JsonBytes);

protected abstract void WriteKvlistTag(ref TTagState writer, string key, ArraySegment<byte> kvlistUtf8JsonBytes);

protected override bool TryWriteByteArrayTag(ref TTagState consoleTag, string key, ReadOnlySpan<byte> value) => false;

internal readonly struct JsonArrayTagWriterState(MemoryStream stream, Utf8JsonWriter writer)
Expand All @@ -34,6 +45,15 @@
public Utf8JsonWriter Writer { get; } = writer;
}

internal readonly struct JsonKvlistTagWriterState(MemoryStream stream, Utf8JsonWriter writer, int nestingLevel)
{
public MemoryStream Stream { get; } = stream;

public Utf8JsonWriter Writer { get; } = writer;

public int NestingLevel { get; } = nestingLevel;
}

internal sealed class JsonArrayTagWriter : ArrayTagWriter<JsonArrayTagWriterState>
{
[ThreadStatic]
Expand Down Expand Up @@ -96,4 +116,112 @@
}
}
}

internal sealed class JsonKvlistTagWriter : KvlistTagWriter<JsonKvlistTagWriterState>
{
[ThreadStatic]
private static MemoryStream? threadStream;

[ThreadStatic]
private static Utf8JsonWriter? threadWriter;

[ThreadStatic]
private static int nestingLevel;

public override JsonKvlistTagWriterState BeginWriteKvlist()
{
MemoryStream stream;
Utf8JsonWriter writer;

if (nestingLevel == 0)
{
// Top-level kvlist: use ThreadStatic buffer
if (threadStream == null)
{
threadStream = new MemoryStream();
threadWriter = new Utf8JsonWriter(threadStream);
}
else
{
threadStream.SetLength(0);
threadWriter!.Reset(threadStream);
}

stream = threadStream;
writer = threadWriter!;
}
else
{
// Nested kvlist: allocate new buffer to avoid corrupting parent
stream = new MemoryStream();
writer = new Utf8JsonWriter(stream);

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / concurrency-tests / run-concurrency-tests (ubuntu-22.04, net8.0, OpenTelemetry.Tests)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / concurrency-tests / run-concurrency-tests (ubuntu-22.04, net8.0, OpenTelemetry.Tests)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / concurrency-tests / run-concurrency-tests (ubuntu-22.04, net8.0, OpenTelemetry.Tests)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / concurrency-tests / run-concurrency-tests (ubuntu-22.04, net8.0, OpenTelemetry.Tests)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / concurrency-tests / run-concurrency-tests (ubuntu-22.04, net10.0, OpenTelemetry.Tests)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / concurrency-tests / run-concurrency-tests (ubuntu-22.04, net10.0, OpenTelemetry.Tests)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / concurrency-tests / run-concurrency-tests (ubuntu-22.04, net10.0, OpenTelemetry.Tests)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / concurrency-tests / run-concurrency-tests (ubuntu-22.04, net10.0, OpenTelemetry.Tests)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / concurrency-tests / run-concurrency-tests (windows-latest, net8.0, OpenTelemetry.Tests)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / concurrency-tests / run-concurrency-tests (windows-latest, net8.0, OpenTelemetry.Tests)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / concurrency-tests / run-concurrency-tests (windows-latest, net8.0, OpenTelemetry.Tests)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / concurrency-tests / run-concurrency-tests (windows-latest, net8.0, OpenTelemetry.Tests)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / validate-packages / run-package-validation-stable

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / validate-packages / run-package-validation-stable

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / validate-packages / run-package-validation-stable

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / validate-packages / run-package-validation-stable

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / validate-packages / run-package-validation-stable

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (ubuntu-22.04, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (ubuntu-22.04, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (ubuntu-22.04, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (ubuntu-22.04, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (ubuntu-22.04, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (ubuntu-22.04, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (ubuntu-22.04, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (ubuntu-22.04, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / validate-packages / run-package-validation-experimental

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / validate-packages / run-package-validation-experimental

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / validate-packages / run-package-validation-experimental

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / validate-packages / run-package-validation-experimental

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / validate-packages / run-package-validation-experimental

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (ubuntu-22.04, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (ubuntu-22.04, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (ubuntu-22.04, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (ubuntu-22.04, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (ubuntu-22.04-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (ubuntu-22.04-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (ubuntu-22.04-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (ubuntu-22.04-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (ubuntu-22.04-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (ubuntu-22.04-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (ubuntu-22.04-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (ubuntu-22.04-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (ubuntu-22.04-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (ubuntu-22.04-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (ubuntu-22.04-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (ubuntu-22.04-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (ubuntu-22.04, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (ubuntu-22.04, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (ubuntu-22.04, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (ubuntu-22.04, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (ubuntu-22.04, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (ubuntu-22.04, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (ubuntu-22.04, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (ubuntu-22.04, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / concurrency-tests / run-concurrency-tests (windows-latest, net10.0, OpenTelemetry.Tests)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / concurrency-tests / run-concurrency-tests (windows-latest, net10.0, OpenTelemetry.Tests)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / concurrency-tests / run-concurrency-tests (windows-latest, net10.0, OpenTelemetry.Tests)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / concurrency-tests / run-concurrency-tests (windows-latest, net10.0, OpenTelemetry.Tests)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (ubuntu-22.04-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (ubuntu-22.04-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (ubuntu-22.04-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (ubuntu-22.04-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (ubuntu-22.04, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (ubuntu-22.04, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (ubuntu-22.04, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (ubuntu-22.04, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (ubuntu-22.04, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (ubuntu-22.04, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (ubuntu-22.04, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (ubuntu-22.04, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (ubuntu-22.04-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (ubuntu-22.04-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (ubuntu-22.04-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (ubuntu-22.04-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (ubuntu-22.04-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (ubuntu-22.04-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (ubuntu-22.04-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (ubuntu-22.04-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (ubuntu-22.04, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (ubuntu-22.04, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (ubuntu-22.04, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (ubuntu-22.04, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (ubuntu-22.04, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (ubuntu-22.04, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (ubuntu-22.04, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (ubuntu-22.04, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-latest, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-latest, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-latest, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-latest, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-latest, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-latest, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-latest, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-latest, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-latest, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-latest, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-latest, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-latest, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-latest, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-latest, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-latest, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-latest, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-latest, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-latest, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-latest, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-latest, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-latest, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-latest, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-latest, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-latest, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-latest, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-latest, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-latest, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-latest, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-latest, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-latest, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-latest, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-latest, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-latest, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-latest, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-latest, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-latest, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-latest, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-latest, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-latest, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-latest, net10.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-latest, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-latest, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-latest, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-latest, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-11-arm, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-11-arm, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-11-arm, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-11-arm, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-11-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-11-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-11-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-11-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-latest, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-latest, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-latest, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-latest, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-11-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-11-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-11-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-11-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-11-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-11-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-11-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-solution / build-test (windows-11-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-11-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-11-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-11-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-11-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-11-arm, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-11-arm, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-11-arm, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-stable / build-test (windows-11-arm, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-11-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-11-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-11-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-11-arm, net9.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-11-arm, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-11-arm, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-11-arm, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-11-arm, net462)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-11-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-11-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-11-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)

Check failure on line 157 in src/Shared/TagWriter/JsonStringArrayTagWriter.cs

View workflow job for this annotation

GitHub Actions / build-test-project-experimental / build-test (windows-11-arm, net8.0)

Call System.IDisposable.Dispose on object created by 'new Utf8JsonWriter(stream)' before all references to it are out of scope (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)
}

nestingLevel++;

writer.WriteStartObject();
return new(stream, writer, nestingLevel);
}

public override void EndWriteKvlist(ref JsonKvlistTagWriterState state)
{
state.Writer.WriteEndObject();
state.Writer.Flush();
nestingLevel--;
}

public override void WriteBooleanValue(ref JsonKvlistTagWriterState state, string key, bool value)
{
state.Writer.WriteBoolean(key, value);
}

public override void WriteFloatingPointValue(ref JsonKvlistTagWriterState state, string key, double value)
{
state.Writer.WriteNumber(key, value);
}

public override void WriteIntegralValue(ref JsonKvlistTagWriterState state, string key, long value)
{
state.Writer.WriteNumber(key, value);
}

public override void WriteNullValue(ref JsonKvlistTagWriterState state, string key)
{
state.Writer.WriteNull(key);
}

public override void WriteStringValue(ref JsonKvlistTagWriterState state, string key, ReadOnlySpan<char> value)
{
state.Writer.WriteString(key, value);
}

public override void WriteArrayValue<TArrayState>(ref JsonKvlistTagWriterState state, string key, ref TArrayState arrayState)
{
if (arrayState is JsonArrayTagWriterState jsonArrayState)
{
var result = jsonArrayState.Stream.TryGetBuffer(out var buffer);
Debug.Assert(result, "result was false");
state.Writer.WritePropertyName(key);
#if NET6_0_OR_GREATER
state.Writer.WriteRawValue(buffer);
#else
using var doc = JsonDocument.Parse(buffer);
doc.RootElement.WriteTo(state.Writer);
#endif
}
}

public override void WriteKvlistValue(ref JsonKvlistTagWriterState state, string key, ref JsonKvlistTagWriterState nestedKvlistState)
{
var result = nestedKvlistState.Stream.TryGetBuffer(out var buffer);
Debug.Assert(result, "result was false");
state.Writer.WritePropertyName(key);
#if NET6_0_OR_GREATER
state.Writer.WriteRawValue(buffer);
#else
using var doc = JsonDocument.Parse(buffer);
doc.RootElement.WriteTo(state.Writer);
#endif
}
}
}
29 changes: 29 additions & 0 deletions src/Shared/TagWriter/KvlistTagWriter.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

namespace OpenTelemetry.Internal;

internal abstract class KvlistTagWriter<TKvlistState>
where TKvlistState : notnull
{
public abstract TKvlistState BeginWriteKvlist();

public abstract void WriteNullValue(ref TKvlistState state, string key);

public abstract void WriteIntegralValue(ref TKvlistState state, string key, long value);

public abstract void WriteFloatingPointValue(ref TKvlistState state, string key, double value);

public abstract void WriteBooleanValue(ref TKvlistState state, string key, bool value);

public abstract void WriteStringValue(ref TKvlistState state, string key, ReadOnlySpan<char> value);

public abstract void WriteArrayValue<TArrayState>(ref TKvlistState state, string key, ref TArrayState arrayState)
where TArrayState : notnull;

public abstract void WriteKvlistValue(ref TKvlistState state, string key, ref TKvlistState nestedKvlistState);

public abstract void EndWriteKvlist(ref TKvlistState state);

public virtual bool TryResize() => false;
}
Loading
Loading