public async Task Stop() { _cancellation.Cancel(); if (_connection != null) { _connection.SafeDispose(); if (_daemon != null) { await _daemon.StopAll().ConfigureAwait(false); } } }
public async Task StopAsync(CancellationToken cancellationToken) { try { await _coordinator.Stop(); await _agent.StopAll(); } catch (Exception e) { _logger.LogError(e, "Error when trying to stop the asynchronous projection agent"); } }
public Task Stop() { return(_agent.StopAll()); }