private static void HandleConnectionStrategy(this ConnectionStrategyConfig connectionStrategyConfig, XmlNode node) { connectionStrategyConfig.AsyncStart = Convert.ToBoolean(GetAttribute(node, "async-start").Trim()); var attrValue = GetAttribute(node, "reconnect-mode"); if (attrValue != null) { connectionStrategyConfig.ReconnectMode = (ReconnectMode)Enum.Parse(typeof(ReconnectMode), attrValue.Trim(), true); } foreach (XmlNode child in node.ChildNodes) { var nodeName = CleanNodeName(child); if ("connection-retry".Equals(nodeName)) { connectionStrategyConfig.ConnectionRetryConfig.HandleConnectionRetry(child); } } }
public ClientConfig SetConnectionStrategyConfig(ConnectionStrategyConfig connectionStrategyConfig) { IsNotNull(connectionStrategyConfig, "connectionStrategyConfig"); _connectionStrategyConfig = connectionStrategyConfig; return(this); }