Table of Contents

Class RetryHandler

Namespace
Phetch.Core
Assembly
Phetch.Core.dll

A helper class for creating retry handlers.

public static class RetryHandler
Inheritance
RetryHandler
Inherited Members

Properties

None

If passed in the options to Endpoint.Use, this will override the default retry handler for the endpoint.

Example:
var query = endpoint.Use(new()
{
    RetryHandler = RetryHandler.None
});
public static NoRetryHandler None { get; }

Property Value

NoRetryHandler

Methods

Simple(int)

A simple retry handler that retries a given number of times with no waiting between retries.

This will retry if the query function throws an exception other than OperationCanceledException.
public static SimpleRetryHandler Simple(int maxRetries)

Parameters

maxRetries int

Returns

SimpleRetryHandler

Remarks

Construct this using Simple(int).

Example:
RetryHandler = RetryHandler.Simple(2);