diff --git a/jastadd-mquat-solver-ilp/src/main/java/de/tudresden/inf/st/mquat/solving/ilp/ILPExternalSolver.java b/jastadd-mquat-solver-ilp/src/main/java/de/tudresden/inf/st/mquat/solving/ilp/ILPExternalSolver.java index 851e0789566b49a2ef87768363058717cac5e2d3..35c5ec928a12d2768a25c8508b9e05e94cc1977a 100644 --- a/jastadd-mquat-solver-ilp/src/main/java/de/tudresden/inf/st/mquat/solving/ilp/ILPExternalSolver.java +++ b/jastadd-mquat-solver-ilp/src/main/java/de/tudresden/inf/st/mquat/solving/ilp/ILPExternalSolver.java @@ -110,12 +110,15 @@ public class ILPExternalSolver extends AbstractILPSolver { cleanup(watch); throw new SolvingException("Interrupted while waiting for result", e); } + StopWatch writerWatch = StopWatch.start(); if (!finishedInTime) { // solver already had a timeout, so wait some seconds longer to let it write a solution file this.timedOut = true; try { - process.waitFor(10, TimeUnit.SECONDS); + logger.debug("Solver had a timeout, waiting ten seconds to let it write the result."); + process.waitFor(60, TimeUnit.SECONDS); } catch (InterruptedException ignored) { } + logger.debug("Solver took {} seconds to write the result.", writerWatch.time(TimeUnit.SECONDS)); // then destroy the process process.destroyForcibly(); if (!solutionReadable.toAbsolutePath().toFile().exists()) {