Commit fecaec93 authored by Costin Grigoras's avatar Costin Grigoras
Browse files

log a line in case sitesonar doesn't finish in time

parent 81fb0a04
...@@ -20,7 +20,7 @@ public class JobRunner extends JobAgent { ...@@ -20,7 +20,7 @@ public class JobRunner extends JobAgent {
/** /**
* logger object * logger object
*/ */
final Logger logger = ConfigUtils.getLogger(JobRunner.class.getCanonicalName()); private static final Logger logger = ConfigUtils.getLogger(JobRunner.class.getCanonicalName());
/** /**
* ML monitor object * ML monitor object
...@@ -115,6 +115,9 @@ public class JobRunner extends JobAgent { ...@@ -115,6 +115,9 @@ public class JobRunner extends JobAgent {
if (p != null) { if (p != null) {
final ProcessWithTimeout ptimeout = new ProcessWithTimeout(p, pBuilder); final ProcessWithTimeout ptimeout = new ProcessWithTimeout(p, pBuilder);
ptimeout.waitFor(5, TimeUnit.MINUTES); ptimeout.waitFor(5, TimeUnit.MINUTES);
if (!ptimeout.exitedOk())
logger.log(Level.WARNING, "Sitesonar didn't finish in due time");
} }
} }
catch (@SuppressWarnings("unused") final IOException | InterruptedException e) { catch (@SuppressWarnings("unused") final IOException | InterruptedException e) {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment