public DeliveryService(IDeliveryRepository deliveryRepository, ICourierRepository courierRepository, IMapper mapper, IIntegrationEventPublisher integrationEventPublisher) { _mapper = mapper; _integrationEventPublisher = integrationEventPublisher; _deliveryRepository = deliveryRepository; _courierRepository = courierRepository; }
// This method gets called by the runtime. Use this method to configure the HTTP request pipeline. public void Configure(IApplicationBuilder app, IIntegrationEventPublisher publisher) { foreach (var i in Enumerable.Range(0, 10)) { publisher.PublishAsync(new TestEvent { Name = $"test message {i}" }).GetAwaiter().GetResult(); Thread.Sleep(i * 1000); } }
public TicketPriorityEventHandler(ITicketQueryRepository ticketRepository, IPriorityQueryRepository priorityRepository, ITicketEventQueryRepository eventRepository, IMapper mapper, IWebsocketEmittor websocketEmittor, IIntegrationEventPublisher eventPublisher) { _ticketRepository = ticketRepository ?? throw new ArgumentNullException(nameof(ticketRepository)); _priorityRepository = priorityRepository ?? throw new ArgumentNullException(nameof(priorityRepository)); _eventRepository = eventRepository ?? throw new ArgumentNullException(nameof(eventRepository)); _mapper = mapper ?? throw new ArgumentNullException(nameof(mapper)); _websocketEmittor = websocketEmittor ?? throw new ArgumentNullException(nameof(websocketEmittor)); _eventPublisher = eventPublisher ?? throw new ArgumentNullException(nameof(eventPublisher)); }
/// <summary> /// Initializes a new instance of the <see cref="PublishIntegrationEventOnFriendshipRequestSentDomainEventHandler"/> class. /// </summary> /// <param name="integrationEventPublisher">The integration event publisher.</param> public PublishIntegrationEventOnFriendshipRequestSentDomainEventHandler(IIntegrationEventPublisher integrationEventPublisher) =>
/// <summary> /// Initializes a new instance of the <see cref="PublishIntegrationEventOnInvitationAcceptedDomainEventHandler"/> class. /// </summary> /// <param name="integrationEventPublisher">The integration event publisher.</param> public PublishIntegrationEventOnInvitationAcceptedDomainEventHandler(IIntegrationEventPublisher integrationEventPublisher) =>
/// <summary> /// Initializes a new instance of the <see cref="PublishIntegrationEventOnUserPasswordChangedDomainEventHandler"/> class. /// </summary> /// <param name="integrationEventPublisher">The integration event publisher.</param> public PublishIntegrationEventOnUserPasswordChangedDomainEventHandler(IIntegrationEventPublisher integrationEventPublisher) =>
/// <summary> /// Initializes a new instance of the <see cref="PublishIntegrationEventOnFriendshipRequestAcceptedDomainEventHandler"/> class. /// </summary> /// <param name="integrationEventPublisher">The integration event publisher.</param> public PublishIntegrationEventOnFriendshipRequestAcceptedDomainEventHandler(IIntegrationEventPublisher integrationEventPublisher) => _integrationEventPublisher = integrationEventPublisher;
/// <summary> /// Initializes a new instance of the <see cref="PublishIntegrationEventOnGroupEventNameChangedDomainEventHandler"/> class. /// </summary> /// <param name="integrationEventPublisher">The integration event publisher.</param> public PublishIntegrationEventOnGroupEventNameChangedDomainEventHandler(IIntegrationEventPublisher integrationEventPublisher) =>
/// <summary> Creates an instance of the <b>NotesController</b> class. </summary> /// <param name="noteRepository"> Note repository </param> /// <param name="integrationEventPublisher"> Integration Event Publisher </param> public NotesController(INoteRepository noteRepository, IIntegrationEventPublisher integrationEventPublisher) { myIntegrationEventPublisher = integrationEventPublisher; myNoteRepository = noteRepository; }
/// <summary> /// Initializes a new instance of the <see cref="PublishIntegrationEventOnUserCreatedDomainEventHandler"/> class. /// </summary> /// <param name="integrationEventPublisher">The integration event publisher.</param> public PublishIntegrationEventOnUserCreatedDomainEventHandler(IIntegrationEventPublisher integrationEventPublisher) =>
/// <summary> /// Initializes a new instance of the <see cref="PublishIntegrationEventOnAttendeeCreatedEventHandler"/> class. /// </summary> /// <param name="integrationEventPublisher">The integration event publisher.</param> public PublishIntegrationEventOnAttendeeCreatedEventHandler(IIntegrationEventPublisher integrationEventPublisher) =>
public TransactionalBehavior(DataContext dataContext, IIntegrationEventPublisher integrationEventPublisher) { _dataContext = dataContext; _integrationEventPublisher = integrationEventPublisher; }
/// <summary> /// Initializes a new instance of the <see cref="PublishIntegrationEventOnGroupEventCancelledDomainEventHandler"/> class. /// </summary> /// <param name="integrationEventPublisher">The integration event publisher.</param> public PublishIntegrationEventOnGroupEventCancelledDomainEventHandler(IIntegrationEventPublisher integrationEventPublisher) =>
public StockSnapshotService(DataContext dataContext, IIntegrationEventPublisher integrationEventPublisher) { _dataContext = dataContext; _integrationEventPublisher = integrationEventPublisher; }