145 references to LoggerMode
Microsoft.Build (20)
BackEnd\BuildManager\BuildManager.cs (3)
2910
LoggerMode
loggerMode = cpuCount == 1 && _buildParameters.UseSynchronousLogging
2911
?
LoggerMode
.Synchronous
2912
:
LoggerMode
.Asynchronous;
BackEnd\Components\Logging\ILoggingService.cs (1)
76
LoggerMode
LoggingMode
BackEnd\Components\Logging\LoggingService.cs (8)
283
private
LoggerMode
_logMode =
LoggerMode
.Asynchronous;
296
protected LoggingService(
LoggerMode
loggerMode, int nodeId)
321
if (_logMode ==
LoggerMode
.Asynchronous)
492
public
LoggerMode
LoggingMode => _logMode;
840
public static ILoggingService CreateLoggingService(
LoggerMode
mode, int node)
913
if (_logMode ==
LoggerMode
.Asynchronous)
1299
if (_logMode ==
LoggerMode
.Asynchronous)
BackEnd\Components\Logging\LoggingServiceFactory.cs (3)
21
private
LoggerMode
_logMode =
LoggerMode
.Synchronous;
36
internal LoggingServiceFactory(
LoggerMode
mode, int nodeId)
BackEnd\Node\OutOfProcNode.cs (1)
758
LoggingServiceFactory loggingServiceFactory = new LoggingServiceFactory(
LoggerMode
.Asynchronous, configuration.NodeId);
Definition\ProjectCollection.cs (4)
26
using LoggerMode = Microsoft.Build.BackEnd.Logging.
LoggerMode
;
203
private
LoggerMode
_loggerMode;
334
_loggerMode = useAsynchronousLogging ?
LoggerMode
.Asynchronous :
LoggerMode
.Synchronous;
Microsoft.Build.BuildCheck.UnitTests (1)
BuildCheckManagerProviderTests.cs (1)
30
_loggingService = LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
Microsoft.Build.Engine.UnitTests (124)
BackEnd\BuildManager_Logging_Tests.cs (1)
99
ILoggingService service = LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
BackEnd\LoggingService_Tests.cs (23)
64
IBuildComponent logServiceComponent = (IBuildComponent)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
69
Assert.Equal(
LoggerMode
.Synchronous, logService.LoggingMode);
73
logServiceComponent = (IBuildComponent)LoggingService.CreateLoggingService(
LoggerMode
.Asynchronous, 1);
76
Assert.Equal(
LoggerMode
.Asynchronous, logService.LoggingMode);
91
IBuildComponent logServiceComponent = (IBuildComponent)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
119
IBuildComponent logServiceComponent = (IBuildComponent)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
642
LoggingService loggingService = (LoggingService)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
648
Assert.Equal(
LoggerMode
.Synchronous, loggingService.LoggingMode); // "Expected Logging mode to be Synchronous"
675
LoggingService loggingService = (LoggingService)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
688
LoggingService loggingService = (LoggingService)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
701
LoggingServicesLogMethod_Tests.ProcessBuildEventHelper loggingService = (LoggingServicesLogMethod_Tests.ProcessBuildEventHelper)LoggingServicesLogMethod_Tests.ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
734
MockLogger logger = GetLoggedEventsWithWarningsAsErrorsOrMessages(BuildWarningEventForTreatAsErrorOrMessageTests, (
LoggerMode
)loggerMode, nodeId, warningsAsErrors);
784
MockLogger logger = GetLoggedEventsWithWarningsAsErrorsOrMessages(BuildWarningEventForTreatAsErrorOrMessageTests, (
LoggerMode
)loggerMode, nodeId, warningsAsErrors);
792
ILoggingService ls = LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
818
MockLogger logger = GetLoggedEventsWithWarningsAsErrorsOrMessages(BuildWarningEventForTreatAsErrorOrMessageTests, (
LoggerMode
)loggerMode, nodeId, warningsAsMessages: warningsAsMessages);
872
MockLogger logger = GetLoggedEventsWithWarningsAsErrorsOrMessages(BuildWarningEventForTreatAsErrorOrMessageTests, (
LoggerMode
)loggerMode, nodeId, warningsAsErrorsForProject: warningsAsErrorsForProject);
903
MockLogger logger = GetLoggedEventsWithWarningsAsErrorsOrMessages(BuildWarningEventForTreatAsErrorOrMessageTests, (
LoggerMode
)loggerMode, nodeId, warningsAsErrorsForProject: warningsAsErrorsForProject);
925
MockLogger logger = GetLoggedEventsWithWarningsAsErrorsOrMessages(BuildWarningEventForTreatAsErrorOrMessageTests, (
LoggerMode
)loggerMode, nodeId, warningsAsMessagesForProject: warningsAsMessagesForProject);
947
LoggerMode
loggerMode =
LoggerMode
.Synchronous,
1047
ILoggingService node1LoggingService = LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
1049
ILoggingService node2LoggingService = LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 2);
1092
IBuildComponent logServiceComponent = (IBuildComponent)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
BackEnd\LoggingServiceFactory_Tests.cs (4)
23
LoggingServiceFactory factory = new LoggingServiceFactory(
LoggerMode
.Synchronous, 1);
25
Assert.Equal(
LoggerMode
.Synchronous, loggingService.LoggingMode); // "Expected to create a Synchronous LoggingService"
34
LoggingServiceFactory factory = new LoggingServiceFactory(
LoggerMode
.Asynchronous, 1);
36
Assert.Equal(
LoggerMode
.Asynchronous, loggingService.LoggingMode); // "Expected to create an Asynchronous LoggingService"
BackEnd\LoggingServicesLogMethod_Tests.cs (64)
55
LoggingService loggingService = (LoggingService)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
74
ProcessBuildEventHelper loggingService = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
105
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
118
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
137
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
155
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
168
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
181
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
216
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
229
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
247
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
261
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
275
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
295
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
318
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
335
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
354
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
375
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
388
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
401
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
512
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
526
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
544
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
569
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
582
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
609
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
622
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
635
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
679
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
692
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
707
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
732
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
743
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
755
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
769
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
795
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
809
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
838
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1, componentHost);
864
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1, componentHost);
903
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1, componentHost);
944
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1, componentHost);
978
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
1010
(ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
1034
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
1055
(ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
1076
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Asynchronous, 1);
1096
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
1131
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
1171
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
1219
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
1258
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
1286
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
1351
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
1372
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
1389
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
1404
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1, componentHost);
1453
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
1473
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
1493
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
1524
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
1551
ProcessBuildEventHelper service = (ProcessBuildEventHelper)ProcessBuildEventHelper.CreateLoggingService(
LoggerMode
.Synchronous, 1);
1805
private ProcessBuildEventHelper(
LoggerMode
loggerMode, int nodeId, IBuildComponentHost componentHost)
1837
public static new IBuildComponent CreateLoggingService(
LoggerMode
mode, int nodeId)
1847
public static IBuildComponent CreateLoggingService(
LoggerMode
mode, int nodeId, IBuildComponentHost componentHost)
BackEnd\MockLoggingService.cs (2)
81
public
LoggerMode
LoggingMode
85
return
LoggerMode
.Synchronous;
BackEnd\SdkResolverLoader_Tests.cs (1)
38
ILoggingService loggingService = LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
BackEnd\SdkResolverService_Tests.cs (1)
38
ILoggingService loggingService = LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
BackEnd\TaskExecutionHost_Tests.cs (1)
1233
_loggingService = LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
BackEnd\TaskHost_Tests.cs (1)
64
LoggingServiceFactory loggingFactory = new LoggingServiceFactory(
LoggerMode
.Synchronous, 1);
BackEnd\TaskRegistry_Tests.cs (1)
88
_loggingService = LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
Construction\SolutionFilter_Tests.cs (1)
298
ILoggingService loggingService = LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 0);
Construction\SolutionProjectGenerator_Tests.cs (2)
21
using LoggerMode = Microsoft.Build.BackEnd.Logging.
LoggerMode
;
2839
ILoggingService loggingService = LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 0);
Definition\ToolsVersion_Tests.cs (19)
21
using LoggerMode = Microsoft.Build.BackEnd.Logging.
LoggerMode
;
84
LoggingService service = (LoggingService)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
104
LoggingService service = (LoggingService)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
123
LoggingService service = (LoggingService)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
143
LoggingService service = (LoggingService)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
193
LoggingService service = (LoggingService)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
218
LoggingService service = (LoggingService)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
239
LoggingService service = (LoggingService)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
305
LoggingService service = (LoggingService)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
342
LoggingService service = (LoggingService)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
378
LoggingService service = (LoggingService)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
408
LoggingService service = (LoggingService)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
440
LoggingService service = (LoggingService)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
548
LoggingService service = (LoggingService)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
586
LoggingService service = (LoggingService)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
627
LoggingService service = (LoggingService)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
698
LoggingService service = (LoggingService)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
783
LoggingService service = (LoggingService)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
894
LoggingService service = (LoggingService)LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
Evaluation\Expander_Tests.cs (2)
5133
ILoggingService loggingService = LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
5170
ILoggingService loggingService = LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1);
TestLoggingContext.cs (1)
17
loggingService ?? Build.BackEnd.Logging.LoggingService.CreateLoggingService(
LoggerMode
.Synchronous, 1), eventContext)