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

Diagnostics: Removes unused properties and reduces size #3519

Merged
merged 12 commits into from
Nov 2, 2022
Merged
Original file line number Diff line number Diff line change
Expand Up @@ -40,17 +40,13 @@ public static void WriteTrace(
writer.WriteFieldName("Summary");
SummaryDiagnostics summaryDiagnostics = new SummaryDiagnostics(trace);
summaryDiagnostics.WriteSummaryDiagnostics(writer);
writer.WriteFieldName("start time");
writer.WriteStringValue(trace.StartTime.ToString("hh:mm:ss:fff"));
aavasthy marked this conversation as resolved.
Show resolved Hide resolved
aavasthy marked this conversation as resolved.
Show resolved Hide resolved
}

writer.WriteFieldName("name");
writer.WriteStringValue(trace.Name);

writer.WriteFieldName("id");
aavasthy marked this conversation as resolved.
Show resolved Hide resolved
writer.WriteStringValue(trace.Id.ToString());

writer.WriteFieldName("start time");
writer.WriteStringValue(trace.StartTime.ToString("hh:mm:ss:fff"));
aavasthy marked this conversation as resolved.
Show resolved Hide resolved

writer.WriteFieldName("duration in milliseconds");
writer.WriteNumber64Value(trace.Duration.TotalMilliseconds);

Expand Down Expand Up @@ -78,8 +74,8 @@ public static void WriteTrace(

foreach (ITrace child in trace.Children)
{
WriteTrace(writer,
ealsur marked this conversation as resolved.
Show resolved Hide resolved
child,
WriteTrace(writer,
child,
isRootTrace: false);
}

Expand Down Expand Up @@ -208,7 +204,7 @@ public void Visit(ClientSideRequestStatisticsTraceDatum clientSideRequestStatist

foreach (KeyValuePair<string, ClientSideRequestStatisticsTraceDatum.AddressResolutionStatistics> stat in clientSideRequestStatisticsTraceDatum.EndpointToAddressResolutionStatistics)
{
this.VisitAddressResolutionStatistics(stat.Value);
this.VisitAddressResolutionStatistics(stat.Value);
aavasthy marked this conversation as resolved.
Show resolved Hide resolved
}

this.jsonWriter.WriteArrayEnd();
Expand Down Expand Up @@ -536,7 +532,7 @@ private void WriteJsonUriArrayWithDuplicatesCounted(string propertyName, IReadOn
}
}

foreach (KeyValuePair<TransportAddressUri, int> contactedCount in uriCount)
ealsur marked this conversation as resolved.
Show resolved Hide resolved
foreach (KeyValuePair<TransportAddressUri, int> contactedCount in uriCount)
{
this.jsonWriter.WriteObjectStart();
this.jsonWriter.WriteFieldName("Count");
Expand Down