private EventStoreRepository(IEventStoreRepositoryConfiguration configuration, IEventStoreConnection eventStoreConnection, IConnectionStatusMonitor connectionMonitor) { _eventStoreRepositoryConfiguration = configuration; _eventStoreConnection = eventStoreConnection; _eventTypeCache = new Dictionary <string, Type>(); _connectionMonitor = connectionMonitor; }
public static EventStoreRepository Create(IEventStoreRepositoryConfiguration repositoryConfiguration) { var eventStoreConnection = new ExternalEventStore(repositoryConfiguration.ConnectionString, repositoryConfiguration.ConnectionSettings).Connection; var repository = new EventStoreRepository(repositoryConfiguration, eventStoreConnection, new ConnectionStatusMonitor(eventStoreConnection)); return(repository); }
public EventStoreQueueAdapter(string providerName, IEventStoreRepositoryConfiguration eventStoreRepositoryConfiguration, ILoggerFactory loggerFactory) { _eventStoreRepositoryConfiguration = eventStoreRepositoryConfiguration; _loggerFactory = loggerFactory; Name = providerName; EventStore = EventStoreRepository.Create(eventStoreRepositoryConfiguration); }
public EventStoreAdapterFactory(string providerName, IEventStoreStreamProviderConfiguration streamProviderConfiguration, ILoggerFactory loggerFactory) { _streamProviderConfiguration = streamProviderConfiguration; _loggerFactory = loggerFactory; _providerName = providerName; _receivers = new ConcurrentDictionary <QueueId, EventStoreQueueAdapterReceiver>(); _eventStoreQueueAdapterCache = new EventStoreQueueAdapterCache(this, loggerFactory); var hashRingStreamQueueMapperOptions = new HashRingStreamQueueMapperOptions() { TotalQueueCount = 2 }; _streamQueueMapper = new HashRingBasedStreamQueueMapper(hashRingStreamQueueMapperOptions, _providerName); }
public EventStoreRepository( IEventStoreRepositoryConfiguration eventStoreRepositoryConfiguration, IEventStoreConnection eventStoreConnection, IConnectionStatusMonitor <IEventStoreConnection> connectionMonitor, ILoggerFactory loggerFactory) { Logger = loggerFactory?.CreateLogger <EventStoreRepository>(); Id = $"{GetType()}-{Guid.NewGuid()}"; _eventStoreRepositoryConfiguration = eventStoreRepositoryConfiguration; _eventStoreConnection = eventStoreConnection; _cleanup = connectionMonitor.OnConnected .Subscribe(isConnected => { IsConnected = isConnected; }); }
public EventStoreAggregateRepository(IEventStoreRepositoryConfiguration eventStoreRepositoryConfiguration, IEventStoreConnection eventStoreConnection, IConnectionStatusMonitor <IEventStoreConnection> connectionMonitor, ILoggerFactory loggerFactory) : base(eventStoreRepositoryConfiguration, eventStoreConnection, connectionMonitor, loggerFactory) { }
public CcyPairGrain(IEventStoreRepositoryConfiguration eventStoreConfiguration) : base(eventStoreConfiguration) { }
protected EventStoreJournaledGrain(IEventStoreRepositoryConfiguration eventStoreConfiguration) { _eventStoreConfiguration = eventStoreConfiguration; }