Example #1
0
        private async Task ProcessAsync()
        {
            try
            {
                await _brokerProcessor.Completion.ConfigureAwait(false);
            }
            finally
            {
                await _appLifecycleManager.StopAsync().IgnoreExceptions().ConfigureAwait(false);

                await Task.WhenAll(_transportServers.Select(x => x.StopAsync())).ConfigureAwait(false);
            }
        }