Skip to content

Commit f9d559f

Browse files
Even higher timeout for replication for CouchDB 3.4
1 parent f290bc7 commit f9d559f

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

couchdb/src/test/java/me/retrodaredevil/couchdbjava/integration/test/ReplicatorTest.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,10 +65,11 @@ void test(DatabaseService databaseService) throws CouchDbException, JsonProcessi
6565
}
6666

6767

68+
// TODO We should probably try and change a configuration value in CouchDB to convince this to execute faster
6869
// NOTE: For CouchDB 3.3 and lower, we were able to get away with a timeout of about 7.5 seconds
6970
// For CouchDB 3.4 we need about a 10-second timeout.
7071
// I've increased that timeout to 20 seconds, as it seems integration tests will sometimes fail even with a 10 second timeout
71-
for (int i = 0; i < 40 && !target.exists(); i++) { // 40 iterations is ~20 seconds maximum
72+
for (int i = 0; i < 120 && !target.exists(); i++) { // 120 iterations is ~60 seconds maximum
7273
//noinspection BusyWait
7374
Thread.sleep(500);
7475
}

0 commit comments

Comments
 (0)