no sync in ping and event

This commit is contained in:
anhefti 2023-06-01 14:43:54 +02:00
parent 45e01dc0dd
commit 5dc85f9e73
2 changed files with 12 additions and 12 deletions

View file

@ -161,10 +161,10 @@ public class SEBClientEventBatchService {
} }
ClientConnectionDataInternal clientConnection = null; ClientConnectionDataInternal clientConnection = null;
synchronized (ExamSessionCacheService.CLIENT_CONNECTION_CREATION_LOCK) { //synchronized (ExamSessionCacheService.CLIENT_CONNECTION_CREATION_LOCK) {
clientConnection = this.examSessionCacheService clientConnection = this.examSessionCacheService
.getClientConnection(eventData.connectionToken); .getClientConnection(eventData.connectionToken);
} //}
if (clientConnection == null) { if (clientConnection == null) {
log.error("Failed to get ClientConnectionDataInternal for: {}", eventData.connectionToken); log.error("Failed to get ClientConnectionDataInternal for: {}", eventData.connectionToken);
@ -208,10 +208,10 @@ public class SEBClientEventBatchService {
try { try {
ClientConnectionDataInternal clientConnection = null; ClientConnectionDataInternal clientConnection = null;
synchronized (ExamSessionCacheService.CLIENT_CONNECTION_CREATION_LOCK) { //synchronized (ExamSessionCacheService.CLIENT_CONNECTION_CREATION_LOCK) {
clientConnection = this.examSessionCacheService clientConnection = this.examSessionCacheService
.getClientConnection(eventData.connectionToken); .getClientConnection(eventData.connectionToken);
} //}
if (clientConnection == null) { if (clientConnection == null) {
log.warn("Failed to retrieve ClientConnection for token {}. Skip this event", log.warn("Failed to retrieve ClientConnection for token {}. Skip this event",

View file

@ -92,10 +92,10 @@ public class SEBClientPingBatchService {
} }
ClientConnectionDataInternal activeClientConnection = null; ClientConnectionDataInternal activeClientConnection = null;
synchronized (ExamSessionCacheService.CLIENT_CONNECTION_CREATION_LOCK) { //synchronized (ExamSessionCacheService.CLIENT_CONNECTION_CREATION_LOCK) {
activeClientConnection = this.examSessionCacheService activeClientConnection = this.examSessionCacheService
.getClientConnection(connectionToken); .getClientConnection(connectionToken);
} //}
if (activeClientConnection != null) { if (activeClientConnection != null) {
activeClientConnection.notifyPing(timestamp); activeClientConnection.notifyPing(timestamp);