コード例 #1
0
 public Task StopAsync(CancellationToken cancellationToken)
 {
     return(_registry.Stop(cancellationToken));
 }
コード例 #2
0
        public static async Task Stop(this IBusRegistry registry, TimeSpan timeout)
        {
            using var cancellationTokenSource = new CancellationTokenSource(timeout);

            await registry.Stop(cancellationTokenSource.Token).ConfigureAwait(false);
        }