Skip to content
Permalink
Browse files
Merge pull request #1421 from daniel-beck/JENKINS-24914
[FIXED JENKINS-24914] Don't block indefinitely every other month
  • Loading branch information
oleg-nenashev committed Oct 10, 2014
2 parents 657d715 + adf8305 commit d045618e0a009cae321f6b048a7507ec0b3b8eac
Showing with 3 additions and 2 deletions.
  1. +3 −2 core/src/main/java/jenkins/model/Jenkins.java
@@ -2949,9 +2949,10 @@ public HttpRedirect doQuietDown(
isQuietingDown = true;
}
if (block) {
if (timeout > 0) timeout += System.currentTimeMillis();
long waitUntil = timeout;
if (timeout > 0) waitUntil += System.currentTimeMillis();
while (isQuietingDown
&& (timeout <= 0 || System.currentTimeMillis() < timeout)
&& (timeout <= 0 || System.currentTimeMillis() < waitUntil)
&& !RestartListener.isAllReady()) {
Thread.sleep(1000);
}

0 comments on commit d045618

Please sign in to comment.