ServicePartitionClient<TCommunicationClient>.InvokeWithRetry Method

Definition

Overloads

InvokeWithRetry(Action<TCommunicationClient>, Type[])

Invokes the given Function, retrying for exceptions thrown other than the exceptions in the doNotRetryExceptionTypes. For exceptions that are not in doNotRetryExceptionTypes, CommunicationClientFactory's ReportOperationExceptionAsync() method controls if the exception should be retried or not.

InvokeWithRetry<TResult>(Func<TCommunicationClient,TResult>, Type[])

Invokes the given Function, retrying for exceptions thrown other than the exceptions in the doNotRetryExceptionTypes. For exceptions that are not in doNotRetryExceptionTypes, CommunicationClientFactory's ReportOperationExceptionAsync() method controls if the exception should be retried or not.

InvokeWithRetry(Action<TCommunicationClient>, Type[])

Invokes the given Function, retrying for exceptions thrown other than the exceptions in the doNotRetryExceptionTypes. For exceptions that are not in doNotRetryExceptionTypes, CommunicationClientFactory's ReportOperationExceptionAsync() method controls if the exception should be retried or not.

public void InvokeWithRetry (Action<TCommunicationClient> func, params Type[] doNotRetryExceptionTypes);
member this.InvokeWithRetry : Action<'CommunicationClient (requires 'CommunicationClient :> Microsoft.ServiceFabric.Services.Communication.Client.ICommunicationClient)> * Type[] -> unit
Public Sub InvokeWithRetry (func As Action(Of TCommunicationClient), ParamArray doNotRetryExceptionTypes As Type())

Parameters

func
Action<TCommunicationClient>

Function being invoked

doNotRetryExceptionTypes
Type[]

Exceptions for which the service partition client should not retry

Applies to

Product Introduced

InvokeWithRetry<TResult>(Func<TCommunicationClient,TResult>, Type[])

Invokes the given Function, retrying for exceptions thrown other than the exceptions in the doNotRetryExceptionTypes. For exceptions that are not in doNotRetryExceptionTypes, CommunicationClientFactory's ReportOperationExceptionAsync() method controls if the exception should be retried or not.

public TResult InvokeWithRetry<TResult> (Func<TCommunicationClient,TResult> func, params Type[] doNotRetryExceptionTypes);
member this.InvokeWithRetry : Func<'CommunicationClient, 'Result (requires 'CommunicationClient :> Microsoft.ServiceFabric.Services.Communication.Client.ICommunicationClient)> * Type[] -> 'Result
Public Function InvokeWithRetry(Of TResult) (func As Func(Of TCommunicationClient, TResult), ParamArray doNotRetryExceptionTypes As Type()) As TResult

Type Parameters

TResult

Result from the function being invoked

Parameters

func
Func<TCommunicationClient,TResult>

Function being invoked

doNotRetryExceptionTypes
Type[]

Exceptions for which the service partition client should not retry

Returns

TResult

Result from the function given in the argument

Applies to

Product Introduced