The class Tracehas a UseGlobalLock property , which should be trueif the underlying listener (s) reports that they are not thread safe.
In other words, if you use a trace listener that is not thread safe with the class Debugor Trace, then these classes ( Trace/ Debug) the listener is handled in a thread safe way.
, , , . , , - , , -, .
, true, , , Trace.UseGlobalLock :
<configuration>
<system.diagnostics>
<trace useGlobalLock="false" />
</system.diagnostics>
</configuration>
: - Trace, .
, Debug , Trace, .
Debug Trace , , , , , . , Trace.UseGlobalLock Debug.WriteXYZ.