TSK-608: removed exception hiding in JobRunner.

This commit is contained in:
Holger Hagen 2018-06-27 08:54:37 +02:00 committed by Martin Rojas Miguel Angel
parent 98d012d592
commit 5ef8fe2ba0
1 changed files with 4 additions and 1 deletions

View File

@ -119,6 +119,7 @@ public class JobRunner {
}
} catch (Exception e) {
// transaction was rolled back -> split job into 2 half sized jobs
LOGGER.warn("Processing of job " + job.getJobId() + " failed. Trying to split it up into two pieces...", e);
if (job.getRetryCount() < maxRetryCount) {
rescheduleBisectedJob(bulkLog, job);
} else {
@ -304,7 +305,9 @@ public class JobRunner {
executor = (SingleJobExecutor) Class.forName(job.getExecutor()).newInstance();
} catch (InstantiationException | IllegalAccessException | ClassNotFoundException e) {
LOGGER.error("When attempting to load class {} caught Exception {} ", job.getExecutor(), e);
throw new SystemException("When attempting to load class " + job.getExecutor() + " caught Exception " + e);
throw new SystemException(
"When attempting to load class " + job.getExecutor() + " caught Exception " + e.getMessage(),
e);
}
bulkLog = executor.runSingleJob(job, taskanaEngine);