private static void RunRpcOperation(string serverName, int?timeoutMs, DagNetworkRpc.InternalRpcOperation rpcOperation)
        {
            RpcErrorExceptionInfo errorInfo = null;

            TasksRpcExceptionWrapper.Instance.ClientRetryableOperation(serverName, delegate
            {
                using (ReplayRpcClient replayRpcClient = DagNetworkRpc.RpcClientFactory(serverName, timeoutMs))
                {
                    errorInfo = rpcOperation(replayRpcClient);
                }
            });
            TasksRpcExceptionWrapper.Instance.ClientRethrowIfFailed(serverName, errorInfo);
        }
 private static ReplayRpcClient RpcClientFactory(string serverName)
 {
     return(DagNetworkRpc.RpcClientFactory(serverName, null));
 }