protected async Task <bool> Handle(StopSystemQuery stopSystemCommand) { await MessageBroker.Request <StopSystemQuery, bool>(StopSystemQuery.Default, _configService); await _configService.StopAsync(); await _scheduler.Shutdown(); _actorFactory.GetExistingActor(nameof(Controller)).Stop(); return(true); }
protected async Task <bool> Handle(StopSystemQuery stopSystemCommand) { await MessageBroker.Request <StopSystemQuery, bool>(StopSystemQuery.Default, _configService); await _configService.StopAsync(); await _scheduler.Shutdown(); Mapper.Reset(); // TODO configuration is using static mapper - fix this because second execution need this static reset _actorFactory.GetExistingActor(nameof(Controller)).Stop(); return(true); }
public void Send(object message, string uid, string address = null) { var pid = _actorFactory.GetExistingActor(uid, address); _actorFactory.Context.Send(pid, message); }