13 instantiations of LogLine
Aspire.Hosting (1)
ApplicationModel\ResourceLoggerService.cs (1)
862logs[i] = new LogLine(lineNumber, content, entry.Type == LogEntryType.Error);
Aspire.Hosting.DevTunnels (1)
DevTunnelMonitor.cs (1)
144await ApplyLogsAsync(run, [new(1, content, false)]).ConfigureAwait(false);
Aspire.Hosting.EntityFrameworkCore.Tests (11)
EFCoreOperationExecutorTests.cs (11)
22var logs = CreateLogEntries(new LogLine(1, "error: Unhandled exception: Unable to load the service index for source", false)); 39var logs = CreateLogEntries(new LogLine(1, "info: Migration applied successfully.", false)); 56var logs = CreateLogEntries(new LogLine(1, "data: [{\"id\":\"20240101\",\"name\":\"Init\"}]", false)); 71var logs = CreateLogEntries(new LogLine(1, "Something failed", true)); 88new LogLine(1, "info: Starting migration...", false), 89new LogLine(2, "error: NuGet restore failed", false), 90new LogLine(3, "data: {}", false), 91new LogLine(4, "warn: Deprecated warning", false)); 108var logs = CreateLogEntries(new LogLine(1, "verbose: Loaded assembly from cache", false)); 125new LogLine(1, "info: Applying migration '20240101_Init'...", false), 126new LogLine(2, "info: Done.", false));
107 references to LogLine
Aspire.Hosting (23)
ApplicationModel\CommandsConfigurationExtensions.cs (1)
470foreach (var line in batch)
ApplicationModel\ResourceLoggerService.cs (15)
145public IAsyncEnumerable<IReadOnlyList<LogLine>> GetAllAsync(IResource resource) 165public IAsyncEnumerable<IReadOnlyList<LogLine>> WatchAsync(IResource resource) 185public IAsyncEnumerable<IReadOnlyList<LogLine>> GetAllAsync(string resourceName) 197public IAsyncEnumerable<IReadOnlyList<LogLine>> WatchAsync(string resourceName) 204internal IDisposable Subscribe(string resourceName, Action<IReadOnlyList<LogLine>> onLogs) 315private static async IAsyncEnumerable<IReadOnlyList<LogLine>> CombineMultipleAsync(string[] resourceNames, Func<string, IAsyncEnumerable<IReadOnlyList<LogLine>>> fetch) 317var channel = Channel.CreateUnbounded<IReadOnlyList<LogLine>>(); 432public async IAsyncEnumerable<IReadOnlyList<LogLine>> GetAllAsync(IConsoleLogsService consoleLogsService, [EnumeratorCancellation] CancellationToken cancellationToken = default) 455public async IAsyncEnumerable<IReadOnlyList<LogLine>> WatchAsync([EnumeratorCancellation] CancellationToken cancellationToken = default) 508public IDisposable Subscribe(Action<IReadOnlyList<LogLine>> onLogs) 536IReadOnlyList<LogLine>? logLines = null; 577var batches = new List<IReadOnlyList<LogLine>>(); 850private static LogLine[] CreateLogLines(ref int lineNumber, IReadOnlyList<LogEntry> entries) 852var logs = new LogLine[entries.Count];
Backchannel\AuxiliaryBackchannelRpcTarget.cs (1)
1673foreach (var logLine in batch)
Dashboard\DashboardEventHandlers.cs (1)
790foreach (var logLine in batch)
Dashboard\DashboardServiceData.cs (4)
164internal IAsyncEnumerable<IReadOnlyList<LogLine>>? SubscribeConsoleLogs(string resourceName) 170async IAsyncEnumerable<IReadOnlyList<LogLine>> Enumerate([EnumeratorCancellation] CancellationToken cancellationToken = default) 181internal IAsyncEnumerable<IReadOnlyList<LogLine>>? GetConsoleLogs(string resourceName) 187async IAsyncEnumerable<IReadOnlyList<LogLine>> Enumerate([EnumeratorCancellation] CancellationToken cancellationToken = default)
ResourceLoggerForwarderService.cs (1)
72foreach (var line in logEvent)
Aspire.Hosting.Browsers.Tests (8)
BrowserLogsBuilderExtensionsTests.cs (3)
1685var log = Assert.Single(logs); 1726var log = Assert.Single(logs); 1766private static Task<IReadOnlyList<LogLine>> CaptureLogsAsync(ResourceLoggerService resourceLoggerService, string resourceName, Action writeLogs) =>
ConsoleLoggingTestHelpers.cs (5)
13public static async Task<IReadOnlyList<LogLine>> CaptureLogsAsync(ResourceLoggerService service, string resourceName, int targetLogCount, Action writeLogs) 36public static Task<IReadOnlyList<LogLine>> WatchForLogsAsync(IAsyncEnumerable<IReadOnlyList<LogLine>> watchEnumerable, int targetLogCount) 40var logs = new List<LogLine>(); 50return (IReadOnlyList<LogLine>)logs;
Aspire.Hosting.DevTunnels (2)
DevTunnelMonitor.cs (2)
462private async Task ApplyLogsAsync(Run run, IReadOnlyList<LogLine> batch) 465foreach (var entry in batch)
Aspire.Hosting.DevTunnels.Tests (1)
TestDevTunnelMonitor.cs (1)
97public async Task<IReadOnlyList<LogLine>> LogsAsync(IResource? resource = null)
Aspire.Hosting.Dotnet.Tests (2)
DotnetProjectBuildCoordinatorTests.cs (2)
3999private static async Task<IReadOnlyList<LogLine>> ReadLogsAsync( 4005var logs = new List<LogLine>();
Aspire.Hosting.EntityFrameworkCore (2)
EFCoreOperationExecutor.cs (2)
476IAsyncEnumerable<IReadOnlyList<LogLine>> logChannel, 485foreach (var entry in entries)
Aspire.Hosting.EntityFrameworkCore.Tests (2)
EFCoreOperationExecutorTests.cs (2)
230private static async IAsyncEnumerable<IReadOnlyList<LogLine>> CreateLogEntries(params LogLine[] lines)
Aspire.Hosting.Testing.Tests (11)
tests\Aspire.Hosting.TestUtilities\Utils\LoggerNotificationExtensions.cs (1)
164foreach (var line in logEvent)
tests\Shared\ConsoleLogging\ConsoleLoggingTestHelpers.cs (10)
10public static async Task<IReadOnlyList<LogLine>> CaptureLogsAsync(ResourceLoggerService service, string resourceName, int targetLogCount, Action writeLogs) 33public static Task<IReadOnlyList<LogLine>> WatchForLogsAsync(ResourceLoggerService service, int targetLogCount, IResource resource) 39public static Task<IReadOnlyList<LogLine>> WatchForLogsAsync(IAsyncEnumerable<IReadOnlyList<LogLine>> watchEnumerable, int targetLogCount) 43var logs = new List<LogLine>(); 52return (IReadOnlyList<LogLine>)logs; 56public static Task<IReadOnlyList<LogLine>> WatchForLogsAsync(IAsyncEnumerator<IReadOnlyList<LogLine>> watchEnumerator, int targetLogCount) 60var logs = new List<LogLine>(); 70return (IReadOnlyList<LogLine>)logs;
Aspire.Hosting.Tests (54)
Dcp\DcpExecutorTests.cs (24)
1985var logLine = watchLogsEnumerator.Current.Single(); 2161var logLines = new ConcurrentQueue<LogLine>(); 2164foreach (var logLine in batch) 2223var logLines = new ConcurrentQueue<LogLine>(); 2233foreach (var logLine in batch) 2287var logLines = new List<LogLine>(); 2477var logLines = new ConcurrentQueue<LogLine>(); 2488foreach (var logLine in batch) 2558var logLines = new List<LogLine>(); 2642var logLines = new ConcurrentQueue<LogLine>(); 2652foreach (var logLine in batch) 2737var logLines = new ConcurrentQueue<LogLine>(); 2840void AddLogLines(IReadOnlyList<LogLine> batch) 2842foreach (var logLine in batch) 2893var logLines = new ConcurrentQueue<LogLine>(); 2992void AddLogLines(IReadOnlyList<LogLine> batch) 2994foreach (var logLine in batch) 3331var logLines = new ConcurrentQueue<LogLine>(); 3369foreach (var logLine in batch) 7375var logLines = new List<LogLine>(); 8788var logLines = new List<LogLine>(); 9294var logLines = new List<LogLine>(); 9381var logLines = new List<LogLine>(); 10416var logLines = new List<LogLine>();
Lifecycle\TerminalHostFailureDiagnosticServiceTests.cs (3)
271private static async Task<IReadOnlyList<LogLine>> ReadLogsAsync(ResourceLoggerService loggers, IResource host, int expected, int? timeoutMs = null) 273var collected = new List<LogLine>(); 279foreach (var line in batch)
Orchestrator\ParameterProcessorTests.cs (3)
346var logEntry = logs[0]; 370var logEntry = logs[0]; 413var logEntry = logs[0];
ResourceLoggerServiceTests.cs (14)
291var allLogs = new List<LogLine>(); 317var logLines = new List<LogLine>(); 352var logLines = new List<LogLine>(); 384var logLines = new List<LogLine>(); 490var allLogs = new List<LogLine>(); 496var logLine = Assert.Single(allLogs); 507var logLines = new List<LogLine>(); 550var logLines = new List<LogLine>(); 604foreach (var line in batch) 625foreach (var line in batch) 683var logs = new List<LogLine>(); 688return (IReadOnlyList<LogLine>)logs; 717var logs = new List<LogLine>(); 722return (IReadOnlyList<LogLine>)logs;
tests\Shared\ConsoleLogging\ConsoleLoggingTestHelpers.cs (10)
10public static async Task<IReadOnlyList<LogLine>> CaptureLogsAsync(ResourceLoggerService service, string resourceName, int targetLogCount, Action writeLogs) 33public static Task<IReadOnlyList<LogLine>> WatchForLogsAsync(ResourceLoggerService service, int targetLogCount, IResource resource) 39public static Task<IReadOnlyList<LogLine>> WatchForLogsAsync(IAsyncEnumerable<IReadOnlyList<LogLine>> watchEnumerable, int targetLogCount) 43var logs = new List<LogLine>(); 52return (IReadOnlyList<LogLine>)logs; 56public static Task<IReadOnlyList<LogLine>> WatchForLogsAsync(IAsyncEnumerator<IReadOnlyList<LogLine>> watchEnumerator, int targetLogCount) 60var logs = new List<LogLine>(); 70return (IReadOnlyList<LogLine>)logs;
Aspire.Hosting.TestUtilities (1)
Utils\LoggerNotificationExtensions.cs (1)
164foreach (var line in logEvent)
Aspire.Playground.Tests (1)
tests\Aspire.Hosting.TestUtilities\Utils\LoggerNotificationExtensions.cs (1)
164foreach (var line in logEvent)