Updated
This commit is contained in:
@@ -37,6 +37,7 @@ public sealed class LogBuilder
|
||||
public LogBuilder(string category = "Application")
|
||||
{
|
||||
_category = category ?? throw new ArgumentNullException(nameof(category));
|
||||
UseAsyncPipeline();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -1107,6 +1108,18 @@ public sealed class LogBuilder
|
||||
return this;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Disables the async dispatch pipeline and uses a synchronous flow instead.
|
||||
/// </summary>
|
||||
/// <param name="capacity"></param>
|
||||
/// <returns></returns>
|
||||
public LogBuilder UseSyncPipeline(int capacity = 65536)
|
||||
{
|
||||
_useAsyncPipeline = false;
|
||||
_asyncPipelineCapacity = capacity;
|
||||
return this;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Attaches a <see cref="DynamicLevelController"/> so the minimum log level can
|
||||
/// be changed at runtime without restarting the application.
|
||||
|
||||
Reference in New Issue
Block a user