- fix compile issues
This commit is contained in:
parent
76a6d99ca3
commit
0d53d2bf93
@ -2,7 +2,7 @@ package org.bigbluebutton.messages;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
class CreateMeetingRequestPayload {
|
||||
public class CreateMeetingRequestPayload {
|
||||
public final String id;
|
||||
public final String externalId;
|
||||
public final String parentId;
|
||||
|
@ -4,7 +4,7 @@ organization := "org.bigbluebutton"
|
||||
|
||||
version := "0.0.1-SNAPSHOT"
|
||||
|
||||
scalaVersion := "2.11.7"
|
||||
scalaVersion := "2.12.2"
|
||||
|
||||
scalacOptions ++= Seq(
|
||||
"-unchecked",
|
||||
@ -25,12 +25,14 @@ testOptions in Test += Tests.Argument(TestFrameworks.Specs2, "html", "console",
|
||||
|
||||
testOptions in Test += Tests.Argument(TestFrameworks.ScalaTest, "-h", "target/scalatest-reports")
|
||||
|
||||
val scalaV = "2.11.7"
|
||||
val scalaV = "2.12.2"
|
||||
|
||||
libraryDependencies += "org.scala-lang" % "scala-compiler" % scalaV
|
||||
libraryDependencies += "org.scala-lang" % "scala-library" % scalaV
|
||||
libraryDependencies += "org.scala-lang" % "scala-reflect" % scalaV
|
||||
|
||||
libraryDependencies += "org.bigbluebutton" % "bbb-common-message_2.12" % "0.0.19-SNAPSHOT"
|
||||
|
||||
libraryDependencies += "redis.clients" % "jedis" % "2.7.2"
|
||||
libraryDependencies += "com.google.code.gson" % "gson" % "2.5"
|
||||
|
||||
@ -48,7 +50,7 @@ libraryDependencies += "org.openoffice" % "juh" % "3.2.1"
|
||||
libraryDependencies += "org.openoffice" % "jurt" % "3.2.1"
|
||||
|
||||
libraryDependencies += "org.apache.poi" % "poi-ooxml" % "3.15"
|
||||
libraryDependencies += "org.bigbluebutton" % "bbb-common-message" % "0.0.19-SNAPSHOT"
|
||||
|
||||
libraryDependencies += "org.slf4j" % "slf4j-api" % "1.7.5"
|
||||
|
||||
// https://mvnrepository.com/artifact/org.apache.httpcomponents/httpclient
|
||||
|
@ -4,6 +4,6 @@ addSbtPlugin("com.typesafe.sbteclipse" % "sbteclipse-plugin" % "2.2.0")
|
||||
|
||||
addSbtPlugin("com.jsuereth" % "sbt-pgp" % "1.0.0")
|
||||
|
||||
addSbtPlugin("com.artima.supersafe" % "sbtplugin" % "1.1.0")
|
||||
addSbtPlugin("com.artima.supersafe" % "sbtplugin" % "1.1.2")
|
||||
|
||||
|
||||
|
@ -60,6 +60,7 @@ import org.bigbluebutton.api.messaging.messages.UserRoleChanged;
|
||||
import org.bigbluebutton.api.messaging.messages.UserSharedWebcam;
|
||||
import org.bigbluebutton.api.messaging.messages.UserStatusChanged;
|
||||
import org.bigbluebutton.api.messaging.messages.UserUnsharedWebcam;
|
||||
import org.bigbluebutton.api.pub.IPublisherService;
|
||||
import org.bigbluebutton.presentation.PresentationUrlDownloadService;
|
||||
import org.bigbluebutton.api.messaging.messages.StunTurnInfoRequested;
|
||||
import org.bigbluebutton.web.services.RegisteredUserCleanupTimerTask;
|
||||
@ -90,6 +91,7 @@ public class MeetingService implements MessageListener {
|
||||
|
||||
private RecordingService recordingService;
|
||||
private MessagingService messagingService;
|
||||
private IPublisherService publisherService;
|
||||
private RegisteredUserCleanupTimerTask registeredUserCleaner;
|
||||
private StunTurnService stunTurnService;
|
||||
|
||||
@ -190,7 +192,7 @@ public class MeetingService implements MessageListener {
|
||||
}
|
||||
|
||||
private void destroyMeeting(String meetingID) {
|
||||
messagingService.destroyMeeting(meetingID);
|
||||
publisherService.destroyMeeting(meetingID);
|
||||
}
|
||||
|
||||
public Collection<Meeting> getMeetings() {
|
||||
@ -262,7 +264,7 @@ public class MeetingService implements MessageListener {
|
||||
|
||||
log.info("Create meeting: data={}", logStr);
|
||||
|
||||
messagingService.createMeeting(m.getInternalId(), m.getExternalId(),
|
||||
publisherService.createMeeting(m.getInternalId(), m.getExternalId(),
|
||||
m.getParentMeetingId(), m.getName(), m.isRecord(),
|
||||
m.getTelVoice(), m.getDuration(), m.getAutoStartRecording(),
|
||||
m.getAllowStartStopRecording(), m.getWebcamsOnlyForModerator(),
|
||||
@ -280,7 +282,7 @@ public class MeetingService implements MessageListener {
|
||||
}
|
||||
|
||||
private void processRegisterUser(RegisterUser message) {
|
||||
messagingService.registerUser(message.meetingID,
|
||||
publisherService.registerUser(message.meetingID,
|
||||
message.internalUserId, message.fullname, message.role,
|
||||
message.externUserID, message.authToken, message.avatarURL, message.guest, message.authed);
|
||||
}
|
||||
@ -459,12 +461,6 @@ public class MeetingService implements MessageListener {
|
||||
messagingService.send(channel, message);
|
||||
}
|
||||
|
||||
public void createdPolls(String meetingId, String title, String question,
|
||||
String questionType, ArrayList<String> answers) {
|
||||
messagingService.sendPolls(meetingId, title, question, questionType,
|
||||
answers);
|
||||
}
|
||||
|
||||
public void endMeeting(String meetingId) {
|
||||
handle(new EndMeeting(meetingId));
|
||||
}
|
||||
@ -516,7 +512,7 @@ public class MeetingService implements MessageListener {
|
||||
}
|
||||
|
||||
private void processEndMeeting(EndMeeting message) {
|
||||
messagingService.endMeeting(message.meetingId);
|
||||
publisherService.endMeeting(message.meetingId);
|
||||
}
|
||||
|
||||
private void processRemoveEndedMeeting(MeetingEnded message) {
|
||||
@ -754,7 +750,7 @@ public class MeetingService implements MessageListener {
|
||||
log.info("a org.bigbluebutton.web.services.turn: " + t.url + "username/pass=" + t.username + '/'
|
||||
+ t.password);
|
||||
}
|
||||
messagingService.sendStunTurnInfo(message.meetingId,
|
||||
publisherService.sendStunTurnInfo(message.meetingId,
|
||||
message.internalUserId, stuns, turns);
|
||||
}
|
||||
|
||||
@ -919,6 +915,10 @@ public class MeetingService implements MessageListener {
|
||||
messagingService = mess;
|
||||
}
|
||||
|
||||
public void setPublisherService(IPublisherService mess) {
|
||||
publisherService = mess;
|
||||
}
|
||||
|
||||
public void setRegisteredUserCleanupTimerTask(
|
||||
RegisteredUserCleanupTimerTask c) {
|
||||
registeredUserCleaner = c;
|
||||
|
@ -63,7 +63,7 @@ public class Meeting {
|
||||
private final Boolean isBreakout;
|
||||
private final List<String> breakoutRooms = new ArrayList();
|
||||
|
||||
public Meeting(Builder builder) {
|
||||
public Meeting(Meeting.Builder builder) {
|
||||
name = builder.name;
|
||||
extMeetingId = builder.externalId;
|
||||
intMeetingId = builder.internalId;
|
||||
|
@ -19,32 +19,14 @@
|
||||
|
||||
package org.bigbluebutton.api.messaging;
|
||||
|
||||
import org.bigbluebutton.web.services.turn.StunServer;
|
||||
import org.bigbluebutton.web.services.turn.TurnEntry;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Set;
|
||||
|
||||
public interface MessagingService {
|
||||
void recordMeetingInfo(String meetingId, Map<String, String> info);
|
||||
void recordBreakoutInfo(String meetingId, Map<String, String> breakoutInfo);
|
||||
void addBreakoutRoom(String parentId, String breakoutId);
|
||||
void destroyMeeting(String meetingID);
|
||||
void createMeeting(String meetingID, String externalMeetingID,
|
||||
String parentMeetingID, String meetingName, Boolean recorded,
|
||||
String voiceBridge, Integer duration, Boolean autoStartRecording,
|
||||
Boolean allowStartStopRecording, Boolean webcamsOnlyForModerator,
|
||||
String moderatorPass, String viewerPass, Long createTime,
|
||||
String createDate, Boolean isBreakout, Integer sequence,
|
||||
Map<String, String> metadata, String guestPolicy);
|
||||
void endMeeting(String meetingId);
|
||||
void send(String channel, String message);
|
||||
void sendPolls(String meetingId, String title, String question, String questionType, List<String> answers);
|
||||
void registerUser(String meetingID, String internalUserId, String fullname, String role, String externUserID,
|
||||
String authToken, String avatarURL, Boolean guest, Boolean authed);
|
||||
void sendKeepAlive(String system, Long timestamp);
|
||||
void sendStunTurnInfo(String meetingId, String internalUserId, Set<StunServer> stuns, Set<TurnEntry> turns);
|
||||
void publishRecording(String recordId, String meetingId, String externalMeetingId, String format, boolean publish);
|
||||
void deleteRecording(String recordId, String meetingId, String externalMeetingId, String format);
|
||||
}
|
||||
|
@ -37,7 +37,8 @@ import org.bigbluebutton.common.messages.Constants;
|
||||
import org.bigbluebutton.common.messages.MessagingConstants;
|
||||
import org.bigbluebutton.common.messages.SendStunTurnInfoReplyMessage;
|
||||
import org.bigbluebutton.messages.CreateMeetingRequest;
|
||||
import org.bigbluebutton.messages.CreateMeetingRequest.CreateMeetingRequestPayload;
|
||||
import org.bigbluebutton.messages.CreateMeetingRequestPayload;
|
||||
import org.bigbluebutton.messages.RegisterUserMessagePayload;
|
||||
import org.bigbluebutton.web.services.turn.StunServer;
|
||||
import org.bigbluebutton.web.services.turn.TurnEntry;
|
||||
import org.slf4j.Logger;
|
||||
@ -73,7 +74,7 @@ public class RedisMessagingService implements MessagingService {
|
||||
|
||||
public void registerUser(String meetingID, String internalUserId, String fullname, String role,
|
||||
String externUserID, String authToken, String avatarURL, Boolean guest, Boolean authed) {
|
||||
RegisterUserMessage.Payload payload = new RegisterUserMessage.Payload(meetingID, internalUserId, fullname, role, externUserID,
|
||||
RegisterUserMessagePayload payload = new RegisterUserMessagePayload(meetingID, internalUserId, fullname, role, externUserID,
|
||||
authToken, avatarURL, guest, authed);
|
||||
RegisterUserMessage msg = new RegisterUserMessage(payload);
|
||||
|
||||
|
@ -0,0 +1,26 @@
|
||||
package org.bigbluebutton.api.pub;
|
||||
|
||||
|
||||
import org.bigbluebutton.web.services.turn.StunServer;
|
||||
import org.bigbluebutton.web.services.turn.TurnEntry;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Set;
|
||||
|
||||
public interface IPublisherService {
|
||||
void destroyMeeting(String meetingID);
|
||||
void createMeeting(String meetingID, String externalMeetingID,
|
||||
String parentMeetingID, String meetingName, Boolean recorded,
|
||||
String voiceBridge, Integer duration, Boolean autoStartRecording,
|
||||
Boolean allowStartStopRecording, Boolean webcamsOnlyForModerator,
|
||||
String moderatorPass, String viewerPass, Long createTime,
|
||||
String createDate, Boolean isBreakout, Integer sequence,
|
||||
Map<String, String> metadata, String guestPolicy);
|
||||
void endMeeting(String meetingId);
|
||||
void send(String channel, String message);
|
||||
void registerUser(String meetingID, String internalUserId, String fullname, String role, String externUserID,
|
||||
String authToken, String avatarURL, Boolean guest, Boolean authed);
|
||||
void sendKeepAlive(String system, Long timestamp);
|
||||
void sendStunTurnInfo(String meetingId, String internalUserId, Set<StunServer> stuns, Set<TurnEntry> turns);
|
||||
}
|
@ -26,7 +26,7 @@ import java.util.Map;
|
||||
public class ConversionUpdateMessage {
|
||||
private Map<String, Object> message = new HashMap<String, Object>();
|
||||
|
||||
private ConversionUpdateMessage(MessageBuilder builder) {
|
||||
private ConversionUpdateMessage(ConversionUpdateMessage.MessageBuilder builder) {
|
||||
message = builder.message;
|
||||
}
|
||||
|
||||
|
@ -25,7 +25,7 @@ public interface PageAnalyser {
|
||||
/**
|
||||
*
|
||||
* @param output
|
||||
* a {@link File} to analyse
|
||||
* a File to analyse
|
||||
* @return true if the file has been parsed without any error
|
||||
*/
|
||||
public boolean analyse(File output);
|
||||
|
@ -28,7 +28,7 @@ public class CountingPageException extends Exception {
|
||||
|
||||
public enum ExceptionType {PAGE_COUNT_EXCEPTION, PAGE_EXCEEDED_EXCEPTION};
|
||||
|
||||
public CountingPageException(ExceptionType type, int pageCount, int maxNumberOfPages) {
|
||||
public CountingPageException(CountingPageException.ExceptionType type, int pageCount, int maxNumberOfPages) {
|
||||
super("Exception while trying to determine number of pages.");
|
||||
this.pageCount = pageCount;
|
||||
this.maxNumberOfPages = maxNumberOfPages;
|
||||
@ -39,7 +39,7 @@ public class CountingPageException extends Exception {
|
||||
return maxNumberOfPages;
|
||||
}
|
||||
|
||||
public ExceptionType getExceptionType() {
|
||||
public CountingPageException.ExceptionType getExceptionType() {
|
||||
return exceptionType;
|
||||
}
|
||||
|
||||
|
@ -30,13 +30,14 @@ import org.bigbluebutton.api.messaging.MessageListener;
|
||||
import org.bigbluebutton.api.messaging.MessagingService;
|
||||
import org.bigbluebutton.api.messaging.messages.IMessage;
|
||||
import org.bigbluebutton.api.messaging.messages.KeepAliveReply;
|
||||
import org.bigbluebutton.api.pub.IPublisherService;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
public class KeepAliveService implements MessageListener {
|
||||
private static Logger log = LoggerFactory.getLogger(KeepAliveService.class);
|
||||
private final String KEEP_ALIVE_REQUEST = "KEEP_ALIVE_REQUEST";
|
||||
private MessagingService service;
|
||||
private IPublisherService service;
|
||||
private long runEvery = 10000;
|
||||
private int maxLives = 5;
|
||||
private KeepAliveTask task = new KeepAliveTask();
|
||||
@ -69,7 +70,7 @@ public class KeepAliveService implements MessageListener {
|
||||
runEvery = v * 1000;
|
||||
}
|
||||
|
||||
public void setMessagingService(MessagingService service){
|
||||
public void setPublisherService(IPublisherService service){
|
||||
this.service = service;
|
||||
}
|
||||
|
||||
|
@ -0,0 +1,41 @@
|
||||
package org.bigbluebutton.api.pub
|
||||
|
||||
import java.util
|
||||
import org.bigbluebutton.web.services.turn.{StunServer, TurnEntry}
|
||||
|
||||
|
||||
class RedisPublisherService extends IPublisherService {
|
||||
def destroyMeeting (meetingId: String):Unit = {
|
||||
|
||||
}
|
||||
|
||||
def createMeeting(meetingId: String, extMeetingId: String, parentMeetingId: String, meetingName: String,
|
||||
recorded: java.lang.Boolean, voiceBridge: String, duration: java.lang.Integer, autoStartRecording: java.lang.Boolean,
|
||||
allowStartStopRecording: java.lang.Boolean, webcamsOnlyForModerator: java.lang.Boolean, moderatorPass: String,
|
||||
viewerPass: String, createTime: java.lang.Long, createDate: String, isBreakout: java.lang.Boolean, sequence: java.lang.Integer,
|
||||
metadata: util.Map[String, String], guestPolicy: String): Unit = {
|
||||
|
||||
}
|
||||
|
||||
def endMeeting(meetingId: String): Unit = {
|
||||
|
||||
}
|
||||
|
||||
def send(channel: String, message: String): Unit = {
|
||||
|
||||
}
|
||||
|
||||
def registerUser(meetingID: String, internalUserId: String, fullname: String, role: String, externUserID: String,
|
||||
authToken: String, avatarURL: String, guest: java.lang.Boolean, authed: java.lang.Boolean): Unit = {
|
||||
|
||||
}
|
||||
|
||||
def sendKeepAlive(system: String, timestamp: java.lang.Long): Unit = {
|
||||
|
||||
}
|
||||
|
||||
def sendStunTurnInfo(meetingId: String, internalUserId: String, stuns: util.Set[StunServer],
|
||||
turns: util.Set[TurnEntry]): Unit = {
|
||||
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user