defaultFetchStrategy static method

Future<FetchInstructions?> defaultFetchStrategy(
  1. Uri uri,
  2. FetchFailure? failure
)

The default strategy: 3 attempts, exponential backoff (starting at 100 ms, ×1.5 each retry, ±25% jitter), transient status codes only.

A static method tear-off so it can be used as a const default value.

Implementation

static Future<FetchInstructions?> defaultFetchStrategy(
  Uri uri,
  FetchFailure? failure,
) {
  return const FetchStrategyBuilder().build()(uri, failure);
}