4 writes to Attributes
Aspire.Dashboard (2)
Otlp\Model\OtlpSpan.cs (1)
93Attributes = item.Attributes,
Otlp\Storage\TelemetryRepository.cs (1)
1246Attributes = span.Attributes.ToKeyValuePairs(context),
Aspire.Dashboard.Components.Tests (1)
tests\Shared\Telemetry\TelemetryTestHelpers.cs (1)
312Attributes = attributes ?? [],
Aspire.Dashboard.Tests (1)
tests\Shared\Telemetry\TelemetryTestHelpers.cs (1)
312Attributes = attributes ?? [],
37 references to Attributes
Aspire.Dashboard (36)
Components\Pages\TraceDetail.razor.cs (1)
512return GenAIHelpers.IsGenAISpan(spanViewModel.Span.Attributes);
Model\GenAI\GenAIVisualizerDialogViewModel.cs (8)
68viewModel.PeerName = OtlpHelpers.GetPeerAddress(viewModel.Span.Attributes)!; 71viewModel.ModelName = viewModel.Span.Attributes.GetValue(GenAIHelpers.GenAIResponseModel); 72viewModel.InputTokens = viewModel.Span.Attributes.GetValueAsInteger(GenAIHelpers.GenAIUsageInputTokens); 73viewModel.OutputTokens = viewModel.Span.Attributes.GetValueAsInteger(GenAIHelpers.GenAIUsageOutputTokens); 81viewModel.Span.Attributes.GetValue("error.type"), 164var systemInstructions = viewModel.Span.Attributes.GetValue(GenAIHelpers.GenAISystemInstructions); 165var inputMessages = viewModel.Span.Attributes.GetValue(GenAIHelpers.GenAIInputMessages); 166var outputMessages = viewModel.Span.Attributes.GetValue(GenAIHelpers.GenAIOutputInstructions);
Model\Otlp\SpanWaterfallViewModel.cs (3)
161var hasPeerService = OtlpHelpers.GetPeerAddress(span.Attributes) != null; 228if (resolver.TryResolvePeer(span.Attributes, out var name, out _)) 235return OtlpHelpers.GetPeerAddress(span.Attributes);
Model\SpanType.cs (2)
93if (!string.IsNullOrEmpty(span.Attributes.GetValue(attributeName))) 126if (!string.IsNullOrEmpty(span.Attributes.GetValue(attributeName)))
Model\TraceHelpers.cs (2)
118if (span.Attributes.HasKey("messaging.system")) 127if (span.Attributes.HasKey("messaging.system"))
Otlp\Model\OtlpSpan.cs (17)
93Attributes = item.Attributes, 120foreach (var kv in Attributes.OrderBy(a => a.Key)) 144if (!string.IsNullOrEmpty(OtlpHelpers.GetValue(span.Attributes, "http.method"))) 146var httpMethod = OtlpHelpers.GetValue(span.Attributes, "http.method"); 147var statusCode = OtlpHelpers.GetValue(span.Attributes, "http.status_code"); 151else if (!string.IsNullOrEmpty(OtlpHelpers.GetValue(span.Attributes, "db.system"))) 153var dbSystem = OtlpHelpers.GetValue(span.Attributes, "db.system"); 157else if (!string.IsNullOrEmpty(OtlpHelpers.GetValue(span.Attributes, "rpc.system"))) 159var rpcSystem = OtlpHelpers.GetValue(span.Attributes, "rpc.system"); 160var rpcService = OtlpHelpers.GetValue(span.Attributes, "rpc.service"); 161var rpcMethod = OtlpHelpers.GetValue(span.Attributes, "rpc.method"); 165var grpcStatusCode = OtlpHelpers.GetValue(span.Attributes, "rpc.grpc.status_code"); 178else if (!string.IsNullOrEmpty(OtlpHelpers.GetValue(span.Attributes, "messaging.system"))) 180var messagingSystem = OtlpHelpers.GetValue(span.Attributes, "messaging.system"); 181var messagingOperation = OtlpHelpers.GetValue(span.Attributes, "messaging.operation"); 182var destinationName = OtlpHelpers.GetValue(span.Attributes, "messaging.destination.name"); 205_ => span.Attributes.GetValue(field)
Otlp\Storage\TelemetryRepository.cs (3)
1054foreach (var kvp in newSpan.Attributes) 1123var hasPeerService = OtlpHelpers.GetPeerAddress(span.Attributes) != null; 1151if (resolver.TryResolvePeer(span.Attributes, out _, out var matchedResourced))
Aspire.Dashboard.Tests (1)
TelemetryRepositoryTests\TraceTests.cs (1)
826Assert.Collection(trace.FirstSpan.Attributes,