baseline: 小军 WMS 二开代码原始快照(含 SynOABusiness.cs Debugger.Break)
This commit is contained in:
commit
c2b0e7be0d
6522 files changed
+3530643
No files matched your search
@@ -0,0 +1,24 @@
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.Extensions.DependencyInjection.Extensions;
|
||||
using Opsoft.NetCore.O3App.Domain;
|
||||
|
||||
namespace Opsoft.NetCore.O3App.Infrastructure
|
||||
{
|
||||
/// <summary>
|
||||
/// Extensions on the <see cref="IServiceCollection"/>.
|
||||
/// </summary>
|
||||
public static class TraceIdServiceExtensions
|
||||
{
|
||||
/// <summary>
|
||||
/// Adds required services to support the Trace ID functionality.
|
||||
/// </summary>
|
||||
/// <param name="serviceCollection"></param>
|
||||
public static IServiceCollection AddTraceId(this IServiceCollection serviceCollection)
|
||||
{
|
||||
serviceCollection.TryAddSingleton<ITraceContextAccessor, TraceContextAccessor>();
|
||||
serviceCollection.TryAddTransient<ITraceContextFactory, TraceContextFactory>();
|
||||
|
||||
return serviceCollection;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user