}
if (jobRecord.isIgnoreException()) {
return;
}
UpdateSpec updateSpec = new UpdateSpec(jobRecord.getRootJobKey());
ExceptionRecord exceptionRecord = new ExceptionRecord(
jobRecord.getRootJobKey(), jobRecord.getKey(), currentRunGUID, caughtException);
updateSpec.getNonTransactionalGroup().includeException(exceptionRecord);
Key exceptionKey = exceptionRecord.getKey();
jobRecord.setExceptionKey(exceptionKey);
if (jobRecord.isCallExceptionHandler() || attemptNumber >= maxAttempts) {
jobRecord.setState(State.STOPPED);
updateSpec.getNonTransactionalGroup().includeJob(jobRecord);
if (jobRecord.isExceptionHandlerSpecified()) {