Package com.netflix.astyanax.retry

Examples of com.netflix.astyanax.retry.RetryNTimes


                .setDiscoveryType(NodeDiscoveryType.NONE)
                .setConnectionPoolType(ConnectionPoolType.ROUND_ROBIN);

        int numRetries = config.getIntegerProperty(CoreConfig.CASSANDRA_MAX_RETRIES);
        if (numRetries > 0) {
            astyconfig.setRetryPolicy(new RetryNTimes(numRetries));
        }

        return astyconfig;
    }
View Full Code Here


    private static AstyanaxContext<Keyspace> connect(String host, int port, String keyspace, int threads, NodeDiscoveryType discovery) {
        AstyanaxContext<Keyspace> context = new AstyanaxContext.Builder()
                        .forKeyspace(keyspace)
                .withAstyanaxConfiguration(new AstyanaxConfigurationImpl()
                    .setDiscoveryType(discovery)
                    .setRetryPolicy(new RetryNTimes(10)))
                   
                .withConnectionPoolConfiguration(new ConnectionPoolConfigurationImpl(host + ":" + keyspace)
                        .setMaxConns(threads * 2)
                        .setSeeds(host)
                        .setPort(port)
View Full Code Here

TOP

Related Classes of com.netflix.astyanax.retry.RetryNTimes

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.