CommitAsync() public method

public CommitAsync ( CancellationToken token ) : Task
token System.Threading.CancellationToken
return Task
コード例 #1
0
        public async Task CommitAsync(CancellationToken token)
        {
            if (_mode == CommandRunnerMode.External)
            {
                return;
            }

            await buildConnectionAsync(token).ConfigureAwait(false);

            await _retryPolicy.ExecuteAsync(async() => await _connection.CommitAsync(token).ConfigureAwait(false), token);

            await _connection.CommitAsync(token).ConfigureAwait(false);

            _connection.Dispose();
            _connection = null;
        }
コード例 #2
0
        public async Task CommitAsync(CancellationToken token)
        {
            await buildConnectionAsync(token).ConfigureAwait(false);

            await _connection.CommitAsync(token).ConfigureAwait(false);

            _connection.Dispose();
            _connection = null;
        }