From 9c0ae1878a457f58f8a4e06d9b25860669e721a2 Mon Sep 17 00:00:00 2001 From: Steve Gordon Date: Fri, 22 Nov 2024 11:17:05 +0000 Subject: [PATCH] Aspire tweaks --- build/scripts/Targets.fs | 5 ++++- examples/AppHost/Properties/launchSettings.json | 17 +++++++++++++++-- .../Example.AspNetCore.Mvc.csproj | 2 +- examples/ServiceDefaults/ServiceDefaults.csproj | 2 +- .../ElasticOpenTelemetryBuilder.cs | 1 - 5 files changed, 21 insertions(+), 6 deletions(-) diff --git a/build/scripts/Targets.fs b/build/scripts/Targets.fs index 6583e49..396c24a 100644 --- a/build/scripts/Targets.fs +++ b/build/scripts/Targets.fs @@ -75,7 +75,10 @@ let private runTests suite _ = | Skip_E2E -> [ "--filter"; "FullyQualifiedName!~.EndToEndTests" ] let settingsArg = ["-s"; "tests/.runsettings"] - let tfmArgs = if OS.Current = Windows then [] else if suite.Equals(E2E) then ["-f"; "net8.0"] else ["-f"; "net9.0"] + let tfmArgs = + if OS.Current = Windows then [] + elif suite.Equals(E2E) then ["-f"; "net8.0"] + else ["-f"; "net9.0"] exec { env (Map ["TEST_SUITE", suite.SuitName]) run "dotnet" ( diff --git a/examples/AppHost/Properties/launchSettings.json b/examples/AppHost/Properties/launchSettings.json index d1b87a7..4695bc6 100644 --- a/examples/AppHost/Properties/launchSettings.json +++ b/examples/AppHost/Properties/launchSettings.json @@ -1,15 +1,28 @@ { "$schema": "http://json.schemastore.org/launchsettings.json", "profiles": { + "https": { + "commandName": "Project", + "dotnetRunMessages": true, + "launchBrowser": true, + "applicationUrl": "https://localhost:17236;http://localhost:15173", + "environmentVariables": { + "ASPNETCORE_ENVIRONMENT": "Development", + "DOTNET_ENVIRONMENT": "Development", + "DOTNET_DASHBOARD_OTLP_ENDPOINT_URL": "https://localhost:21045", + "DOTNET_RESOURCE_SERVICE_ENDPOINT_URL": "https://localhost:22093" + } + }, "http": { "commandName": "Project", "dotnetRunMessages": true, "launchBrowser": true, - "applicationUrl": "http://localhost:15114", + "applicationUrl": "http://localhost:15173", "environmentVariables": { "ASPNETCORE_ENVIRONMENT": "Development", "DOTNET_ENVIRONMENT": "Development", - "DOTNET_DASHBOARD_OTLP_ENDPOINT_URL": "http://localhost:16161" + "DOTNET_DASHBOARD_OTLP_ENDPOINT_URL": "http://localhost:19153", + "DOTNET_RESOURCE_SERVICE_ENDPOINT_URL": "http://localhost:20247" } } } diff --git a/examples/Example.AspNetCore.Mvc/Example.AspNetCore.Mvc.csproj b/examples/Example.AspNetCore.Mvc/Example.AspNetCore.Mvc.csproj index 0e49607..837362b 100644 --- a/examples/Example.AspNetCore.Mvc/Example.AspNetCore.Mvc.csproj +++ b/examples/Example.AspNetCore.Mvc/Example.AspNetCore.Mvc.csproj @@ -1,7 +1,7 @@  - net9.0 + net8.0 enable enable Linux diff --git a/examples/ServiceDefaults/ServiceDefaults.csproj b/examples/ServiceDefaults/ServiceDefaults.csproj index 1968191..2d20800 100644 --- a/examples/ServiceDefaults/ServiceDefaults.csproj +++ b/examples/ServiceDefaults/ServiceDefaults.csproj @@ -1,7 +1,7 @@ - net9.0 + net8.0 enable enable true diff --git a/src/Elastic.OpenTelemetry/ElasticOpenTelemetryBuilder.cs b/src/Elastic.OpenTelemetry/ElasticOpenTelemetryBuilder.cs index 7804718..d8cd735 100644 --- a/src/Elastic.OpenTelemetry/ElasticOpenTelemetryBuilder.cs +++ b/src/Elastic.OpenTelemetry/ElasticOpenTelemetryBuilder.cs @@ -170,5 +170,4 @@ internal static partial class LoggerMessages [LoggerMessage(EventId = 4, Level = LogLevel.Information, Message = "Elastic defaults for {Signal} skipped, configured to be disabled")] public static partial void LogDefaultsDisabled(this ILogger logger, string signal); - }