traceAsyncOperation<T> method

Future<T> traceAsyncOperation<T>(
  1. TracedOperation operation,
  2. Future<T> execute()
)

Called when an asynchronous operation trace point is reached.

T is the type of the result of the operation.

The method must call execute exactly once. execute might throw a synchronous exception or return a Future that completes with an exception. This method must return a Future that completes with the same value as execute or completes with the same exception as execute.

Implementation

Future<T> traceAsyncOperation<T>(
  TracedOperation operation,
  Future<T> Function() execute,
) =>
    execute();