private static void connectionStrategy(XmlGenerator gen, ClientConnectionStrategyConfig connectionStrategy) {
        ConnectionRetryConfig connectionRetry = connectionStrategy.getConnectionRetryConfig();
        gen.open("connection-strategy", "async-start", connectionStrategy.isAsyncStart(),
                "reconnect-mode", connectionStrategy.getReconnectMode());
        gen.open("connection-retry")
                .node("initial-backoff-millis", connectionRetry.getInitialBackoffMillis())
                .node("max-backoff-millis", connectionRetry.getMaxBackoffMillis())
                .node("multiplier", connectionRetry.getMultiplier())
                .node("cluster-connect-timeout-millis", connectionRetry.getClusterConnectTimeoutMillis())
                .node("jitter", connectionRetry.getJitter())
                .close();

        // close connection-strategy
        gen.close();
    }
@Test
    public void connectionStrategy() {
        ClientConnectionStrategyConfig expected = new ClientConnectionStrategyConfig();
        expected.setAsyncStart(true)
                .setReconnectMode(ASYNC)
                .setConnectionRetryConfig(new ConnectionRetryConfig()
                        .setInitialBackoffMillis(1000)
                        .setMaxBackoffMillis(30000)
                        .setMultiplier(2.0)
                        .setClusterConnectTimeoutMillis(5)
                        .setJitter(0.2));
        clientConfig.setConnectionStrategyConfig(expected);

        ClientConnectionStrategyConfig actual = newConfigViaGenerator().getConnectionStrategyConfig();
        assertEquals(expected.isAsyncStart(), actual.isAsyncStart());
        assertEquals(expected.getReconnectMode(), actual.getReconnectMode());
        assertEquals(expected.getConnectionRetryConfig(), actual.getConnectionRetryConfig());
    }