Used to decide if the repository should retry after an error.
@protected FutureOr<bool> shouldRetry(Exception exception) => true;