5 writes to Attributes
Aspire.Dashboard (2)
Model\TelemetryExportService.cs (1)
644Attributes = attributes.ToArray()
OtlpJsonSerializerContext.OtlpResourceJson.g.cs (1)
59Setter = static (obj, value) => ((global::Aspire.Otlp.Serialization.OtlpResourceJson)obj).Attributes = value!,
Aspire.Dashboard.Tests (3)
Model\TelemetryImportServiceTests.cs (3)
437Attributes = 482Attributes = 527Attributes =
18 references to Attributes
Aspire.Dashboard (8)
Otlp\Model\Serialization\OtlpJsonProtobufConverter.cs (2)
749if (json.Attributes is not null) 751foreach (var attr in json.Attributes)
OtlpJsonSerializerContext.OtlpResourceJson.g.cs (2)
58Getter = static obj => ((global::Aspire.Otlp.Serialization.OtlpResourceJson)obj).Attributes, 126global::Aspire.Otlp.Serialization.OtlpKeyValueJson[] __value_Attributes = ((global::Aspire.Otlp.Serialization.OtlpResourceJson)value).Attributes;
src\Shared\ConsoleLogs\SharedAIHelpers.cs (2)
516var serviceName = GetAttributeStringValue(resource?.Attributes, "service.name"); 517var serviceInstanceId = GetAttributeStringValue(resource?.Attributes, "service.instance.id");
src\Shared\Otlp\Serialization\OtlpResourceJson.cs (2)
37if (Attributes is null) 42foreach (var attr in Attributes)
Aspire.Dashboard.Tests (10)
Model\TelemetryExportServiceTests.cs (10)
69Assert.NotNull(resourceLogs.Resource.Attributes); 70Assert.Contains(resourceLogs.Resource.Attributes, a => a.Key == OtlpResource.SERVICE_NAME && a.Value?.StringValue == "TestService"); 71Assert.Contains(resourceLogs.Resource.Attributes, a => a.Key == OtlpResource.SERVICE_INSTANCE_ID && a.Value?.StringValue == "instance-1"); 303Assert.NotNull(resourceSpans.Resource.Attributes); 304Assert.Contains(resourceSpans.Resource.Attributes, a => a.Key == OtlpResource.SERVICE_NAME && a.Value?.StringValue == "TestService"); 518Assert.NotNull(resourceMetrics.Resource.Attributes); 519Assert.Contains(resourceMetrics.Resource.Attributes, a => a.Key == OtlpResource.SERVICE_NAME && a.Value?.StringValue == "TestService"); 900Assert.NotNull(data.ResourceSpans[0].Resource?.Attributes); 1053Assert.NotNull(data.ResourceSpans[0].Resource?.Attributes); 1089Assert.NotNull(data.ResourceLogs[0].Resource?.Attributes);