Package com.netflix.astyanax.connectionpool.exceptions

Examples of com.netflix.astyanax.connectionpool.exceptions.NoAvailableHostsException


        super(config, monitor);

        this.pools = Lists.newArrayList(pools);

        if (this.pools == null || this.pools.isEmpty()) {
            throw new NoAvailableHostsException("No hosts to borrow from");
        }

        int size = this.pools.size();
        retryCountdown = Math.min(config.getMaxFailoverCount(), size);
        if (retryCountdown < 0)
View Full Code Here


        this.index = index;
        this.pools = pools;

        if (pools == null || pools.isEmpty()) {
            throw new NoAvailableHostsException("No hosts to borrow from");
        }
       
        size = pools.size();
        retryCountdown = Math.min(config.getMaxFailoverCount(), size);
        if (retryCountdown < 0)
View Full Code Here

            boolean isSorted = false;
   
            if (op.getPinnedHost() != null) {
                HostConnectionPool<CL> pool = hosts.get(op.getPinnedHost());
                if (pool == null) {
                    throw new NoAvailableHostsException("Host " + op.getPinnedHost() + " not active");
                }
                pools = Arrays.<HostConnectionPool<CL>> asList(pool);
            }
            else {
                TokenHostConnectionPoolPartition<CL> partition = topology.getPartition(op.getRowKey());
View Full Code Here

                        }
                        catch (ConnectionException connectionException) {
                            // Ignore
                        }
                    }
                    throw new NoAvailableHostsException("Too many errors trying to open a connection");
                }
                else {
                    throw new NoAvailableHostsException("No hosts to borrow from");
                }
            }
            finally {
                if (connection == null)
                    activeConnectionCount.decrementAndGet();
View Full Code Here

TOP

Related Classes of com.netflix.astyanax.connectionpool.exceptions.NoAvailableHostsException

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.