diff --git a/tools/test-proxy/Azure.Sdk.Tools.TestProxy/Startup.cs b/tools/test-proxy/Azure.Sdk.Tools.TestProxy/Startup.cs index 26ac09a4f4b..5508a54b2b9 100644 --- a/tools/test-proxy/Azure.Sdk.Tools.TestProxy/Startup.cs +++ b/tools/test-proxy/Azure.Sdk.Tools.TestProxy/Startup.cs @@ -21,9 +21,9 @@ using System.Linq; using System.CommandLine; using Azure.Sdk.Tools.TestProxy.CommandOptions; -using Microsoft.AspNetCore.Identity; -using Microsoft.CodeAnalysis.VisualBasic.Syntax; using System.Text.Json; +using Microsoft.Extensions.Logging.Console; +using Microsoft.Extensions.Options; namespace Azure.Sdk.Tools.TestProxy { @@ -147,9 +147,12 @@ private static void StartServer(StartOptions startOptions) { loggingBuilder.ClearProviders(); loggingBuilder.AddConfiguration(hostBuilder.Configuration.GetSection("Logging")); - loggingBuilder.AddSimpleConsole(formatterOptions => + loggingBuilder.AddConsole(options => { - formatterOptions.TimestampFormat = "[HH:mm:ss] "; + options.LogToStandardErrorThreshold = LogLevel.Error; + }).AddSimpleConsole(options => + { + options.TimestampFormat = "[HH:mm:ss] "; }); loggingBuilder.AddDebug(); loggingBuilder.AddEventSourceLogger();