internal Bus(ILogger logger, ICommandSender commandSender, IRequestSender requestSender, IMulticastRequestSender multicastRequestSender, IEventSender eventSender, IMessagePumpsManager messagePumpsManager, IDeadLetterOffice deadLetterOffice, IHeartbeat heartbeat) { _logger = logger; _commandSender = commandSender; _requestSender = requestSender; _multicastRequestSender = multicastRequestSender; _eventSender = eventSender; _heartbeat = heartbeat; _messagePumpsManager = messagePumpsManager; DeadLetterOffice = deadLetterOffice; Started += async delegate { await _heartbeat.Start(); }; Stopping += async delegate { await _heartbeat.Stop(); }; }
internal Bus(ILogger logger, ICommandSender commandSender, IRequestSender requestSender, IMulticastRequestSender multicastRequestSender, IEventSender eventSender, IMessagePumpsManager messagePumpsManager, IDeadLetterQueues deadLetterQueues, INimbusTaskFactory taskFactory, IHeartbeat heartbeat) { _logger = logger; _commandSender = commandSender; _requestSender = requestSender; _multicastRequestSender = multicastRequestSender; _eventSender = eventSender; _deadLetterQueues = deadLetterQueues; _taskFactory = taskFactory; _heartbeat = heartbeat; _messagePumpsManager = messagePumpsManager; Started += async delegate { await _heartbeat.Start(); }; Stopping += async delegate { await _heartbeat.Stop(); }; }
public Task Execute(IJobExecutionContext context) { return(_heartbeat.Start()); }