public static Task SetStoppedNodeStateAsync(Guid operationId, IStatefulServicePartition partition, IReliableStateManager stateManager, IReliableDictionary <string, bool> stoppedNodeTable, string nodeName, bool setStopped, CancellationToken cancellationToken)
 {
     return(FaultAnalysisServiceUtility.RunAndReportFaultOnRepeatedFailure(
                operationId,
                () => SetStoppedNodeStateInnerAsync(operationId, stateManager, stoppedNodeTable, nodeName, setStopped, cancellationToken),
                partition,
                "FaultAnalysisServiceUtility.SetStoppedNodeStateAsync",
                3,
                cancellationToken));
 }
 public static Task RunAndReportFaultOnRepeatedFailure(Guid operationId, Func <Task> action, IStatefulServicePartition partition, string caller, int numRetries, CancellationToken cancellationToken)
 {
     return(FaultAnalysisServiceUtility.RunAndReportFaultOnRepeatedFailure(
                operationId,
                async() =>
     {
         await action.Invoke();
         return new object();
     },
                partition,
                caller,
                numRetries,
                cancellationToken));
 }