public EventStoreListener(ITriggeredFunctionExecutor executor, IEventStoreSubscription eventStoreSubscription, TraceWriter trace) { _executor = executor; _eventStoreSubscription = eventStoreSubscription; _trace = trace; }
private void Dispose(bool isDisposing) { if (isDisposing) { Cancel(); _eventStoreSubscription = null; } GC.SuppressFinalize(this); }
public QuerySideInitializer( IEventStoreSubscription <CustomerQueueSubscription> customerQueueEventStoreSubscription, IDomainEventBus domainEventBus, IClientNotifier clientNotifier, ViewHolder viewHolder) { _customerQueueEventStoreSubscription = customerQueueEventStoreSubscription; _domainEventBus = domainEventBus; _clientNotifier = clientNotifier; _viewHolder = viewHolder; }
public LiveProcessingStartedListener(ITriggeredFunctionExecutor executor, IEventStoreSubscription eventStoreSubscription, int batchSize, int timeoutInMilliseconds, TraceWriter trace) { _executor = executor; _eventStoreSubscription = eventStoreSubscription; _batchSize = batchSize; _timeoutInMilliseconds = timeoutInMilliseconds; _trace = trace; }
/// <summary> /// Method called when jobhost starts. /// </summary> /// <param name="context"></param> public void Initialize(ExtensionConfigContext context) { if (context == null) { throw new ArgumentNullException("context"); } if (EventStoreConnectionFactory == null) { EventStoreConnectionFactory = new EventStoreConnectionFactory(); } if (UserCredentialFactory == null) { UserCredentialFactory = new UserCredentialFactory(); } if (MaxLiveQueueSize == 0) { MaxLiveQueueSize = 200; } _eventStoreSubscription = new EventStoreCatchUpSubscriptionObservable(EventStoreConnectionFactory.Create(ConnectionString), LastPosition, MaxLiveQueueSize, UserCredentialFactory.CreateAdminCredentials(Username, Password), context.Trace); var triggerBindingProvider = new EventTriggerAttributeBindingProvider <EventTriggerAttribute>( BuildListener, context.Config, context.Trace); var liveProcessingStartedBindingProvider = new LiveProcessingStartedAttributeBindingProvider( BuildListener, context.Trace); // Register our extension binding providers context.Config.RegisterBindingExtensions( triggerBindingProvider); context.Config.RegisterBindingExtensions( liveProcessingStartedBindingProvider); }