diff --git a/akka-bbb-apps/src/main/scala/org/bigbluebutton/core/domain/MeetingInactivityTracker.scala b/akka-bbb-apps/src/main/scala/org/bigbluebutton/core/domain/MeetingInactivityTracker.scala index e488e2554f..1d687303be 100755 --- a/akka-bbb-apps/src/main/scala/org/bigbluebutton/core/domain/MeetingInactivityTracker.scala +++ b/akka-bbb-apps/src/main/scala/org/bigbluebutton/core/domain/MeetingInactivityTracker.scala @@ -37,6 +37,7 @@ case class MeetingInactivityTracker( case class MeetingExpiryTracker( startedOnInMs: Long, userHasJoined: Boolean, + isBreakout: Boolean, lastUserLeftOnInMs: Option[Long], durationInMs: Long, meetingExpireIfNoUserJoinedInMs: Long, @@ -65,11 +66,11 @@ case class MeetingExpiryTracker( } def hasMeetingExpired(timestampInMs: Long): (Boolean, Option[String]) = { - if (hasMeetingExpiredNeverBeenJoined(timestampInMs)) { + if (hasMeetingExpiredNeverBeenJoined(timestampInMs) && !isBreakout) { (true, Some(MeetingEndReason.ENDED_WHEN_NOT_JOINED)) } else if (meetingOverDuration(timestampInMs)) { (true, Some(MeetingEndReason.ENDED_AFTER_EXCEEDING_DURATION)) - } else if (hasMeetingExpiredAfterLastUserLeft(timestampInMs)) { + } else if (hasMeetingExpiredAfterLastUserLeft(timestampInMs) && !isBreakout) { (true, Some(MeetingEndReason.ENDED_WHEN_LAST_USER_LEFT)) } else { (false, None) diff --git a/akka-bbb-apps/src/main/scala/org/bigbluebutton/core/running/MeetingActor.scala b/akka-bbb-apps/src/main/scala/org/bigbluebutton/core/running/MeetingActor.scala index b081cd31f6..1381ea82bf 100755 --- a/akka-bbb-apps/src/main/scala/org/bigbluebutton/core/running/MeetingActor.scala +++ b/akka-bbb-apps/src/main/scala/org/bigbluebutton/core/running/MeetingActor.scala @@ -121,6 +121,7 @@ class MeetingActor( val expiryTracker = new MeetingExpiryTracker( startedOnInMs = TimeUtil.timeNowInMs(), userHasJoined = false, + isBreakout = props.meetingProp.isBreakout, lastUserLeftOnInMs = None, durationInMs = TimeUtil.minutesToMillis(props.durationProps.duration), meetingExpireIfNoUserJoinedInMs = TimeUtil.minutesToMillis(props.durationProps.meetingExpireIfNoUserJoinedInMinutes), diff --git a/akka-bbb-apps/src/test/scala/org/bigbluebutton/core2/message/handlers/ValidateAuthTokenReqMsgHdlrTestsSpec.scala b/akka-bbb-apps/src/test/scala/org/bigbluebutton/core2/message/handlers/ValidateAuthTokenReqMsgHdlrTestsSpec.scala index 36c9bceddb..87c1549127 100755 --- a/akka-bbb-apps/src/test/scala/org/bigbluebutton/core2/message/handlers/ValidateAuthTokenReqMsgHdlrTestsSpec.scala +++ b/akka-bbb-apps/src/test/scala/org/bigbluebutton/core2/message/handlers/ValidateAuthTokenReqMsgHdlrTestsSpec.scala @@ -42,6 +42,7 @@ class ValidateAuthTokenReqMsgHdlrTestsSpec extends TestKit(ActorSystem( val expiryTracker = new MeetingExpiryTracker( startedOnInMs = TimeUtil.timeNowInSeconds(), userHasJoined = false, + isBreakout = false, lastUserLeftOnInMs = None, durationInMs = 120, meetingExpireIfNoUserJoinedInMs = 5,