Skip to content
Snippets Groups Projects
Commit f8d8079f authored by Richard Alam's avatar Richard Alam
Browse files

- make sure to record the EndAndKickAllEvent

parent 460dfb52
No related branches found
No related tags found
No related merge requests found
......@@ -42,12 +42,12 @@ public class RecorderApplication {
private BlockingQueue<RecordEvent> messages;
private volatile boolean recordEvents = false;
private final Map<String, String> recordingSessions;
// private final Map<String, String> recordingSessions;
private Recorder recorder;
public RecorderApplication() {
messages = new LinkedBlockingQueue<RecordEvent>();
recordingSessions = new ConcurrentHashMap<String, String>();
// recordingSessions = new ConcurrentHashMap<String, String>();
}
public void start() {
......@@ -75,25 +75,25 @@ public class RecorderApplication {
}
public void destroyRecordSession(String meetingID) {
recordingSessions.remove(meetingID);
// recordingSessions.remove(meetingID);
}
public void createRecordSession(String meetingID) {
recordingSessions.put(meetingID, meetingID);
// recordingSessions.put(meetingID, meetingID);
}
public void record(String meetingID, RecordEvent message) {
messages.offer(message);
if (recordingSessions.containsKey(meetingID)) {
// if (recordingSessions.containsKey(meetingID)) {
recorder.record(meetingID, message);
}
// }
}
private void recordEvent(RecordEvent message) {
if (recordingSessions.containsKey(message.getMeetingID())) {
// if (recordingSessions.containsKey(message.getMeetingID())) {
recorder.record(message.getMeetingID(), message);
}
// }
}
public void setRecorder(Recorder recorder) {
......
......@@ -46,7 +46,10 @@ class BigBlueButtonActor(outGW: MessageOutGateway) extends Actor {
case None => println("Could not find meeting id[" + msg.meetingID + "] to destroy.")
case Some(m) => {
m ! StopMeetingActor
meetings -= msg.meetingID
meetings -= msg.meetingID
println("Kinc everyone out on meeting id[" + msg.meetingID + "].")
outGW.send(new EndAndKickAll(msg.meetingID, m.recorded))
println("Destroyed meeting id[" + msg.meetingID + "].")
outGW.send(new MeetingDestroyed(msg.meetingID))
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment