Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ class ZKConnectionRegistry implements ConnectionRegistry {
private final Configuration conf;
private final int zkRegistryAsyncTimeout;
public static final String ZK_REGISTRY_ASYNC_GET_TIMEOUT = "zookeeper.registry.async.get.timeout";
public static final int DEFAULT_ZK_REGISTRY_ASYNC_GET_TIMEOUT = 60000; // 1 min
public static final int DEFAULT_ZK_REGISTRY_ASYNC_GET_TIMEOUT = 10000; // 10 sec

// User not used, but for rpc based registry we need it
ZKConnectionRegistry(Configuration conf, User ignored) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -217,9 +217,9 @@ public void testNotCloseZkWhenPending() throws Exception {

@Test
public void testReadWithTimeout() throws Exception {
assertArrayEquals(DATA, RO_ZK.get(PATH, 60000).get());
assertEquals(CHILDREN, RO_ZK.exists(PATH, 60000).get().getNumChildren());
List<String> children = RO_ZK.list(PATH, 60000).get();
assertArrayEquals(DATA, RO_ZK.get(PATH, 10000).get());
assertEquals(CHILDREN, RO_ZK.exists(PATH, 10000).get().getNumChildren());
List<String> children = RO_ZK.list(PATH, 10000).get();
assertEquals(CHILDREN, children.size());
Collections.sort(children);
for (int i = 0; i < CHILDREN; i++) {
Expand Down