63 references to OtlpSpan
Aspire.Dashboard (61)
Components\Controls\Chart\ChartBase.cs (5)
60
private Dictionary<SpanKey,
OtlpSpan
> _currentCache = new Dictionary<SpanKey,
OtlpSpan
>();
61
private Dictionary<SpanKey,
OtlpSpan
> _newCache = new Dictionary<SpanKey,
OtlpSpan
>();
511
_newCache = new Dictionary<SpanKey,
OtlpSpan
>();
Components\Pages\TraceDetail.razor.cs (1)
97
private static Icon GetSpanIcon(
OtlpSpan
span)
Model\MetricsHelpers.cs (2)
18
Func<string, string,
OtlpSpan
?> getSpan,
24
var
span = getSpan(traceId, spanId);
Model\Otlp\SpanWaterfallViewModel.cs (5)
50
public static string GetTitle(
OtlpSpan
span, List<OtlpApplication> allApplications)
55
public static string GetDisplaySummary(
OtlpSpan
span)
125
TraceHelpers.VisitSpans(trace, (
OtlpSpan
span, SpanWaterfallViewModelState s) =>
137
static SpanWaterfallViewModel CreateViewModel(
OtlpSpan
span, int depth, bool hidden, TraceDetailState state)
180
private static string? ResolveUninstrumentedPeerName(
OtlpSpan
span, IEnumerable<IOutgoingPeerResolver> outgoingPeerResolvers)
Model\Otlp\TelemetryFilter.cs (2)
131
public bool Apply(
OtlpSpan
span)
133
var fieldValue =
OtlpSpan
.GetFieldValue(span, Field);
Model\TraceHelpers.cs (7)
13
public static void VisitSpans<TState>(OtlpTrace trace, Func<
OtlpSpan
, TState, TState> spanAction, TState state)
19
var orderByFunc = static (
OtlpSpan
s) => s.StartTime;
28
static void Visit(OtlpSpanCollection allSpans,
OtlpSpan
span, Func<
OtlpSpan
, TState, TState> spanAction, TState state, Func<
OtlpSpan
, DateTime> orderByFunc)
30
foreach (var childSpan in
OtlpSpan
.GetChildSpans(span, allSpans).OrderBy(orderByFunc))
50
VisitSpans(trace, (
OtlpSpan
span, OrderedApplicationsState state) =>
Otlp\Model\OtlpHelpers.cs (5)
337
var address = GetValue(values,
OtlpSpan
.PeerServiceAttributeKey);
344
if (GetValue(values,
OtlpSpan
.ServerAddressAttributeKey) is { } server)
346
if (GetValue(values,
OtlpSpan
.ServerPortAttributeKey) is { } serverPort)
354
if (GetValue(values,
OtlpSpan
.NetPeerNameAttributeKey) is { } peer)
356
if (GetValue(values,
OtlpSpan
.NetPeerPortAttributeKey) is { } peerPort)
Otlp\Model\OtlpSpanCollection.cs (4)
8
public sealed class OtlpSpanCollection : KeyedCollection<string,
OtlpSpan
>
17
protected override string GetKeyForItem(
OtlpSpan
item)
22
public new List<
OtlpSpan
>.Enumerator GetEnumerator()
25
return ((List<
OtlpSpan
>)this.Items).GetEnumerator();
Otlp\Model\OtlpTrace.cs (17)
11
private
OtlpSpan
? _rootSpan;
17
public
OtlpSpan
FirstSpan => Spans[0]; // There should always be at least one span in a trace.
19
public
OtlpSpan
? RootSpan => _rootSpan;
26
foreach (
var
span in Spans)
39
public int CalculateDepth(
OtlpSpan
span)
42
var
currentSpan = span;
53
public void AddSpan(
OtlpSpan
span)
85
foreach (
var
existingSpan in Spans)
103
static string BuildFullName(
OtlpSpan
existingSpan)
109
private static bool HasCircularReference(
OtlpSpan
span)
119
var
currentSpan = span;
140
var
span = Spans[i];
160
foreach (
var
item in trace.Spans)
162
newTrace.AddSpan(
OtlpSpan
.Clone(item, newTrace));
173
private sealed class SpanStartDateComparer : IComparer<
OtlpSpan
>
177
public int Compare(
OtlpSpan
? x,
OtlpSpan
? y)
Otlp\Storage\TelemetryRepository.cs (13)
73
foreach (
var
span in trace.Spans)
529
foreach (
var
span in t.Spans)
579
foreach (
var
span in trace.Spans)
581
var value =
OtlpSpan
.GetFieldValue(span, attributeName);
656
private
OtlpSpan
? GetSpanUnsynchronized(string traceId, string spanId)
663
foreach (
var
span in trace.Spans)
675
public
OtlpSpan
? GetSpan(string traceId, string spanId)
691
foreach (
var
span in t.Spans)
806
var
newSpan = CreateSpan(applicationView, span, trace, scope, _otlpContext);
824
var
linkedSpan = GetSpanUnsynchronized(link.TraceId, link.SpanId);
950
foreach (
var
span in trace.Spans)
976
private static
OtlpSpan
CreateSpan(OtlpApplicationView applicationView, Span span, OtlpTrace trace, OtlpScope scope, OtlpContext context)
1000
var
newSpan = new OtlpSpan(applicationView, trace, scope)
Aspire.Dashboard.Components.Tests (1)
tests\Shared\Telemetry\TelemetryTestHelpers.cs (1)
289
public static
OtlpSpan
CreateSpan(OtlpApplication app, OtlpTrace trace, OtlpScope scope, string spanId, string? parentSpanId, DateTime startDate)
Aspire.Dashboard.Tests (1)
tests\Shared\Telemetry\TelemetryTestHelpers.cs (1)
289
public static
OtlpSpan
CreateSpan(OtlpApplication app, OtlpTrace trace, OtlpScope scope, string spanId, string? parentSpanId, DateTime startDate)