use of org.apache.geode.cache.client.NoAvailableLocatorsException in project geode by apache.
the class AutoConnectionSourceImpl method findServer.
public ServerLocation findServer(Set excludedServers) {
if (PoolImpl.TEST_DURABLE_IS_NET_DOWN) {
return null;
}
ClientConnectionRequest request = new ClientConnectionRequest(excludedServers, serverGroup);
ClientConnectionResponse response = (ClientConnectionResponse) queryLocators(request);
if (response == null) {
// getLogger().warning("Unable to connect to any locators in the list " + locators);
throw new NoAvailableLocatorsException("Unable to connect to any locators in the list " + locators);
}
return response.getServer();
}
use of org.apache.geode.cache.client.NoAvailableLocatorsException in project geode by apache.
the class AutoConnectionSourceImpl method findReplacementServer.
public ServerLocation findReplacementServer(ServerLocation currentServer, Set excludedServers) {
if (PoolImpl.TEST_DURABLE_IS_NET_DOWN) {
return null;
}
ClientReplacementRequest request = new ClientReplacementRequest(currentServer, excludedServers, serverGroup);
ClientConnectionResponse response = (ClientConnectionResponse) queryLocators(request);
if (response == null) {
// getLogger().warning("Unable to connect to any locators in the list " + locators);
throw new NoAvailableLocatorsException("Unable to connect to any locators in the list " + locators);
}
return response.getServer();
}
use of org.apache.geode.cache.client.NoAvailableLocatorsException in project geode by apache.
the class AutoConnectionSourceImpl method findServersForQueue.
public List findServersForQueue(Set excludedServers, int numServers, ClientProxyMembershipID proxyId, boolean findDurableQueue) {
if (PoolImpl.TEST_DURABLE_IS_NET_DOWN) {
return new ArrayList();
}
QueueConnectionRequest request = new QueueConnectionRequest(proxyId, numServers, excludedServers, serverGroup, findDurableQueue);
QueueConnectionResponse response = (QueueConnectionResponse) queryLocators(request);
if (response == null) {
throw new NoAvailableLocatorsException("Unable to connect to any locators in the list " + locators);
}
List result = response.getServers();
return result;
}
Aggregations