mirror of https://github.com/OpenVidu/openvidu.git
disable locking for empty session deletion
parent
9baff15b65
commit
b779717d5f
|
@ -264,29 +264,29 @@ public class KurentoSessionManager extends SessionManager {
|
||||||
this.openviduConfig.getOpenviduRecordingAutostopTimeout(), sessionId);
|
this.openviduConfig.getOpenviduRecordingAutostopTimeout(), sessionId);
|
||||||
recordingManager.initAutomaticRecordingStopThread(session);
|
recordingManager.initAutomaticRecordingStopThread(session);
|
||||||
} else {
|
} else {
|
||||||
try {
|
// try {
|
||||||
if (session.closingLock.writeLock().tryLock(15, TimeUnit.SECONDS)) {
|
// if (session.closingLock.writeLock().tryLock(15, TimeUnit.SECONDS)) {
|
||||||
try {
|
// try {
|
||||||
if (session.isClosed()) {
|
// if (session.isClosed()) {
|
||||||
return false;
|
// return false;
|
||||||
}
|
// }
|
||||||
// log.info("No more participants in session '{}', removing it and closing it",
|
// log.info("No more participants in session '{}', removing it and closing it",
|
||||||
// sessionId);
|
// sessionId);
|
||||||
// this.closeSessionAndEmptyCollections(session, reason, true);
|
// this.closeSessionAndEmptyCollections(session, reason, true);
|
||||||
// sessionClosedByLastParticipant = true;
|
// sessionClosedByLastParticipant = true;
|
||||||
} finally {
|
// } finally {
|
||||||
session.closingLock.writeLock().unlock();
|
// session.closingLock.writeLock().unlock();
|
||||||
}
|
// }
|
||||||
} else {
|
// } else {
|
||||||
log.error(
|
// log.error(
|
||||||
"Timeout waiting for Session {} closing lock to be available for closing as last participant left",
|
// "Timeout waiting for Session {} closing lock to be available for closing as last participant left",
|
||||||
sessionId);
|
// sessionId);
|
||||||
}
|
// }
|
||||||
} catch (InterruptedException e) {
|
// } catch (InterruptedException e) {
|
||||||
log.error(
|
// log.error(
|
||||||
"InterruptedException while waiting for Session {} closing lock to be available for closing as last participant left",
|
// "InterruptedException while waiting for Session {} closing lock to be available for closing as last participant left",
|
||||||
sessionId);
|
// sessionId);
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
} else if (remainingParticipants.size() == 1 && openviduConfig.isRecordingModuleEnabled()
|
} else if (remainingParticipants.size() == 1 && openviduConfig.isRecordingModuleEnabled()
|
||||||
&& MediaMode.ROUTED.equals(session.getSessionProperties().mediaMode())
|
&& MediaMode.ROUTED.equals(session.getSessionProperties().mediaMode())
|
||||||
|
|
Loading…
Reference in New Issue