Пример #1
0
 public static IServiceCollection AddDaprServer(this IServiceCollection services, params Type[] hostedServices)
 {
     ServiceLoader.RegisterServices(hostedServices);
     return(services
            .AddTransient <ServiceLoader>()
            .AddTransient <DaprServer>());
 }
Пример #2
0
 public DaprServer(IServiceScopeFactory scopeFactory, ServiceLoader serviceLoader)
 {
     _serviceLoader = serviceLoader;
 }