private static ReplayRpcClient RpcClientFactory(string serverName, int?timeoutMs) { ReplayRpcClient replayRpcClient = new ReplayRpcClient(serverName); if (timeoutMs != null) { replayRpcClient.SetTimeOut(timeoutMs.Value); } return(replayRpcClient); }
private static ReplayRpcClient RpcClientFactory(AmServerName serverName, int timeoutMs) { ReplayRpcClient replayRpcClient = new ReplayRpcClient(serverName.Fqdn); if (timeoutMs != -1) { replayRpcClient.SetTimeOut(timeoutMs); } return(replayRpcClient); }
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 void RunRpcOperationDbName(AmServerName serverName, string databaseName, int timeoutMs, IHaRpcExceptionWrapper rpcExceptionWrapperInstance, ReplayRpcClientWrapper.InternalRpcOperation rpcOperation) { RpcErrorExceptionInfo errorInfo = null; rpcExceptionWrapperInstance.ClientRetryableOperation(serverName.Fqdn, delegate { using (ReplayRpcClient replayRpcClient = ReplayRpcClientWrapper.RpcClientFactory(serverName, timeoutMs)) { errorInfo = rpcOperation(replayRpcClient); } }); rpcExceptionWrapperInstance.ClientRethrowIfFailed(databaseName, serverName.Fqdn, errorInfo); }
// Token: 0x06001A41 RID: 6721 RVA: 0x0006E618 File Offset: 0x0006C818 public static SeederClient Create(string serverName, string databaseName, string sourceName, ServerVersion serverVersion) { if (!ReplayRpcVersionControl.IsSeedRpcSupported(serverVersion)) { throw new SeederRpcUnsupportedException(serverName, serverVersion.ToString(), ReplayRpcVersionControl.SeedRpcSupportVersion.ToString()); } ExTraceGlobals.SeederClientTracer.TraceDebug <string, ServerVersion>(0L, "SeederClient is now being created for server '{0}' with version '0x{1:x}'.", serverName, serverVersion); ReplayRpcClient rpcClient = null; SeederRpcExceptionWrapper.Instance.ClientRetryableOperation(serverName, delegate { rpcClient = new ReplayRpcClient(serverName); }); return(new SeederClient(serverName, serverVersion, databaseName, sourceName, rpcClient)); }
// Token: 0x06001A3D RID: 6717 RVA: 0x0006E555 File Offset: 0x0006C755 private SeederClient(string serverName, ServerVersion serverVersion, string databaseName, string sourceName, ReplayRpcClient client) { this.m_disposeTracker = this.GetDisposeTracker(); this.m_serverName = serverName; this.m_serverVersion = serverVersion; this.m_databaseName = databaseName; this.m_sourceName = sourceName; this.m_client = client; }