diff --git a/src/main/java/ch/ethz/seb/sebserver/webservice/servicelayer/session/impl/ExamJITSIProctoringService.java b/src/main/java/ch/ethz/seb/sebserver/webservice/servicelayer/session/impl/ExamJITSIProctoringService.java index 63b21282..1d1fae40 100644 --- a/src/main/java/ch/ethz/seb/sebserver/webservice/servicelayer/session/impl/ExamJITSIProctoringService.java +++ b/src/main/java/ch/ethz/seb/sebserver/webservice/servicelayer/session/impl/ExamJITSIProctoringService.java @@ -321,7 +321,8 @@ public class ExamJITSIProctoringService implements ExamProctoringService { long expTime = System.currentTimeMillis() + Constants.DAY_IN_MILLIS; if (this.examSessionService.isExamRunning(examProctoring.examId)) { - final Exam exam = this.examSessionService.getRunningExam(examProctoring.examId) + final Exam exam = this.examSessionService + .getRunningExam(examProctoring.examId) .getOrThrow(); if (exam.endTime != null) { expTime = exam.endTime.getMillis(); diff --git a/src/main/java/ch/ethz/seb/sebserver/webservice/servicelayer/session/impl/ExamSessionServiceImpl.java b/src/main/java/ch/ethz/seb/sebserver/webservice/servicelayer/session/impl/ExamSessionServiceImpl.java index abe8d6b1..ba1f822b 100644 --- a/src/main/java/ch/ethz/seb/sebserver/webservice/servicelayer/session/impl/ExamSessionServiceImpl.java +++ b/src/main/java/ch/ethz/seb/sebserver/webservice/servicelayer/session/impl/ExamSessionServiceImpl.java @@ -227,7 +227,10 @@ public class ExamSessionServiceImpl implements ExamSessionService { log.trace("Running exam request for exam {}", examId); } - updateExamCache(examId); + if (this.distributedSetup) { + updateExamCache(examId); + } + final Exam exam = this.examSessionCacheService.getRunningExam(examId); if (this.examSessionCacheService.isRunning(exam)) {