Interface IExecutableInRetryableWriteContext<TResult>
- Namespace
- MongoDB.Driver.Core.Operations
- Assembly
- MongoDB.Driver.Core.dll
Represents an operation (that may or may not be retryable) that can be executed in a retryable write context.
public interface IExecutableInRetryableWriteContext<TResult>
Type Parameters
TResult
The type of the result.
Methods
Execute(RetryableWriteContext, CancellationToken)
Executes the first attempt.
TResult Execute(RetryableWriteContext context, CancellationToken cancellationToken)
Parameters
context
RetryableWriteContextThe context.
cancellationToken
CancellationTokenThe cancellation token.
Returns
- TResult
The result.
ExecuteAsync(RetryableWriteContext, CancellationToken)
Executes the first attempt.
Task<TResult> ExecuteAsync(RetryableWriteContext context, CancellationToken cancellationToken)
Parameters
context
RetryableWriteContextThe context.
cancellationToken
CancellationTokenThe cancellation token.
Returns
- Task<TResult>
The result.