109 references to Critical
Aspire.Dashboard (5)
Components\Pages\StructuredLogs.razor.cs (1)
176new SelectViewModel<LogLevel?> { Id = LogLevel.Critical, Name = "Critical" },
Otlp\Model\OtlpLogEntry.cs (4)
88SeverityNumber.Fatal => LogLevel.Critical, 89SeverityNumber.Fatal2 => LogLevel.Critical, 90SeverityNumber.Fatal3 => LogLevel.Critical, 91SeverityNumber.Fatal4 => LogLevel.Critical,
Aspire.Hosting.Tests (3)
Dashboard\DashboardLifecycleHookTests.cs (2)
163LogLevel = LogLevel.Critical, 177LogLevel.Critical
Dashboard\DashboardResourceTests.cs (1)
416[InlineData(LogLevel.Critical)]
Aspire.RabbitMQ.Client (1)
RabbitMQEventSourceLogForwarder.cs (1)
63EventLevel.Critical => LogLevel.Critical,
InMemory.FunctionalTests (3)
src\Servers\Kestrel\shared\test\TestApplicationErrorLogger.cs (3)
35public int CriticalErrorsLogged => Messages.Count(message => message.LogLevel == LogLevel.Critical); 68if (logLevel == LogLevel.Critical && ThrowOnCriticalErrors && !exceptionIsIgnored) 74if (logLevel == LogLevel.Critical && ThrowOnCriticalErrors && !exceptionIsIgnored)
Interop.FunctionalTests (2)
Http3\Http3RequestTests.cs (2)
1054var badLogWrite = TestSink.Writes.FirstOrDefault(w => w.LogLevel == LogLevel.Critical); 1140var badLogWrite = TestSink.Writes.FirstOrDefault(w => w.LogLevel >= LogLevel.Critical);
Microsoft.Arcade.Common (2)
CompactConsoleLoggerFormatter.cs (2)
111LogLevel.Critical => "crit", 131LogLevel.Critical => (ConsoleColor.White, ConsoleColor.DarkRed),
Microsoft.AspNetCore.Components.WebAssembly (3)
Rendering\WebAssemblyRenderer.cs (1)
196[LoggerMessage(100, LogLevel.Critical, "Unhandled exception rendering component: {Message}", EventName = "ExceptionRenderingComponent")]
Services\WebAssemblyConsoleLogger.cs (2)
91case LogLevel.Critical: 152case LogLevel.Critical:
Microsoft.AspNetCore.Hosting (1)
Internal\HostingApplicationDiagnostics.cs (1)
89var loggingEnabled = _logger.IsEnabled(LogLevel.Critical);
Microsoft.AspNetCore.Server.HttpSys (3)
AsyncAcceptContext.Log.cs (3)
17[LoggerMessage(LoggerEventIds.AcceptSetExpectationMismatch, LogLevel.Critical, "Mismatch setting callback expectation - {Value}", EventName = "AcceptSetExpectationMismatch")] 20[LoggerMessage(LoggerEventIds.AcceptCancelExpectationMismatch, LogLevel.Critical, "Mismatch canceling accept state - {Value}", EventName = "AcceptCancelExpectationMismatch")] 23[LoggerMessage(LoggerEventIds.AcceptObserveExpectationMismatch, LogLevel.Critical, "Mismatch observing {Kind} accept callback - {Value}", EventName = "AcceptObserveExpectationMismatch")]
Microsoft.AspNetCore.Server.Kestrel.Core (6)
Internal\Infrastructure\KestrelConnection.cs (1)
174if (Logger.IsEnabled(LogLevel.Critical))
Internal\Infrastructure\KestrelTrace.General.cs (1)
88[LoggerMessage(23, LogLevel.Critical, @"Connection id ""{ConnectionId}"" application never completed.", EventName = "ApplicationNeverCompleted")]
Internal\Infrastructure\KestrelTrace.Http2.cs (3)
135[LoggerMessage(60, LogLevel.Critical, @"Connection id ""{ConnectionId}"" exceeded the output operations maximum queue size.", EventName = "Http2QueueOperationsExceeded")] 138[LoggerMessage(61, LogLevel.Critical, @"Stream {StreamId} on connection id ""{ConnectionId}"" observed an unexpected state where the streams output ended with data still remaining in the pipe.", EventName = "Http2UnexpectedDataRemaining")] 144[LoggerMessage(63, LogLevel.Critical, @"The event loop in connection {ConnectionId} failed unexpectedly.", EventName = "Http2UnexpectedConnectionQueueError")]
Internal\KestrelServerImpl.cs (1)
392if (Trace.IsEnabled(LogLevel.Critical))
Microsoft.AspNetCore.Server.Kestrel.Core.Tests (4)
ConnectionDispatcherTests.cs (1)
66var critical = TestSink.Writes.SingleOrDefault(m => m.LogLevel == LogLevel.Critical);
src\Servers\Kestrel\shared\test\TestApplicationErrorLogger.cs (3)
35public int CriticalErrorsLogged => Messages.Count(message => message.LogLevel == LogLevel.Critical); 68if (logLevel == LogLevel.Critical && ThrowOnCriticalErrors && !exceptionIsIgnored) 74if (logLevel == LogLevel.Critical && ThrowOnCriticalErrors && !exceptionIsIgnored)
Microsoft.AspNetCore.Server.Kestrel.Microbenchmarks (3)
src\Servers\Kestrel\shared\test\TestApplicationErrorLogger.cs (3)
35public int CriticalErrorsLogged => Messages.Count(message => message.LogLevel == LogLevel.Critical); 68if (logLevel == LogLevel.Critical && ThrowOnCriticalErrors && !exceptionIsIgnored) 74if (logLevel == LogLevel.Critical && ThrowOnCriticalErrors && !exceptionIsIgnored)
Microsoft.AspNetCore.Server.Kestrel.Transport.Quic.Tests (3)
src\Servers\Kestrel\shared\test\TestApplicationErrorLogger.cs (3)
35public int CriticalErrorsLogged => Messages.Count(message => message.LogLevel == LogLevel.Critical); 68if (logLevel == LogLevel.Critical && ThrowOnCriticalErrors && !exceptionIsIgnored) 74if (logLevel == LogLevel.Critical && ThrowOnCriticalErrors && !exceptionIsIgnored)
Microsoft.AspNetCore.SignalR.Client.Core (2)
HubConnection.cs (1)
1105if (activity is null && Activity.Current is not null && _logger.IsEnabled(LogLevel.Critical))
HubConnection.Log.cs (1)
129[LoggerMessage(22, LogLevel.Critical, "Invocation ID '{InvocationId}' is already in use.", EventName = "InvocationAlreadyInUse")]
Microsoft.AspNetCore.SignalR.Core (1)
Internal\DefaultHubDispatcher.cs (1)
842var loggingEnabled = logger.IsEnabled(LogLevel.Critical);
Microsoft.CodeAnalysis.LanguageServer (3)
Logging\LspLogMessageLogger.cs (1)
87LogLevel.Critical => MessageType.Error,
Program.cs (1)
64logger.Log(serverConfiguration.LaunchDebugger ? LogLevel.Critical : LogLevel.Trace, "Server started with process ID {processId}", Environment.ProcessId);
Testing\RunTestsHandler.cs (1)
163Microsoft.Extensions.Logging.LogLevel.Error or Microsoft.Extensions.Logging.LogLevel.Critical => TraceLevel.Error,
Microsoft.Extensions.Diagnostics.Testing (1)
Logging\FakeLogRecord.cs (1)
142LogLevel.Critical => " crit",
Microsoft.Extensions.Diagnostics.Testing.Tests (2)
Logging\FakeLoggerTests.cs (2)
156Assert.True(logger.IsEnabled(LogLevel.Critical)); 167Assert.True(logger.IsEnabled(LogLevel.Critical));
Microsoft.Extensions.Hosting (1)
Internal\HostingLoggerExtensions.cs (1)
96if (logger.IsEnabled(LogLevel.Critical))
Microsoft.Extensions.Logging (3)
Logger.cs (1)
243LogLevel.Critical,
LoggerFactory.cs (1)
235if (minLevel is not null and > LogLevel.Critical)
src\libraries\Common\src\Extensions\Logging\DebuggerDisplayFormatting.cs (1)
36LogLevel.Critical,
Microsoft.Extensions.Logging.Abstractions (5)
LoggerExtensions.cs (4)
382logger.Log(LogLevel.Critical, eventId, exception, message, args); 399logger.Log(LogLevel.Critical, eventId, message, args); 416logger.Log(LogLevel.Critical, exception, message, args); 432logger.Log(LogLevel.Critical, message, args);
src\libraries\Common\src\Extensions\Logging\DebuggerDisplayFormatting.cs (1)
36LogLevel.Critical,
Microsoft.Extensions.Logging.Console (4)
JsonConsoleFormatter.cs (1)
135LogLevel.Critical => "Critical",
SimpleConsoleFormatter.cs (2)
172LogLevel.Critical => "crit", 196LogLevel.Critical => new ConsoleColors(ConsoleColor.White, ConsoleColor.DarkRed),
SystemdConsoleFormatter.cs (1)
130LogLevel.Critical => "<2>", // critical conditions
Microsoft.Extensions.Logging.EventLog (1)
EventLogLogger.cs (1)
195case LogLevel.Critical:
Microsoft.Extensions.Logging.EventSource (3)
EventSourceLogger.cs (1)
166if (!IsEnabled(LogLevel.Critical))
LoggingEventSource.cs (2)
499ret = LogLevel.Critical; 541return LogLevel.Critical;
Microsoft.Extensions.Logging.TraceSource (1)
TraceSourceLogger.cs (1)
72case LogLevel.Critical: return TraceEventType.Critical;
Microsoft.Extensions.Telemetry (1)
Logging\ExtendedLoggerFactory.cs (1)
231if (minLevel is > LogLevel.Critical)
Microsoft.Gen.Logging.Generated.Tests (31)
LoggerMessageAttributeTests.cs (2)
122AttributeTestExtensions.M6(logger, LogLevel.Critical, "arg0", "arg1"); 123AssertWhenDefaultLogMethodCtor(collector, LogLevel.Critical, ("p0", "----"), ("p1", "arg1"));
LogMethodTests.cs (10)
25Assert.Equal(LogLevel.Critical, collector.LatestRecord.Level); 32Assert.Equal(LogLevel.Critical, collector.LatestRecord.Level); 39Assert.Equal(LogLevel.Critical, collector.LatestRecord.Level); 52Assert.Equal(LogLevel.Critical, collector.LatestRecord.Level); 70fakeLogger.ControlLevel(LogLevel.Critical, false); 77LevelTestExtensions.M8(logger, LogLevel.Critical); 211CollectionTestExtensions.M9(logger, LogLevel.Critical, 0, new ArgumentException("Foo"), 1); 426Assert.Equal(LogLevel.Critical, collector.LatestRecord.Level); 444LevelTestExtensions.M8(logger, LogLevel.Critical); 447Assert.Equal(LogLevel.Critical, collector.LatestRecord.Level);
LogPropertiesTests.cs (3)
77LogPropertiesOmitParameterNameExtensions.M2(_logger, LogLevel.Critical, props); 468LogMethodDefaultAttrCtor(_logger, LogLevel.Critical, classToLog); 474Assert.Equal(LogLevel.Critical, latestRecord.Level);
test\Generators\Microsoft.Gen.Logging\TestClasses\LevelTestExtensions.cs (1)
25[LoggerMessage(5, LogLevel.Critical, "M5")]
test\Generators\Microsoft.Gen.Logging\TestClasses\MiscTestExtensions.cs (3)
12[LoggerMessage(0, LogLevel.Critical, "Could not open socket to `{hostName}`")] 21[LoggerMessage(0, LogLevel.Critical, "Could not open socket to `{hostName}`")] 33[LoggerMessage(0, LogLevel.Critical, "Could not open socket to `{hostName}`")]
test\Generators\Microsoft.Gen.Logging\TestClasses\NamespaceTestExtensions.cs (1)
10[LoggerMessage(1, LogLevel.Critical, "Could not open socket to `{hostName}`")]
test\Generators\Microsoft.Gen.Logging\TestClasses\SignatureTestExtensions.cs (11)
13[LoggerMessage(eventId: 10, level: LogLevel.Critical, message: "Message11")] 45[LoggerMessage(0, LogLevel.Critical, "Message1")] 49[LoggerMessage(1, LogLevel.Critical, "Message2")] 53[LoggerMessage(2, LogLevel.Critical, "Message3")] 57[LoggerMessage(3, LogLevel.Critical, "Message4")] 61[LoggerMessage(4, LogLevel.Critical, "Message5 {items}")] 65[LoggerMessage(5, LogLevel.Critical, "Message6\n\"\r")] 69[LoggerMessage(6, LogLevel.Critical, "Message7 {p1}\n\"\r")] 73[LoggerMessage(7, LogLevel.Critical, "Message8")] 77[LoggerMessage(8, LogLevel.Critical, "Message9")] 81[LoggerMessage(9, LogLevel.Critical, "Message10 {optional}")]
RoutingSandbox (1)
Program.cs (1)
67b.SetMinimumLevel(LogLevel.Critical);
RoutingWebSite (1)
Program.cs (1)
70b.SetMinimumLevel(LogLevel.Critical);
Sockets.BindTests (6)
src\Servers\Kestrel\shared\test\TestApplicationErrorLogger.cs (3)
35public int CriticalErrorsLogged => Messages.Count(message => message.LogLevel == LogLevel.Critical); 68if (logLevel == LogLevel.Critical && ThrowOnCriticalErrors && !exceptionIsIgnored) 74if (logLevel == LogLevel.Critical && ThrowOnCriticalErrors && !exceptionIsIgnored)
src\Servers\Kestrel\test\BindTests\AddressRegistrationTests.cs (3)
559Assert.Equal(0, LogMessages.Count(log => log.LogLevel == LogLevel.Critical && 594Assert.Equal(0, LogMessages.Count(log => log.LogLevel == LogLevel.Critical && 987Assert.Equal(0, LogMessages.Count(log => log.LogLevel == LogLevel.Critical &&
Sockets.FunctionalTests (3)
src\Servers\Kestrel\shared\test\TestApplicationErrorLogger.cs (3)
35public int CriticalErrorsLogged => Messages.Count(message => message.LogLevel == LogLevel.Critical); 68if (logLevel == LogLevel.Critical && ThrowOnCriticalErrors && !exceptionIsIgnored) 74if (logLevel == LogLevel.Critical && ThrowOnCriticalErrors && !exceptionIsIgnored)