public DomainEventConsumer InitializeENode(bool sendEventHandledMessage = true) { _sendReplyService = new SendReplyService("EventConsumerSendReplyService"); _jsonSerializer = ObjectContainer.Resolve <IJsonSerializer>(); _eventSerializer = ObjectContainer.Resolve <IEventSerializer>(); _messageProcessor = ObjectContainer.Resolve <IMessageProcessor <ProcessingDomainEventStreamMessage, DomainEventStreamMessage> >(); _logger = ObjectContainer.Resolve <ILoggerFactory>().Create(GetType().FullName); _sendEventHandledMessage = sendEventHandledMessage; return(this); }
public CommandExecuteContext(IRepository repository, IAggregateStorage aggregateRootStorage, KafkaMessage kafkaMessage, IKafkaMessageContext messageContext, CommandMessage commandMessage, SendReplyService sendReplyService) { _trackingAggregateRootDict = new ConcurrentDictionary <string, IAggregateRoot>(); _repository = repository; _aggregateRootStorage = aggregateRootStorage; _sendReplyService = sendReplyService; _kafkaMessage = kafkaMessage; _commandMessage = commandMessage; _messageContext = messageContext; }
public DomainEventConsumer InitializeENode(bool sendEventHandledMessage = true) { _sendReplyService = new SendReplyService("EventConsumerSendReplyService"); _jsonSerializer = ObjectContainer.Resolve <IJsonSerializer>(); _eventSerializer = ObjectContainer.Resolve <IEventSerializer>(); _messageProcessor = ObjectContainer.Resolve <IProcessingEventProcessor>(); _logger = ObjectContainer.Resolve <ILoggerFactory>().Create(nameof(DomainEventConsumer)); _sendEventHandledMessage = sendEventHandledMessage; return(this); }
public CommandConsumer InitializeENode() { _sendReplyService = new SendReplyService("CommandConsumerSendReplyService"); _jsonSerializer = ObjectContainer.Resolve <IJsonSerializer>(); _typeNameProvider = ObjectContainer.Resolve <ITypeNameProvider>(); _commandProcessor = ObjectContainer.Resolve <ICommandProcessor>(); _repository = ObjectContainer.Resolve <IRepository>(); _aggregateStorage = ObjectContainer.Resolve <IAggregateStorage>(); _logger = ObjectContainer.Resolve <ILoggerFactory>().Create(nameof(CommandConsumer)); return(this); }