Github user neykov commented on a diff in the pull request:

    https://github.com/apache/brooklyn-server/pull/560#discussion_r103718993
  
    --- Diff: 
launcher/src/main/java/org/apache/brooklyn/launcher/BrooklynWebServer.java ---
    @@ -447,7 +450,14 @@ public synchronized void start() throws Exception {
             rootContext.setTempDirectory(Os.mkdirs(new File(webappTempDir, 
"war-root")));
     
             server.setHandler(handlers);
    -        server.start();
    +        try {
    +            server.start();
    +        } catch (BindException e) {
    +            // retry once just in case it was some fluke or race
    +            log.warn("Initial server start-up failed binding (retrying 
after a delay): "+e);
    +            Time.sleep(Duration.millis(500));
    +            server.start();
    +        }
    --- End diff --
    
    Wdyt about catching the second `BindException` in the test that used to 
fail (in case the backoff is not good enough) and dump some [troubleshooting 
details](https://github.com/apache/incubator-brooklyn/pull/657/files#diff-2219dcab34c5379452f6ac98854d8dd0R88)?
    
    Seems the problem is rare and it's hard to get to the root cause just by 
re-running jobs on the slaves.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to