Skip to content

Commit

Permalink
IGNITE-8650 Fix flaky ZookeeperDiscovery testClientReconnect. - Fixes a…
Browse files Browse the repository at this point in the history
…pache#4704.

Signed-off-by: Dmitriy Govorukhin <dmitriy.govorukhin@gmail.com>
  • Loading branch information
avplatonov authored and DaveWHarvey committed Sep 12, 2018
1 parent 19db096 commit b49b8b9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1203,7 +1203,7 @@ private void reconnectMultinode(boolean longHist) throws Exception {

ClusterGroup grp = client.cluster().forCacheNodes(DEFAULT_CACHE_NAME);

assertEquals(CLIENTS + srvNodes, grp.nodes().size());
assertEquals(expNodes, grp.nodes().size());

grp = client.cluster().forClientNodes(DEFAULT_CACHE_NAME);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1334,7 +1334,9 @@ private void checkClientsStatus(final List<String> aliveNodes) throws Exception
}
}

assert !aliveClients.isEmpty();
// This situation may appear while reconnection and this callback can be skipped.
if(!aliveClients.containsKey(locInternalOrder))
return;

Map.Entry<Long, String> oldest = aliveClients.firstEntry();

Expand Down

0 comments on commit b49b8b9

Please sign in to comment.