/// <summary>Parameterized constructor. /// </summary> /// <param name="processingCommandCache"></param> /// <param name="commandAsyncResultManager"></param> /// <param name="aggregateRootTypeProvider"></param> /// <param name="aggregateRootFactory"></param> /// <param name="memoryCache"></param> /// <param name="repository"></param> /// <param name="retryCommandService"></param> /// <param name="eventStore"></param> /// <param name="eventPublisher"></param> /// <param name="retryService"></param> /// <param name="eventSynchronizerProvider"></param> /// <param name="loggerFactory"></param> public DefaultUncommittedEventExecutor( IProcessingCommandCache processingCommandCache, ICommandAsyncResultManager commandAsyncResultManager, IAggregateRootTypeProvider aggregateRootTypeProvider, IAggregateRootFactory aggregateRootFactory, IMemoryCache memoryCache, IRepository repository, IRetryCommandService retryCommandService, IEventStore eventStore, IEventPublisher eventPublisher, IRetryService retryService, IEventSynchronizerProvider eventSynchronizerProvider, ILoggerFactory loggerFactory) { _processingCommandCache = processingCommandCache; _commandAsyncResultManager = commandAsyncResultManager; _aggregateRootTypeProvider = aggregateRootTypeProvider; _aggregateRootFactory = aggregateRootFactory; _memoryCache = memoryCache; _repository = repository; _retryCommandService = retryCommandService; _eventStore = eventStore; _eventPublisher = eventPublisher; _retryService = retryService; _eventSynchronizerProvider = eventSynchronizerProvider; _logger = loggerFactory.Create(GetType().Name); }
/// <summary>Parameterized constructor. /// </summary> /// <param name="processingCommandCache"></param> /// <param name="commandAsyncResultManager"></param> /// <param name="commandHandlerProvider"></param> /// <param name="aggregateRootTypeProvider"></param> /// <param name="eventSender"></param> /// <param name="retryService"></param> /// <param name="commandContext"></param> /// <param name="loggerFactory"></param> /// <exception cref="Exception"></exception> public DefaultCommandExecutor( IProcessingCommandCache processingCommandCache, ICommandAsyncResultManager commandAsyncResultManager, ICommandHandlerProvider commandHandlerProvider, IAggregateRootTypeProvider aggregateRootTypeProvider, IEventSender eventSender, IRetryService retryService, ICommandContext commandContext, ILoggerFactory loggerFactory) { _processingCommandCache = processingCommandCache; _commandAsyncResultManager = commandAsyncResultManager; _commandHandlerProvider = commandHandlerProvider; _aggregateRootTypeProvider = aggregateRootTypeProvider; _eventSender = eventSender; _retryService = retryService; _commandContext = commandContext; _trackingContext = commandContext as ITrackingContext; _logger = loggerFactory.Create(GetType().Name); if (_trackingContext == null) { throw new Exception("Command context must also implement ITrackingContext interface."); } }
public DefaultCommandExecutor( IProcessingCommandCache processingCommandCache, ICommandAsyncResultManager commandAsyncResultManager, ICommandHandlerProvider commandHandlerProvider, IAggregateRootTypeProvider aggregateRootTypeProvider, IMemoryCache memoryCache, IRepository repository, IRetryCommandService retryCommandService, IEventStore eventStore, IEventPublisher eventPublisher, IEventPersistenceSynchronizerProvider eventPersistenceSynchronizerProvider, ICommandContext commandContext, ILoggerFactory loggerFactory) { _processingCommandCache = processingCommandCache; _commandAsyncResultManager = commandAsyncResultManager; _commandHandlerProvider = commandHandlerProvider; _aggregateRootTypeProvider = aggregateRootTypeProvider; _memoryCache = memoryCache; _repository = repository; _retryCommandService = retryCommandService; _eventStore = eventStore; _eventPublisher = eventPublisher; _eventPersistenceSynchronizerProvider = eventPersistenceSynchronizerProvider; _commandContext = commandContext; _trackingContext = commandContext as ITrackingContext; _logger = loggerFactory.Create(GetType().Name); if (_trackingContext == null) { throw new Exception("command context must also implement ITrackingContext interface."); } }
public EventSourcingRepository(IAggregateRootTypeProvider aggregateRootTypeProvider, IAggregateRootFactory aggregateRootFactory, IMemoryCache memoryCache, IEventStore eventStore, ISnapshotStore snapshotStore) { _aggregateRootTypeProvider = aggregateRootTypeProvider; _aggregateRootFactory = aggregateRootFactory; _memoryCache = memoryCache; _eventStore = eventStore; _snapshotStore = snapshotStore; }
public DefaultMemoryCacheRebuilder( IAggregateRootFactory aggregateRootFactory, IAggregateRootTypeProvider aggregateRootTypeProvider, IEventStore eventStore, IMemoryCache memoryCache) { _aggregateRootFactory = aggregateRootFactory; _aggregateRootTypeProvider = aggregateRootTypeProvider; _eventStore = eventStore; _memoryCache = memoryCache; }
public DefaultMemoryCacheRebuilder( IAggregateRootFactory aggregateRootFactory, IAggregateRootTypeProvider aggregateRootTypeProvider, IEventStore eventStore, IMemoryCache memoryCache) { _aggregateRootFactory = aggregateRootFactory; _aggregateRootTypeProvider = aggregateRootTypeProvider; _eventStore = eventStore; _memoryCache = memoryCache; }
public DefaultMemoryCacheRefreshService( IMemoryCache memoryCache, IRepository repository, IAggregateRootFactory aggregateRootFactory, IAggregateRootTypeProvider aggregateRootTypeProvider) { _memoryCache = memoryCache; _repository = repository; _aggregateRootFactory = aggregateRootFactory; _aggregateRootTypeProvider = aggregateRootTypeProvider; }
/// <summary>Parameterized constructor. /// </summary> /// <param name="connectionString"></param> /// <exception cref="ArgumentNullException"></exception> public SqlEventStore(string connectionString) { if (string.IsNullOrEmpty(connectionString)) { throw new ArgumentNullException("connectionString"); } _connectionString = connectionString; _eventTableProvider = ObjectContainer.Resolve<IEventTableNameProvider>(); _jsonSerializer = ObjectContainer.Resolve<IJsonSerializer>(); _connectionFactory = ObjectContainer.Resolve<IDbConnectionFactory>(); _aggregateRootTypeProvider = ObjectContainer.Resolve<IAggregateRootTypeProvider>(); }
/// <summary>Parameterized constructor. /// </summary> /// <param name="connectionString"></param> /// <exception cref="ArgumentNullException"></exception> public SqlEventStore(string connectionString) { if (string.IsNullOrEmpty(connectionString)) { throw new ArgumentNullException("connectionString"); } _connectionString = connectionString; _eventTableProvider = ObjectContainer.Resolve <IEventTableNameProvider>(); _jsonSerializer = ObjectContainer.Resolve <IJsonSerializer>(); _connectionFactory = ObjectContainer.Resolve <IDbConnectionFactory>(); _aggregateRootTypeProvider = ObjectContainer.Resolve <IAggregateRootTypeProvider>(); }
public MongoEventStore(string connectionString) { if (string.IsNullOrEmpty(connectionString)) { throw new ArgumentNullException("connectionString"); } _connectionString = connectionString; _eventCollectionNameProvider = ObjectContainer.Resolve <IEventCollectionNameProvider>(); _binarySerializer = ObjectContainer.Resolve <IBinarySerializer>(); _aggregateRootTypeProvider = ObjectContainer.Resolve <IAggregateRootTypeProvider>(); }
/// <summary>Parameterized constructor. /// </summary> /// <param name="connectionString"></param> /// <exception cref="ArgumentNullException"></exception> public MongoEventStore(string connectionString) { if (string.IsNullOrEmpty(connectionString)) { throw new ArgumentNullException("connectionString"); } _connectionString = connectionString; _eventCollectionNameProvider = ObjectContainer.Resolve<IEventCollectionNameProvider>(); _binarySerializer = ObjectContainer.Resolve<IBinarySerializer>(); _aggregateRootTypeProvider = ObjectContainer.Resolve<IAggregateRootTypeProvider>(); }
public DefaultCommandExecutor( IProcessingCommandCache processingCommandCache, ICommandAsyncResultManager commandAsyncResultManager, ICommandHandlerProvider commandHandlerProvider, IAggregateRootTypeProvider aggregateRootTypeProvider, IMemoryCacheRefreshService memoryCacheRefreshService, IRetryCommandService retryCommandService, IEventStore eventStore, IEventPublisher eventPublisher, ICommandContext commandContext, ILoggerFactory loggerFactory) { _processingCommandCache = processingCommandCache; _commandAsyncResultManager = commandAsyncResultManager; _commandHandlerProvider = commandHandlerProvider; _aggregateRootTypeProvider = aggregateRootTypeProvider; _memoryCacheRefreshService = memoryCacheRefreshService; _retryCommandService = retryCommandService; _eventStore = eventStore; _eventPublisher = eventPublisher; _commandContext = commandContext; _trackingContext = commandContext as ITrackingContext; _logger = loggerFactory.Create(GetType().Name); }
/// <summary>Parameterized constructor. /// </summary> /// <param name="aggregateRootTypeProvider"></param> public AggregatePerEventCollectionNameProvider(IAggregateRootTypeProvider aggregateRootTypeProvider) { _aggregateRootTypeProvider = aggregateRootTypeProvider; }
public AggregatePerEventTableNameProvider(IAggregateRootTypeProvider aggregateRootTypeProvider) { _aggregateRootTypeProvider = aggregateRootTypeProvider; }
public DefaultSnapshotter(IAggregateRootFactory aggregateRootFactory, IAggregateRootTypeProvider aggregateRootTypeProvider) { _aggregateRootFactory = aggregateRootFactory; _aggregateRootTypeProvider = aggregateRootTypeProvider; }
/// <summary>Parameterized constructor. /// </summary> /// <param name="aggregateRootTypeProvider"></param> public AggregatePerEventTableNameProvider(IAggregateRootTypeProvider aggregateRootTypeProvider) { _aggregateRootTypeProvider = aggregateRootTypeProvider; }
public AggregatePerEventCollectionNameProvider(IAggregateRootTypeProvider aggregateRootTypeProvider) { _aggregateRootTypeProvider = aggregateRootTypeProvider; }