Exemplo n.º 1
0
        protected virtual Task Handle(IDomainEvent domainEvent)
        {
            var sagaId = SagaLocator.LocateSaga(domainEvent);
            var saga   = FindOrSpawn(sagaId);

            saga.Tell(domainEvent, Sender);
            return(Task.CompletedTask);
        }
Exemplo n.º 2
0
        protected virtual bool Handle(IDomainEvent domainEvent)
        {
            var sagaId = SagaLocator.LocateSaga(domainEvent);
            var saga   = FindOrSpawn(sagaId);

            saga.Tell(domainEvent, Sender);
            return(true);
        }
Exemplo n.º 3
0
        public Task Handle(IDomainEvent <TestAggregate, TestAggregateId, TestReceivedEvent> domainEvent)
        {
            var sagaId = SagaLocator.LocateSaga(domainEvent);
            var saga   = FindOrSpawn(sagaId);

            saga.Tell(domainEvent, Sender);
            return(Task.CompletedTask);
        }