TisonKun commented on a change in pull request #338: [CURATOR-549] Prep for
Persistent Watchers by moving to ZK 3.6.0
URL: https://github.com/apache/curator/pull/338#discussion_r392640840
##########
File path:
curator-test/src/main/java/org/apache/curator/test/BaseClassForTests.java
##########
@@ -123,7 +123,16 @@ public void setup() throws Exception
System.setProperty(INTERNAL_PROPERTY_REMOVE_WATCHERS_IN_FOREGROUND,
"true");
System.setProperty(INTERNAL_PROPERTY_VALIDATE_NAMESPACE_WATCHER_MAP_EMPTY,
"true");
- createServer();
+ try
+ {
+ createServer();
+ }
+ catch ( FailedServerStartException ignore )
+ {
+ log.warn("Failed to start server - retrying");
+ closeServer();
+ createServer();
Review comment:
Nice to document that we try exactly one more time for a best effort flaky
test auto-recovery. It is confused at the first glance(why retry exactly once)
and over-engineering if we set the retry time as a field or even configurable.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services