Beispiel #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="EventStore"/> class.
 /// </summary>
 /// <param name="executionContextManager">The <see cref="IExecutionContextManager" />.</param>
 /// <param name="streams">The <see cref="IStreams"/>.</param>
 /// <param name="eventCommitter">The <see cref="IEventCommitter" />.</param>
 /// <param name="aggregateRoots">The <see cref="IAggregateRoots" />.</param>
 /// <param name="logger">An <see cref="ILogger"/>.</param>
 public EventStore(
     IExecutionContextManager executionContextManager,
     IStreams streams,
     IEventCommitter eventCommitter,
     IAggregateRoots aggregateRoots,
     ILogger logger)
 {
     _executionContextManager = executionContextManager;
     _streams        = streams;
     _eventCommitter = eventCommitter;
     _aggregateRoots = aggregateRoots;
     _logger         = logger;
 }
Beispiel #2
0
 public ProcessingCommandHandler(
     IProcessingCommandHandlerContextFactory contextFactory,
     IEventCommitter eventCommitter,
     IEventStore eventStore,
     IEventPublisher eventPublisher,
     IApplicationMessagePublisher applicationMessagePublisher,
     IStringObjectSerializer objectSerializer,
     IServiceProvider serviceProvider,
     ILogger <ProcessingCommandHandler> logger)
 {
     this.contextFactory = contextFactory;
     this.eventCommitter = eventCommitter;
     this.eventStore     = eventStore;
     this.eventPublisher = eventPublisher;
     this.applicationMessagePublisher = applicationMessagePublisher;
     this.objectSerializer            = objectSerializer;
     this.serviceProvider             = serviceProvider;
     this.logger         = logger;
     handlerMapping      = new ConcurrentDictionary <Type, ICommandHandler>();
     asyncHandlerMapping = new ConcurrentDictionary <Type, ICommandAsyncHandler>();
 }