/// <summary> /// /// </summary> /// <param name="serviceProvider"></param> /// <param name="errorHandler"></param> /// <param name="options"></param> protected EventBusBase(IServiceProvider serviceProvider, IEventErrorHandler errorHandler, IOptions <EventBusOptions> options) { ServiceProvider = serviceProvider; ErrorHandler = errorHandler; Options = options.Value; HandlerFactories = new ConcurrentDictionary <Type, List <IEventHandlerFactory> >(); }
public KafkaDistributedEventBus( IServiceScopeFactory serviceScopeFactory, ICurrentTenant currentTenant, IUnitOfWorkManager unitOfWorkManager, IOptions <AbpKafkaEventBusOptions> abpKafkaEventBusOptions, IKafkaMessageConsumerFactory messageConsumerFactory, IOptions <AbpDistributedEventBusOptions> abpDistributedEventBusOptions, IKafkaSerializer serializer, IProducerPool producerPool, IEventErrorHandler errorHandler, IOptions <AbpEventBusOptions> abpEventBusOptions) : base(serviceScopeFactory, currentTenant, unitOfWorkManager, errorHandler) { AbpKafkaEventBusOptions = abpKafkaEventBusOptions.Value; AbpDistributedEventBusOptions = abpDistributedEventBusOptions.Value; AbpEventBusOptions = abpEventBusOptions.Value; MessageConsumerFactory = messageConsumerFactory; Serializer = serializer; ProducerPool = producerPool; DeadLetterTopicName = AbpEventBusOptions.DeadLetterName ?? AbpKafkaEventBusOptions.TopicName + "_dead_letter"; HandlerFactories = new ConcurrentDictionary <Type, List <IEventHandlerFactory> >(); EventTypes = new ConcurrentDictionary <string, Type>(); }
public RabbitEventBus(IServiceProvider serviceProvider, IBus bus, IEventErrorHandler errorHandler, IRabbitMqEventDataSerializer serializer, IOptions<RabbitMQEventBusOptions> options) : base(serviceProvider, errorHandler, options) { Logger = serviceProvider.GetService<ILogger<RabbitEventBus>>(); _bus = bus; Serializer = serializer; _options = options.Value; EventTypes = new ConcurrentDictionary<string, Type>(); }
protected EventBusBase( IServiceScopeFactory serviceScopeFactory, ICurrentTenant currentTenant, IEventErrorHandler errorHandler) { ServiceScopeFactory = serviceScopeFactory; CurrentTenant = currentTenant; ErrorHandler = errorHandler; }
protected EventBusBase( IServiceScopeFactory serviceScopeFactory, ICurrentTenant currentTenant, IUnitOfWorkManager unitOfWorkManager, IEventErrorHandler errorHandler) { ServiceScopeFactory = serviceScopeFactory; CurrentTenant = currentTenant; UnitOfWorkManager = unitOfWorkManager; ErrorHandler = errorHandler; }
public LocalEventBus( IOptions <AbpLocalEventBusOptions> options, IServiceScopeFactory serviceScopeFactory, ICurrentTenant currentTenant, IEventErrorHandler errorHandler) : base(serviceScopeFactory, currentTenant, errorHandler) { Options = options.Value; Logger = NullLogger <LocalEventBus> .Instance; HandlerFactories = new ConcurrentDictionary <Type, List <IEventHandlerFactory> >(); SubscribeHandlers(Options.Handlers); }
public RebusDistributedEventBus( IServiceScopeFactory serviceScopeFactory, ICurrentTenant currentTenant, IBus rebus, IOptions <AbpDistributedEventBusOptions> abpDistributedEventBusOptions, IOptions <AbpRebusEventBusOptions> abpEventBusRebusOptions, IEventErrorHandler errorHandler) : base(serviceScopeFactory, currentTenant, errorHandler) { Rebus = rebus; AbpRebusEventBusOptions = abpEventBusRebusOptions.Value; AbpDistributedEventBusOptions = abpDistributedEventBusOptions.Value; HandlerFactories = new ConcurrentDictionary <Type, List <IEventHandlerFactory> >(); EventTypes = new ConcurrentDictionary <string, Type>(); }
public RabbitMqDistributedEventBus( IOptions <AbpRabbitMqEventBusOptions> options, IConnectionPool connectionPool, IRabbitMqSerializer serializer, IServiceScopeFactory serviceScopeFactory, IOptions <AbpDistributedEventBusOptions> distributedEventBusOptions, IRabbitMqMessageConsumerFactory messageConsumerFactory, ICurrentTenant currentTenant, IEventErrorHandler errorHandler, IOptions <AbpEventBusOptions> abpEventBusOptions) : base(serviceScopeFactory, currentTenant, errorHandler) { ConnectionPool = connectionPool; Serializer = serializer; MessageConsumerFactory = messageConsumerFactory; AbpEventBusOptions = abpEventBusOptions.Value; AbpDistributedEventBusOptions = distributedEventBusOptions.Value; AbpRabbitMqEventBusOptions = options.Value; HandlerFactories = new ConcurrentDictionary <Type, List <IEventHandlerFactory> >(); EventTypes = new ConcurrentDictionary <string, Type>(); }
public LocalEventBus(IServiceProvider serviceProvider, IEventErrorHandler errorHandler, IOptions <EventBusOptions> options) : base(serviceProvider, errorHandler, options) { Logger = serviceProvider.GetService <ILogger <LocalEventBus> >(); }
public Scanner(IDirectory directory, IScanErrorHandler scanErrorHandler, IEventErrorHandler eventErrorHandler) { mDirectory = directory; mScanErrorHandler = scanErrorHandler; mEventErrorHandler = eventErrorHandler; }