Massive project restructuring: new 'io.openvidu' groupId

pull/20/head
pabloFuente 2017-06-06 11:52:13 +02:00
parent e9c1a19213
commit 5f9a4399de
136 changed files with 688 additions and 485 deletions

View File

@ -185,8 +185,8 @@ A Java package that wraps the HTTP REST operations for making them even easier
- Maven dependency
```xml
<dependency>
<groupId>org.openvidu</groupId>
<artifactId>openvidu-backend-client</artifactId>
<groupId>io.openvidu</groupId>
<artifactId>openvidu-java-client</artifactId>
<version>...</version>
</dependency>
```
@ -199,7 +199,7 @@ The usage is quite simple: import OpenVidu package and get an **OpenVidu** objec
```java
import org.openvidu.client.OpenVidu;
import io.openvidu.java.client.OpenVidu;
OpenVidu openVidu = new OpenVidu(OPENVIDU_SERVER_IP, YOUR_SECRET);

View File

@ -1,49 +0,0 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.openvidu</groupId>
<artifactId>openvidu</artifactId>
<version>0.0.1-SNAPSHOT</version>
</parent>
<artifactId>openvidu-backend-client</artifactId>
<packaging>jar</packaging>
<name>OpenVidu Java Backend Client</name>
<url>http://maven.apache.org</url>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<java.version>1.8</java.version>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
</properties>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
</dependency>
<dependency>
<groupId>com.googlecode.json-simple</groupId>
<artifactId>json-simple</artifactId>
</dependency>
</dependencies>
</project>

View File

@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.openvidu</groupId>
<groupId>io.openvidu</groupId>
<artifactId>openvidu</artifactId>
<version>0.0.1-SNAPSHOT</version>
</parent>
@ -39,10 +39,10 @@
<developers>
<developer>
<id>openvidu.org</id>
<name>-openvidu.org Community</name>
<organization>OpenVidu.org</organization>
<organizationUrl>https://github.com/OpenVidu/openvidu</organizationUrl>
<id>openvidu.io</id>
<name>-openvidu.io Community</name>
<organization>OpenVidu</organization>
<organizationUrl>http://openvidu.io</organizationUrl>
</developer>
</developers>

View File

@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.openvidu</groupId>
<groupId>io.openvidu</groupId>
<artifactId>openvidu</artifactId>
<version>0.0.1-SNAPSHOT</version>
</parent>
@ -39,10 +39,10 @@
<developers>
<developer>
<id>openvidu.org</id>
<name>-openvidu.org Community</name>
<organization>OpenVidu.org</organization>
<organizationUrl>https://github.com/OpenVidu/openvidu</organizationUrl>
<id>openvidu.io</id>
<name>-openvidu.io Community</name>
<organization>OpenVidu</organization>
<organizationUrl>http://openvidu.io</organizationUrl>
</developer>
</developers>
@ -52,7 +52,7 @@
<artifactId>kurento-jsonrpc-client</artifactId>
</dependency>
<!-- <dependency>
<groupId>org.openvidu</groupId>
<groupId>io.openvidu</groupId>
<artifactId>openvidu-server</artifactId>
</dependency>-->
<dependency>

View File

@ -14,37 +14,37 @@
* limitations under the License.
*/
package org.openvidu.client;
package io.openvidu.client;
import static org.openvidu.client.internal.ProtocolElements.CUSTOMREQUEST_METHOD;
import static org.openvidu.client.internal.ProtocolElements.JOINROOM_DATACHANNELS_PARAM;
import static org.openvidu.client.internal.ProtocolElements.JOINROOM_METHOD;
import static org.openvidu.client.internal.ProtocolElements.JOINROOM_PEERID_PARAM;
import static org.openvidu.client.internal.ProtocolElements.JOINROOM_PEERSTREAMID_PARAM;
import static org.openvidu.client.internal.ProtocolElements.JOINROOM_PEERSTREAMS_PARAM;
import static org.openvidu.client.internal.ProtocolElements.JOINROOM_ROOM_PARAM;
import static org.openvidu.client.internal.ProtocolElements.JOINROOM_USER_PARAM;
import static org.openvidu.client.internal.ProtocolElements.LEAVEROOM_METHOD;
import static org.openvidu.client.internal.ProtocolElements.ONICECANDIDATE_CANDIDATE_PARAM;
import static org.openvidu.client.internal.ProtocolElements.ONICECANDIDATE_EPNAME_PARAM;
import static org.openvidu.client.internal.ProtocolElements.ONICECANDIDATE_METHOD;
import static org.openvidu.client.internal.ProtocolElements.ONICECANDIDATE_SDPMIDPARAM;
import static org.openvidu.client.internal.ProtocolElements.ONICECANDIDATE_SDPMLINEINDEX_PARAM;
import static org.openvidu.client.internal.ProtocolElements.PUBLISHVIDEO_DOLOOPBACK_PARAM;
import static org.openvidu.client.internal.ProtocolElements.PUBLISHVIDEO_METHOD;
import static org.openvidu.client.internal.ProtocolElements.PUBLISHVIDEO_SDPANSWER_PARAM;
import static org.openvidu.client.internal.ProtocolElements.PUBLISHVIDEO_SDPOFFER_PARAM;
import static org.openvidu.client.internal.ProtocolElements.RECEIVEVIDEO_METHOD;
import static org.openvidu.client.internal.ProtocolElements.RECEIVEVIDEO_SDPANSWER_PARAM;
import static org.openvidu.client.internal.ProtocolElements.RECEIVEVIDEO_SDPOFFER_PARAM;
import static org.openvidu.client.internal.ProtocolElements.RECEIVEVIDEO_SENDER_PARAM;
import static org.openvidu.client.internal.ProtocolElements.SENDMESSAGE_MESSAGE_PARAM;
import static org.openvidu.client.internal.ProtocolElements.SENDMESSAGE_ROOM_METHOD;
import static org.openvidu.client.internal.ProtocolElements.SENDMESSAGE_ROOM_PARAM;
import static org.openvidu.client.internal.ProtocolElements.SENDMESSAGE_USER_PARAM;
import static org.openvidu.client.internal.ProtocolElements.UNPUBLISHVIDEO_METHOD;
import static org.openvidu.client.internal.ProtocolElements.UNSUBSCRIBEFROMVIDEO_METHOD;
import static org.openvidu.client.internal.ProtocolElements.UNSUBSCRIBEFROMVIDEO_SENDER_PARAM;
import static io.openvidu.client.internal.ProtocolElements.CUSTOMREQUEST_METHOD;
import static io.openvidu.client.internal.ProtocolElements.JOINROOM_DATACHANNELS_PARAM;
import static io.openvidu.client.internal.ProtocolElements.JOINROOM_METHOD;
import static io.openvidu.client.internal.ProtocolElements.JOINROOM_PEERID_PARAM;
import static io.openvidu.client.internal.ProtocolElements.JOINROOM_PEERSTREAMID_PARAM;
import static io.openvidu.client.internal.ProtocolElements.JOINROOM_PEERSTREAMS_PARAM;
import static io.openvidu.client.internal.ProtocolElements.JOINROOM_ROOM_PARAM;
import static io.openvidu.client.internal.ProtocolElements.JOINROOM_USER_PARAM;
import static io.openvidu.client.internal.ProtocolElements.LEAVEROOM_METHOD;
import static io.openvidu.client.internal.ProtocolElements.ONICECANDIDATE_CANDIDATE_PARAM;
import static io.openvidu.client.internal.ProtocolElements.ONICECANDIDATE_EPNAME_PARAM;
import static io.openvidu.client.internal.ProtocolElements.ONICECANDIDATE_METHOD;
import static io.openvidu.client.internal.ProtocolElements.ONICECANDIDATE_SDPMIDPARAM;
import static io.openvidu.client.internal.ProtocolElements.ONICECANDIDATE_SDPMLINEINDEX_PARAM;
import static io.openvidu.client.internal.ProtocolElements.PUBLISHVIDEO_DOLOOPBACK_PARAM;
import static io.openvidu.client.internal.ProtocolElements.PUBLISHVIDEO_METHOD;
import static io.openvidu.client.internal.ProtocolElements.PUBLISHVIDEO_SDPANSWER_PARAM;
import static io.openvidu.client.internal.ProtocolElements.PUBLISHVIDEO_SDPOFFER_PARAM;
import static io.openvidu.client.internal.ProtocolElements.RECEIVEVIDEO_METHOD;
import static io.openvidu.client.internal.ProtocolElements.RECEIVEVIDEO_SDPANSWER_PARAM;
import static io.openvidu.client.internal.ProtocolElements.RECEIVEVIDEO_SDPOFFER_PARAM;
import static io.openvidu.client.internal.ProtocolElements.RECEIVEVIDEO_SENDER_PARAM;
import static io.openvidu.client.internal.ProtocolElements.SENDMESSAGE_MESSAGE_PARAM;
import static io.openvidu.client.internal.ProtocolElements.SENDMESSAGE_ROOM_METHOD;
import static io.openvidu.client.internal.ProtocolElements.SENDMESSAGE_ROOM_PARAM;
import static io.openvidu.client.internal.ProtocolElements.SENDMESSAGE_USER_PARAM;
import static io.openvidu.client.internal.ProtocolElements.UNPUBLISHVIDEO_METHOD;
import static io.openvidu.client.internal.ProtocolElements.UNSUBSCRIBEFROMVIDEO_METHOD;
import static io.openvidu.client.internal.ProtocolElements.UNSUBSCRIBEFROMVIDEO_SENDER_PARAM;
import java.io.IOException;
import java.util.ArrayList;
@ -57,8 +57,6 @@ import org.eclipse.jetty.util.ssl.SslContextFactory;
import org.kurento.jsonrpc.client.JsonRpcClient;
import org.kurento.jsonrpc.client.JsonRpcClientWebSocket;
import org.kurento.jsonrpc.client.JsonRpcWSConnectionListener;
import org.openvidu.client.internal.JsonRoomUtils;
import org.openvidu.client.internal.Notification;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@ -66,6 +64,9 @@ import com.google.gson.JsonArray;
import com.google.gson.JsonElement;
import com.google.gson.JsonObject;
import io.openvidu.client.internal.JsonRoomUtils;
import io.openvidu.client.internal.Notification;
/**
* Java client for the room server.
*

View File

@ -15,7 +15,7 @@
*
*/
package org.openvidu.client;
package io.openvidu.client;
public class OpenViduException extends RuntimeException {
private static final long serialVersionUID = 1L;

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.client;
package io.openvidu.client;
import java.util.ArrayList;
import java.util.Iterator;
@ -25,19 +25,6 @@ import java.util.concurrent.BlockingQueue;
import org.kurento.jsonrpc.DefaultJsonRpcHandler;
import org.kurento.jsonrpc.Transaction;
import org.kurento.jsonrpc.message.Request;
import org.openvidu.client.internal.IceCandidate;
import org.openvidu.client.internal.IceCandidateInfo;
import org.openvidu.client.internal.JsonRoomUtils;
import org.openvidu.client.internal.MediaErrorInfo;
import org.openvidu.client.internal.Notification;
import org.openvidu.client.internal.ParticipantEvictedInfo;
import org.openvidu.client.internal.ParticipantJoinedInfo;
import org.openvidu.client.internal.ParticipantLeftInfo;
import org.openvidu.client.internal.ParticipantPublishedInfo;
import org.openvidu.client.internal.ParticipantUnpublishedInfo;
import org.openvidu.client.internal.ProtocolElements;
import org.openvidu.client.internal.RoomClosedInfo;
import org.openvidu.client.internal.SendMessageInfo;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@ -45,6 +32,20 @@ import com.google.gson.JsonArray;
import com.google.gson.JsonElement;
import com.google.gson.JsonObject;
import io.openvidu.client.internal.IceCandidate;
import io.openvidu.client.internal.IceCandidateInfo;
import io.openvidu.client.internal.JsonRoomUtils;
import io.openvidu.client.internal.MediaErrorInfo;
import io.openvidu.client.internal.Notification;
import io.openvidu.client.internal.ParticipantEvictedInfo;
import io.openvidu.client.internal.ParticipantJoinedInfo;
import io.openvidu.client.internal.ParticipantLeftInfo;
import io.openvidu.client.internal.ParticipantPublishedInfo;
import io.openvidu.client.internal.ParticipantUnpublishedInfo;
import io.openvidu.client.internal.ProtocolElements;
import io.openvidu.client.internal.RoomClosedInfo;
import io.openvidu.client.internal.SendMessageInfo;
/**
* Service that handles server JSON-RPC events.
*

View File

@ -1,4 +1,4 @@
package org.openvidu.client.internal;
package io.openvidu.client.internal;
public class IceCandidate {

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.client.internal;
package io.openvidu.client.internal;
/**
* @see Notification

View File

@ -14,16 +14,17 @@
* limitations under the License.
*/
package org.openvidu.client.internal;
package io.openvidu.client.internal;
import org.kurento.jsonrpc.message.Request;
import org.openvidu.client.OpenViduException;
import org.openvidu.client.OpenViduException.Code;
import com.google.gson.JsonArray;
import com.google.gson.JsonElement;
import com.google.gson.JsonObject;
import io.openvidu.client.OpenViduException;
import io.openvidu.client.OpenViduException.Code;
/**
* JSON tools for extracting info from request or response elements.
*

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.client.internal;
package io.openvidu.client.internal;
/**
*

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.client.internal;
package io.openvidu.client.internal;
/**
* Wrapper for server events.

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.client.internal;
package io.openvidu.client.internal;
/**
* @see Notification

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.client.internal;
package io.openvidu.client.internal;
/**
* @see Notification

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.client.internal;
package io.openvidu.client.internal;
/**
* @see Notification

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.client.internal;
package io.openvidu.client.internal;
import java.util.List;

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.client.internal;
package io.openvidu.client.internal;
/**
* @see Notification

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.client.internal;
package io.openvidu.client.internal;
/**
* This class defines constant values of client-server messages and their parameters.

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.client.internal;
package io.openvidu.client.internal;
/**
* @see Notification

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.client.internal;
package io.openvidu.client.internal;
/**
* @see Notification

View File

@ -13,13 +13,13 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.openvidu.client.test;
package io.openvidu.client.test;
import static io.openvidu.client.internal.ProtocolElements.*;
import static org.hamcrest.CoreMatchers.is;
import static org.junit.Assert.assertThat;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.when;
import static org.openvidu.client.internal.ProtocolElements.*;
import java.io.IOException;
import java.util.HashMap;
@ -29,12 +29,13 @@ import java.util.Map;
import org.junit.Before;
import org.junit.Test;
import org.kurento.jsonrpc.client.JsonRpcClient;
import org.openvidu.client.OpenViduClient;
import org.openvidu.client.ServerJsonRpcHandler;
import com.google.gson.JsonArray;
import com.google.gson.JsonObject;
import io.openvidu.client.OpenViduClient;
import io.openvidu.client.ServerJsonRpcHandler;
/**
* Unit tests for the room client protocol.
*

View File

@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.openvidu</groupId>
<groupId>io.openvidu</groupId>
<artifactId>openvidu</artifactId>
<version>0.0.1-SNAPSHOT</version>
</parent>
@ -46,12 +46,12 @@
<properties>
<!-- Main class -->
<start-class>org.openvidu.demo.OpenViduSampleApp</start-class>
<start-class>io.openvidu.demo.OpenViduSampleApp</start-class>
</properties>
<dependencies>
<dependency>
<groupId>org.openvidu</groupId>
<groupId>io.openvidu</groupId>
<artifactId>openvidu-server</artifactId>
<exclusions>
<exclusion>
@ -61,11 +61,11 @@
</exclusions>
</dependency>
<dependency>
<groupId>org.openvidu</groupId>
<groupId>io.openvidu</groupId>
<artifactId>openvidu-browser</artifactId>
</dependency>
<dependency>
<groupId>org.openvidu</groupId>
<groupId>io.openvidu</groupId>
<artifactId>openvidu-test</artifactId>
<scope>test</scope>
</dependency>

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.demo;
package io.openvidu.demo;
class ClientConfig {
private boolean loopbackRemote;

View File

@ -14,11 +14,12 @@
* limitations under the License.
*
*/
package org.openvidu.demo;
package io.openvidu.demo;
import org.kurento.commons.PropertiesManager;
import org.openvidu.client.OpenViduException;
import org.openvidu.server.core.NotificationRoomManager;
import io.openvidu.client.OpenViduException;
import io.openvidu.server.core.NotificationRoomManager;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.demo;
package io.openvidu.demo;
import java.io.IOException;
import java.util.SortedMap;
@ -23,14 +23,15 @@ import org.kurento.client.FaceOverlayFilter;
import org.kurento.client.MediaElement;
import org.kurento.jsonrpc.Transaction;
import org.kurento.jsonrpc.message.Request;
import org.openvidu.server.core.NotificationRoomManager;
import org.openvidu.server.core.api.pojo.ParticipantRequest;
import org.openvidu.server.rpc.JsonRpcUserControl;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import com.google.gson.JsonObject;
import io.openvidu.server.core.NotificationRoomManager;
import io.openvidu.server.core.api.pojo.ParticipantRequest;
import io.openvidu.server.rpc.JsonRpcUserControl;
/**
* User control that applies a media filter when publishing video.
*

View File

@ -1,14 +1,15 @@
package org.openvidu.demo;
package io.openvidu.demo;
import java.util.SortedMap;
import org.kurento.client.Continuation;
import org.kurento.client.Filter;
import org.kurento.module.markerdetector.ArMarkerdetector;
import org.openvidu.client.internal.ProtocolElements;
import org.openvidu.server.core.api.UserNotificationService;
import org.openvidu.server.core.internal.DefaultNotificationRoomHandler;
import org.openvidu.server.core.internal.Participant;
import io.openvidu.client.internal.ProtocolElements;
import io.openvidu.server.core.api.UserNotificationService;
import io.openvidu.server.core.internal.DefaultNotificationRoomHandler;
import io.openvidu.server.core.internal.Participant;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.demo;
package io.openvidu.demo;
import java.util.List;
import java.util.regex.Matcher;
@ -22,13 +22,14 @@ import java.util.regex.Pattern;
import org.kurento.client.KurentoClient;
import org.kurento.jsonrpc.Session;
import org.openvidu.client.OpenViduException;
import org.openvidu.server.core.internal.DefaultKurentoClientSessionInfo;
import org.openvidu.server.kms.Kms;
import org.openvidu.server.kms.KmsManager;
import org.openvidu.server.kms.MaxWebRtcLoadManager;
import org.openvidu.server.rpc.JsonRpcNotificationService;
import org.openvidu.server.rpc.ParticipantSession;
import io.openvidu.client.OpenViduException;
import io.openvidu.server.core.internal.DefaultKurentoClientSessionInfo;
import io.openvidu.server.kms.Kms;
import io.openvidu.server.kms.KmsManager;
import io.openvidu.server.kms.MaxWebRtcLoadManager;
import io.openvidu.server.rpc.JsonRpcNotificationService;
import io.openvidu.server.rpc.ParticipantSession;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;

View File

@ -14,7 +14,7 @@
* limitations under the License.
*
*/
package org.openvidu.demo;
package io.openvidu.demo;
/**
* @author Radu Tom Vlad (radutom.vlad@gmail.com)

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.demo;
package io.openvidu.demo;
import java.util.List;
import java.util.Map.Entry;
@ -24,10 +24,6 @@ import java.util.TreeMap;
import org.kurento.commons.ConfigFileManager;
import org.kurento.commons.PropertiesManager;
import org.kurento.jsonrpc.JsonUtils;
import org.openvidu.server.OpenViduServer;
import org.openvidu.server.core.NotificationRoomManager;
import org.openvidu.server.kms.KmsManager;
import org.openvidu.server.rpc.JsonRpcUserControl;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.boot.SpringApplication;
@ -37,6 +33,11 @@ import com.google.gson.JsonArray;
import com.google.gson.JsonElement;
import com.google.gson.JsonObject;
import io.openvidu.server.OpenViduServer;
import io.openvidu.server.core.NotificationRoomManager;
import io.openvidu.server.kms.KmsManager;
import io.openvidu.server.rpc.JsonRpcUserControl;
import static org.kurento.commons.PropertiesManager.getPropertyJson;
/**

View File

@ -1,5 +1,5 @@
/*
* (C) Copyright 2016 OpenVidu (http://openVidu.org/)
* (C) Copyright 2016 OpenVidu (http://openvidu.io/)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.

View File

@ -14,14 +14,15 @@
* limitations under the License.
*/
package org.openvidu.test.demo;
package io.openvidu.demo.test;
import java.lang.invoke.MethodHandles;
import java.util.Collection;
import org.junit.runners.Parameterized.Parameters;
import org.kurento.test.browser.WebPageType;
import org.openvidu.test.browser.AddRemoveUsers;
import io.openvidu.test.browser.AddRemoveUsers;
/**
* @see AddRemoveUsers

View File

@ -14,14 +14,15 @@
* limitations under the License.
*/
package org.openvidu.test.demo;
package io.openvidu.demo.test;
import java.lang.invoke.MethodHandles;
import java.util.Collection;
import org.junit.runners.Parameterized.Parameters;
import org.kurento.test.browser.WebPageType;
import org.openvidu.test.browser.AddRemoveUsersNoSinkVerify;
import io.openvidu.test.browser.AddRemoveUsersNoSinkVerify;
/**
* @see AddRemoveUsersNoSinkVerify

View File

@ -14,14 +14,15 @@
* limitations under the License.
*/
package org.openvidu.test.demo;
package io.openvidu.demo.test;
import java.lang.invoke.MethodHandles;
import java.util.Collection;
import org.junit.runners.Parameterized.Parameters;
import org.kurento.test.browser.WebPageType;
import org.openvidu.test.browser.NUsersEqualLifetime;
import io.openvidu.test.browser.NUsersEqualLifetime;
/**
* @see NUsersEqualLifetime

View File

@ -14,14 +14,15 @@
* limitations under the License.
*/
package org.openvidu.test.demo;
package io.openvidu.demo.test;
import java.lang.invoke.MethodHandles;
import java.util.Collection;
import org.junit.runners.Parameterized.Parameters;
import org.kurento.test.browser.WebPageType;
import org.openvidu.test.browser.OneUserQuickReentry;
import io.openvidu.test.browser.OneUserQuickReentry;
/**
* @see OneUserQuickReentry

View File

@ -14,14 +14,15 @@
* limitations under the License.
*/
package org.openvidu.test.demo;
package io.openvidu.demo.test;
import java.lang.invoke.MethodHandles;
import java.util.Collection;
import org.junit.runners.Parameterized.Parameters;
import org.kurento.test.browser.WebPageType;
import org.openvidu.test.browser.SeqAddRemoveUser;
import io.openvidu.test.browser.SeqAddRemoveUser;
/**
* @see SeqAddRemoveUser

View File

@ -14,14 +14,15 @@
* limitations under the License.
*/
package org.openvidu.test.demo;
package io.openvidu.demo.test;
import java.lang.invoke.MethodHandles;
import java.util.Collection;
import org.junit.runners.Parameterized.Parameters;
import org.kurento.test.browser.WebPageType;
import org.openvidu.test.browser.SeqNUsersEqualLifetime;
import io.openvidu.test.browser.SeqNUsersEqualLifetime;
/**
* @see SeqNUsersEqualLifetime

View File

@ -14,14 +14,15 @@
* limitations under the License.
*/
package org.openvidu.test.demo;
package io.openvidu.demo.test;
import java.lang.invoke.MethodHandles;
import java.util.Collection;
import org.junit.runners.Parameterized.Parameters;
import org.kurento.test.browser.WebPageType;
import org.openvidu.test.browser.TwoUsersEqualLifetime;
import io.openvidu.test.browser.TwoUsersEqualLifetime;
/**
* @see TwoUsersEqualLifetime

View File

@ -14,14 +14,15 @@
* limitations under the License.
*/
package org.openvidu.test.demo;
package io.openvidu.demo.test;
import java.lang.invoke.MethodHandles;
import java.util.Collection;
import org.junit.runners.Parameterized.Parameters;
import org.kurento.test.browser.WebPageType;
import org.openvidu.test.browser.UnpublishMedia;
import io.openvidu.test.browser.UnpublishMedia;
/**
* @see UnpublishMedia

View File

@ -14,14 +14,15 @@
* limitations under the License.
*/
package org.openvidu.test.demo;
package io.openvidu.demo.test;
import java.lang.invoke.MethodHandles;
import java.util.Collection;
import org.junit.runners.Parameterized.Parameters;
import org.kurento.test.browser.WebPageType;
import org.openvidu.test.browser.UnsubscribeFromMedia;
import io.openvidu.test.browser.UnsubscribeFromMedia;
/**
* @see UnsubscribeFromMedia

View File

@ -14,14 +14,15 @@
* limitations under the License.
*/
package org.openvidu.test.demo;
package io.openvidu.demo.test;
import java.lang.invoke.MethodHandles;
import java.util.Collection;
import org.junit.runners.Parameterized.Parameters;
import org.kurento.test.browser.WebPageType;
import org.openvidu.test.browser.WebAppAvailability;
import io.openvidu.test.browser.WebAppAvailability;
/**
* @author Radu Tom Vlad (rvlad@naevatec.com)

View File

@ -13,14 +13,15 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.openvidu.test.demo.fake;
package io.openvidu.demo.test.fake;
import java.lang.invoke.MethodHandles;
import java.util.Collection;
import org.junit.runners.Parameterized.Parameters;
import org.kurento.test.browser.WebPageType;
import org.openvidu.test.fake.ExtraKmsFakeUsers;
import io.openvidu.test.fake.ExtraKmsFakeUsers;
/**
* @see ExtraKmsFakeUsers

View File

@ -13,14 +13,15 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.openvidu.test.demo.fake;
package io.openvidu.demo.test.fake;
import java.lang.invoke.MethodHandles;
import java.util.Collection;
import org.junit.runners.Parameterized.Parameters;
import org.kurento.test.browser.WebPageType;
import org.openvidu.test.fake.MixedUsers;
import io.openvidu.test.fake.MixedUsers;
/**
* @see MixedUsers

View File

@ -13,14 +13,15 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.openvidu.test.demo.fake;
package io.openvidu.demo.test.fake;
import java.lang.invoke.MethodHandles;
import java.util.Collection;
import org.junit.runners.Parameterized.Parameters;
import org.kurento.test.browser.WebPageType;
import org.openvidu.test.fake.ParallelNFakeUsers;
import io.openvidu.test.fake.ParallelNFakeUsers;
/**
* @see ParallelNFakeUsers

View File

@ -0,0 +1,118 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>io.openvidu</groupId>
<artifactId>openvidu</artifactId>
<version>0.0.1-SNAPSHOT</version>
</parent>
<artifactId>openvidu-java-client</artifactId>
<packaging>jar</packaging>
<name>OpenVidu Java Client</name>
<description> OpenVidu client for your Java backend: get sessionId's and tokens easily from your OpenVidu server</description>
<url>http://openvidu.io</url>
<licenses>
<license>
<name>Apache 2.0</name>
<url>http://www.apache.org/licenses/LICENSE-2.0</url>
<distribution>repo</distribution>
</license>
</licenses>
<organization>
<name>OpenVidu</name>
<url>http://openvidu.io</url>
</organization>
<scm>
<url>https://github.com/OpenVidu/openvidu.git</url>
<connection>scm:git:https://github.com/OpenVidu/openvidu.git</connection>
<developerConnection>scm:git:https://github.com/OpenVidu/openvidu.git</developerConnection>
<tag>develop</tag>
</scm>
<developers>
<developer>
<id>openvidu.io</id>
<name>-openvidu.io Community</name>
<organization>openvidu.io</organization>
<organizationUrl>http://openvidu.io</organizationUrl>
</developer>
</developers>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<java.version>1.8</java.version>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
</properties>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
</dependency>
<dependency>
<groupId>com.googlecode.json-simple</groupId>
<artifactId>json-simple</artifactId>
</dependency>
</dependencies>
<profiles>
<profile>
<id>release-sign-artifacts</id>
<activation>
<property>
<name>performRelease</name>
<value>true</value>
</property>
</activation>
<build>
<plugins>
<plugin>
<groupId>org.sonatype.plugins</groupId>
<artifactId>nexus-staging-maven-plugin</artifactId>
<version>1.6.8</version>
<extensions>true</extensions>
<configuration>
<serverId>ossrh</serverId>
<nexusUrl>https://oss.sonatype.org/</nexusUrl>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-gpg-plugin</artifactId>
<executions>
<execution>
<id>sign-artifacts</id>
<phase>verify</phase>
<goals>
<goal>sign</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
</project>

View File

@ -0,0 +1,12 @@
#release configuration
#Tue Jun 06 11:42:44 CEST 2017
scm.tagNameFormat=@{project.artifactId}-@{project.version}
pushChanges=false
scm.url=scm\:git\:https\://github.com/OpenVidu/openvidu.git
preparationGoals=versions\:use-releases
remoteTagging=true
projectVersionPolicyId=default
scm.commentPrefix=[maven-release-plugin]
exec.additionalArguments=-Pkurento-release
exec.snapshotReleasePluginAllowed=false
completedPhase=check-poms

View File

@ -1,4 +1,4 @@
package org.openvidu.client;
package io.openvidu.java.client;
import java.security.KeyManagementException;
import java.security.KeyStoreException;

View File

@ -15,7 +15,7 @@
*
*/
package org.openvidu.client;
package io.openvidu.java.client;
public class OpenViduException extends RuntimeException {
private static final long serialVersionUID = 1L;

View File

@ -1,4 +1,4 @@
package org.openvidu.client;
package io.openvidu.java.client;
public enum OpenViduRole {
SUBSCRIBER,

View File

@ -1,4 +1,4 @@
package org.openvidu.client;
package io.openvidu.java.client;
import java.io.BufferedReader;
import java.io.IOException;
@ -12,7 +12,8 @@ import org.apache.http.entity.StringEntity;
import org.json.simple.JSONObject;
import org.json.simple.parser.JSONParser;
import org.json.simple.parser.ParseException;
import org.openvidu.client.OpenViduException.Code;
import io.openvidu.java.client.OpenViduException.Code;
public class Session {

View File

@ -1,4 +1,4 @@
package org.openvidu.client;
package io.openvidu.java.client;
public class TokenOptions {

View File

@ -1,4 +1,4 @@
package org.openvidu.client;
package io.openvidu.java.client.test;
import junit.framework.Test;
import junit.framework.TestCase;

View File

@ -2,7 +2,7 @@
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>openvidu</groupId>
<groupId>io.openvidu</groupId>
<artifactId>openvidu-sample-app</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>war</packaging>
@ -138,8 +138,8 @@
</dependency>
<dependency>
<groupId>org.openvidu</groupId>
<artifactId>openvidu-backend-client</artifactId>
<groupId>io.openvidu</groupId>
<artifactId>openvidu-java-client</artifactId>
<version>0.0.1-SNAPSHOT</version>
</dependency>

View File

@ -6,10 +6,6 @@ import java.util.Map;
import java.util.concurrent.ConcurrentHashMap;
import org.json.simple.JSONObject;
import org.openvidu.client.OpenVidu;
import org.openvidu.client.Session;
import org.openvidu.client.TokenOptions;
import org.openvidu.client.OpenViduRole;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.http.HttpStatus;
@ -19,6 +15,11 @@ import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;
import io.openvidu.java.client.OpenVidu;
import io.openvidu.java.client.Session;
import io.openvidu.java.client.TokenOptions;
import io.openvidu.java.client.OpenViduRole;
import openvidu.openvidu_sample_app.lesson.Lesson;
import openvidu.openvidu_sample_app.lesson.LessonRepository;
import openvidu.openvidu_sample_app.user.User;

View File

@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.openvidu</groupId>
<groupId>io.openvidu</groupId>
<artifactId>openvidu</artifactId>
<version>0.0.1-SNAPSHOT</version>
</parent>
@ -39,16 +39,16 @@
<developers>
<developer>
<id>openvidu.org</id>
<name>-openvidu.org Community</name>
<organization>OpenVidu.org</organization>
<organizationUrl>https://github.com/OpenVidu/openvidu</organizationUrl>
<id>openvidu.io</id>
<name>-openvidu.io Community</name>
<organization>OpenVidu</organization>
<organizationUrl>http://openvidu.io</organizationUrl>
</developer>
</developers>
<properties>
<!-- Main class -->
<start-class>org.openvidu.server.OpenViduServer</start-class>
<start-class>io.openvidu.server.OpenViduServer</start-class>
</properties>
<build>
@ -108,12 +108,12 @@
</exclusions>
</dependency>
<dependency>
<groupId>org.openvidu</groupId>
<groupId>io.openvidu</groupId>
<artifactId>openvidu-test</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.openvidu</groupId>
<groupId>io.openvidu</groupId>
<artifactId>openvidu-client</artifactId>
</dependency>
<dependency>

View File

@ -14,13 +14,14 @@
* limitations under the License.
*
*/
package org.openvidu.server;
package io.openvidu.server;
import org.kurento.client.KurentoClient;
import org.kurento.client.Properties;
import org.openvidu.client.OpenViduException;
import org.openvidu.server.core.api.KurentoClientProvider;
import org.openvidu.server.core.api.KurentoClientSessionInfo;
import io.openvidu.client.OpenViduException;
import io.openvidu.server.core.api.KurentoClientProvider;
import io.openvidu.server.core.api.KurentoClientSessionInfo;
public class AutodiscoveryKurentoClientProvider implements KurentoClientProvider {

View File

@ -1,4 +1,4 @@
package org.openvidu.server;
package io.openvidu.server;
import java.io.IOException;
import java.util.Map;

View File

@ -1,4 +1,4 @@
package org.openvidu.server;
package io.openvidu.server;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

View File

@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.openvidu.server;
package io.openvidu.server;
import static org.kurento.commons.PropertiesManager.getPropertyJson;
@ -23,14 +23,6 @@ import org.kurento.jsonrpc.JsonUtils;
import org.kurento.jsonrpc.internal.server.config.JsonRpcConfiguration;
import org.kurento.jsonrpc.server.JsonRpcConfigurer;
import org.kurento.jsonrpc.server.JsonRpcHandlerRegistry;
import org.openvidu.server.core.NotificationRoomManager;
import org.openvidu.server.core.RoomManager;
import org.openvidu.server.core.api.KurentoClientProvider;
import org.openvidu.server.core.api.NotificationRoomHandler;
import org.openvidu.server.core.internal.DefaultNotificationRoomHandler;
import org.openvidu.server.kms.FixedOneKmsManager;
import org.openvidu.server.rpc.JsonRpcNotificationService;
import org.openvidu.server.rpc.JsonRpcUserControl;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Value;
@ -45,6 +37,16 @@ import org.springframework.web.socket.server.standard.ServletServerContainerFact
import com.google.gson.Gson;
import com.google.gson.JsonArray;
import io.openvidu.server.core.NotificationRoomManager;
import io.openvidu.server.core.RoomManager;
import io.openvidu.server.core.api.KurentoClientProvider;
import io.openvidu.server.core.api.NotificationRoomHandler;
import io.openvidu.server.core.internal.DefaultNotificationRoomHandler;
import io.openvidu.server.kms.FixedOneKmsManager;
import io.openvidu.server.rest.NgrokController;
import io.openvidu.server.rpc.JsonRpcNotificationService;
import io.openvidu.server.rpc.JsonRpcUserControl;
/**
* Room server application.
*
@ -144,6 +146,17 @@ public class OpenViduServer implements JsonRpcConfigurer {
public static void main(String[] args) throws Exception {
start(args);
try {
NgrokController ngrok = new NgrokController();
log.info("");
log.info(" PUBLIC IP ");
log.info("-------------------------");
log.info(ngrok.getNgrokPublicUrl());
log.info("-------------------------");
log.info("");
} catch(Exception e) {
System.out.println("No ngrok connection");
}
}
public static ConfigurableApplicationContext start(String[] args) {

View File

@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.openvidu.server;
package io.openvidu.server;
import java.util.Arrays;
import java.util.List;
@ -22,17 +22,18 @@ import org.kurento.jsonrpc.DefaultJsonRpcHandler;
import org.kurento.jsonrpc.Session;
import org.kurento.jsonrpc.Transaction;
import org.kurento.jsonrpc.message.Request;
import org.openvidu.client.internal.ProtocolElements;
import org.openvidu.server.core.api.pojo.ParticipantRequest;
import org.openvidu.server.rpc.JsonRpcNotificationService;
import org.openvidu.server.rpc.JsonRpcUserControl;
import org.openvidu.server.rpc.ParticipantSession;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import com.google.gson.JsonObject;
import io.openvidu.client.internal.ProtocolElements;
import io.openvidu.server.core.api.pojo.ParticipantRequest;
import io.openvidu.server.rpc.JsonRpcNotificationService;
import io.openvidu.server.rpc.JsonRpcUserControl;
import io.openvidu.server.rpc.ParticipantSession;
/**
* @author Ivan Gracia (izanmail@gmail.com)
* @author Micael Gallego (micael.gallego@gmail.com)

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.server.core;
package io.openvidu.server.core;
import javax.annotation.PreDestroy;
@ -23,20 +23,21 @@ import java.util.Set;
import org.kurento.client.MediaElement;
import org.kurento.client.MediaPipeline;
import org.kurento.client.MediaType;
import org.openvidu.client.OpenViduException;
import org.openvidu.client.OpenViduException.Code;
import org.openvidu.server.core.RoomManager.JoinRoomReturnValue;
import org.openvidu.server.core.api.KurentoClientSessionInfo;
import org.openvidu.server.core.api.MutedMediaType;
import org.openvidu.server.core.api.NotificationRoomHandler;
import org.openvidu.server.core.api.pojo.ParticipantRequest;
import org.openvidu.server.core.api.pojo.UserParticipant;
import org.openvidu.server.core.internal.DefaultKurentoClientSessionInfo;
import org.openvidu.server.security.ParticipantRole;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import io.openvidu.client.OpenViduException;
import io.openvidu.client.OpenViduException.Code;
import io.openvidu.server.core.RoomManager.JoinRoomReturnValue;
import io.openvidu.server.core.api.KurentoClientSessionInfo;
import io.openvidu.server.core.api.MutedMediaType;
import io.openvidu.server.core.api.NotificationRoomHandler;
import io.openvidu.server.core.api.pojo.ParticipantRequest;
import io.openvidu.server.core.api.pojo.UserParticipant;
import io.openvidu.server.core.internal.DefaultKurentoClientSessionInfo;
import io.openvidu.server.security.ParticipantRole;
/**
* The Kurento room manager represents an SDK for any developer that wants to implement the Room
* server-side application. They can build their application on top of the manager's Java API and

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.server.core;
package io.openvidu.server.core;
import javax.annotation.PreDestroy;
@ -34,24 +34,25 @@ import org.kurento.client.MediaPipeline;
import org.kurento.client.MediaType;
import org.kurento.client.RtpEndpoint;
import org.kurento.client.WebRtcEndpoint;
import org.openvidu.client.OpenViduException;
import org.openvidu.client.OpenViduException.Code;
import org.openvidu.server.InfoHandler;
import org.openvidu.server.core.api.KurentoClientProvider;
import org.openvidu.server.core.api.KurentoClientSessionInfo;
import org.openvidu.server.core.api.MutedMediaType;
import org.openvidu.server.core.api.RoomHandler;
import org.openvidu.server.core.api.pojo.UserParticipant;
import org.openvidu.server.core.endpoint.SdpType;
import org.openvidu.server.core.internal.Participant;
import org.openvidu.server.core.internal.Room;
import org.openvidu.server.security.ParticipantRole;
import org.openvidu.server.security.Token;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import io.openvidu.client.OpenViduException;
import io.openvidu.client.OpenViduException.Code;
import io.openvidu.server.InfoHandler;
import io.openvidu.server.core.api.KurentoClientProvider;
import io.openvidu.server.core.api.KurentoClientSessionInfo;
import io.openvidu.server.core.api.MutedMediaType;
import io.openvidu.server.core.api.RoomHandler;
import io.openvidu.server.core.api.pojo.UserParticipant;
import io.openvidu.server.core.endpoint.SdpType;
import io.openvidu.server.core.internal.Participant;
import io.openvidu.server.core.internal.Room;
import io.openvidu.server.security.ParticipantRole;
import io.openvidu.server.security.Token;
/**
* The Kurento room manager represents an SDK for any developer that wants to implement the Room
* server-side application. They can build their application on top of the manager's Java API and

View File

@ -14,10 +14,11 @@
* limitations under the License.
*/
package org.openvidu.server.core.api;
package io.openvidu.server.core.api;
import org.kurento.client.KurentoClient;
import org.openvidu.client.OpenViduException;
import io.openvidu.client.OpenViduException;
/**
* This service interface was designed so that the room manager could obtain a {@link KurentoClient}

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.server.core.api;
package io.openvidu.server.core.api;
import org.kurento.client.KurentoClient;

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.server.core.api;
package io.openvidu.server.core.api;
public enum MutedMediaType {
ALL, VIDEO, AUDIO;

View File

@ -14,15 +14,16 @@
* limitations under the License.
*/
package org.openvidu.server.core.api;
package io.openvidu.server.core.api;
import java.util.Set;
import org.kurento.client.MediaElement;
import org.openvidu.client.OpenViduException;
import org.openvidu.server.core.NotificationRoomManager;
import org.openvidu.server.core.api.pojo.ParticipantRequest;
import org.openvidu.server.core.api.pojo.UserParticipant;
import io.openvidu.client.OpenViduException;
import io.openvidu.server.core.NotificationRoomManager;
import io.openvidu.server.core.api.pojo.ParticipantRequest;
import io.openvidu.server.core.api.pojo.UserParticipant;
/**
* Through this interface, the room API passes the execution result of client-originated requests to

View File

@ -14,13 +14,14 @@
* limitations under the License.
*/
package org.openvidu.server.core.api;
package io.openvidu.server.core.api;
import java.util.Set;
import org.kurento.client.IceCandidate;
import org.openvidu.server.InfoHandler;
import org.openvidu.server.core.internal.Participant;
import io.openvidu.server.InfoHandler;
import io.openvidu.server.core.internal.Participant;
/**
* Handler for events triggered from media objects.

View File

@ -14,11 +14,11 @@
* limitations under the License.
*/
package org.openvidu.server.core.api;
package io.openvidu.server.core.api;
import org.openvidu.client.OpenViduException;
import org.openvidu.server.core.api.pojo.ParticipantRequest;
import org.openvidu.server.core.internal.DefaultNotificationRoomHandler;
import io.openvidu.client.OpenViduException;
import io.openvidu.server.core.api.pojo.ParticipantRequest;
import io.openvidu.server.core.internal.DefaultNotificationRoomHandler;
/**
* This specification was designed so that the room manager could send notifications or responses

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.server.core.api.pojo;
package io.openvidu.server.core.api.pojo;
/**
* This POJO uniquely identifies a participant's request.

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.server.core.api.pojo;
package io.openvidu.server.core.api.pojo;
/**
* This POJO holds information about a room participant.

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.server.core.endpoint;
package io.openvidu.server.core.endpoint;
import java.util.LinkedList;
import java.util.Map;
@ -33,13 +33,14 @@ import org.kurento.client.OnIceCandidateEvent;
import org.kurento.client.RtpEndpoint;
import org.kurento.client.SdpEndpoint;
import org.kurento.client.WebRtcEndpoint;
import org.openvidu.client.OpenViduException;
import org.openvidu.client.OpenViduException.Code;
import org.openvidu.server.core.api.MutedMediaType;
import org.openvidu.server.core.internal.Participant;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import io.openvidu.client.OpenViduException;
import io.openvidu.client.OpenViduException.Code;
import io.openvidu.server.core.api.MutedMediaType;
import io.openvidu.server.core.internal.Participant;
/**
* {@link WebRtcEndpoint} wrapper that supports buffering of {@link IceCandidate}s until the
* {@link WebRtcEndpoint} is created. Connections to other peers are opened using the corresponding

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.server.core.endpoint;
package io.openvidu.server.core.endpoint;
import java.util.Collection;
import java.util.HashMap;
@ -29,13 +29,14 @@ import org.kurento.client.MediaPipeline;
import org.kurento.client.MediaType;
import org.kurento.client.PassThrough;
import org.kurento.client.WebRtcEndpoint;
import org.openvidu.client.OpenViduException;
import org.openvidu.client.OpenViduException.Code;
import org.openvidu.server.core.api.MutedMediaType;
import org.openvidu.server.core.internal.Participant;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import io.openvidu.client.OpenViduException;
import io.openvidu.client.OpenViduException.Code;
import io.openvidu.server.core.api.MutedMediaType;
import io.openvidu.server.core.internal.Participant;
/**
* Publisher aspect of the {@link MediaEndpoint}.
*

View File

@ -15,7 +15,7 @@
*
*/
package org.openvidu.server.core.endpoint;
package io.openvidu.server.core.endpoint;
public enum SdpType {
OFFER, ANSWER;

View File

@ -14,17 +14,18 @@
* limitations under the License.
*/
package org.openvidu.server.core.endpoint;
package io.openvidu.server.core.endpoint;
import org.kurento.client.MediaPipeline;
import org.kurento.client.MediaType;
import org.openvidu.client.OpenViduException;
import org.openvidu.client.OpenViduException.Code;
import org.openvidu.server.core.api.MutedMediaType;
import org.openvidu.server.core.internal.Participant;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import io.openvidu.client.OpenViduException;
import io.openvidu.client.OpenViduException.Code;
import io.openvidu.server.core.api.MutedMediaType;
import io.openvidu.server.core.internal.Participant;
/**
* Subscriber aspect of the {@link MediaEndpoint}.
*

View File

@ -14,9 +14,9 @@
* limitations under the License.
*/
package org.openvidu.server.core.internal;
package io.openvidu.server.core.internal;
import org.openvidu.server.core.api.KurentoClientSessionInfo;
import io.openvidu.server.core.api.KurentoClientSessionInfo;
/**
* Default implementation of the session info interface, contains a participant's id and the room's

View File

@ -14,23 +14,24 @@
* limitations under the License.
*/
package org.openvidu.server.core.internal;
package io.openvidu.server.core.internal;
import java.util.Set;
import org.kurento.client.IceCandidate;
import org.openvidu.client.OpenViduException;
import org.openvidu.client.internal.ProtocolElements;
import org.openvidu.server.InfoHandler;
import org.openvidu.server.core.api.NotificationRoomHandler;
import org.openvidu.server.core.api.UserNotificationService;
import org.openvidu.server.core.api.pojo.ParticipantRequest;
import org.openvidu.server.core.api.pojo.UserParticipant;
import org.springframework.beans.factory.annotation.Autowired;
import com.google.gson.JsonArray;
import com.google.gson.JsonObject;
import io.openvidu.client.OpenViduException;
import io.openvidu.client.internal.ProtocolElements;
import io.openvidu.server.InfoHandler;
import io.openvidu.server.core.api.NotificationRoomHandler;
import io.openvidu.server.core.api.UserNotificationService;
import io.openvidu.server.core.api.pojo.ParticipantRequest;
import io.openvidu.server.core.api.pojo.UserParticipant;
/**
* Default implementation that assumes that JSON-RPC messages specification was used for the
* client-server communications.

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.server.core.internal;
package io.openvidu.server.core.internal;
import java.util.HashSet;
import java.util.Set;
@ -32,17 +32,18 @@ import org.kurento.client.MediaPipeline;
import org.kurento.client.MediaType;
import org.kurento.client.SdpEndpoint;
import org.kurento.client.internal.server.KurentoServerException;
import org.openvidu.client.OpenViduException;
import org.openvidu.client.OpenViduException.Code;
import org.openvidu.server.InfoHandler;
import org.openvidu.server.core.api.MutedMediaType;
import org.openvidu.server.core.endpoint.MediaEndpoint;
import org.openvidu.server.core.endpoint.PublisherEndpoint;
import org.openvidu.server.core.endpoint.SdpType;
import org.openvidu.server.core.endpoint.SubscriberEndpoint;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import io.openvidu.client.OpenViduException;
import io.openvidu.client.OpenViduException.Code;
import io.openvidu.server.InfoHandler;
import io.openvidu.server.core.api.MutedMediaType;
import io.openvidu.server.core.endpoint.MediaEndpoint;
import io.openvidu.server.core.endpoint.PublisherEndpoint;
import io.openvidu.server.core.endpoint.SdpType;
import io.openvidu.server.core.endpoint.SubscriberEndpoint;
/**
* @author Ivan Gracia (izanmail@gmail.com)
* @author Micael Gallego (micael.gallego@gmail.com)

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.server.core.internal;
package io.openvidu.server.core.internal;
import java.util.Collection;
import java.util.Set;
@ -30,14 +30,15 @@ import org.kurento.client.EventListener;
import org.kurento.client.IceCandidate;
import org.kurento.client.KurentoClient;
import org.kurento.client.MediaPipeline;
import org.openvidu.client.OpenViduException;
import org.openvidu.client.OpenViduException.Code;
import org.openvidu.server.InfoHandler;
import org.openvidu.server.core.api.RoomHandler;
import org.openvidu.server.core.api.pojo.UserParticipant;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import io.openvidu.client.OpenViduException;
import io.openvidu.client.OpenViduException.Code;
import io.openvidu.server.InfoHandler;
import io.openvidu.server.core.api.RoomHandler;
import io.openvidu.server.core.api.pojo.UserParticipant;
/**
* @author Ivan Gracia (izanmail@gmail.com)
* @author Micael Gallego (micael.gallego@gmail.com)

View File

@ -14,7 +14,7 @@
* limitations under the License.
*
*/
package org.openvidu.server.internal;
package io.openvidu.server.internal;
public class ThreadLogUtils {

View File

@ -15,7 +15,7 @@
*
*/
package org.openvidu.server.kms;
package io.openvidu.server.kms;
import org.kurento.client.KurentoClient;

View File

@ -15,7 +15,7 @@
*
*/
package org.openvidu.server.kms;
package io.openvidu.server.kms;
import org.kurento.client.KurentoClient;

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.server.kms;
package io.openvidu.server.kms;
import java.util.ArrayList;
import java.util.Collections;
@ -22,14 +22,15 @@ import java.util.Iterator;
import java.util.List;
import org.kurento.client.KurentoClient;
import org.openvidu.client.OpenViduException;
import org.openvidu.client.OpenViduException.Code;
import org.openvidu.server.core.api.KurentoClientProvider;
import org.openvidu.server.core.api.KurentoClientSessionInfo;
import org.openvidu.server.core.internal.DefaultKurentoClientSessionInfo;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import io.openvidu.client.OpenViduException;
import io.openvidu.client.OpenViduException.Code;
import io.openvidu.server.core.api.KurentoClientProvider;
import io.openvidu.server.core.api.KurentoClientSessionInfo;
import io.openvidu.server.core.internal.DefaultKurentoClientSessionInfo;
public abstract class KmsManager implements KurentoClientProvider {
public static class KmsLoad implements Comparable<KmsLoad> {

View File

@ -15,7 +15,7 @@
*
*/
package org.openvidu.server.kms;
package io.openvidu.server.kms;
public interface LoadManager {

View File

@ -15,7 +15,7 @@
*
*/
package org.openvidu.server.kms;
package io.openvidu.server.kms;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

View File

@ -0,0 +1,41 @@
package io.openvidu.server.rest;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import org.apache.http.HttpResponse;
import org.apache.http.client.ClientProtocolException;
import org.apache.http.client.HttpClient;
import org.apache.http.client.methods.HttpGet;
import org.apache.http.impl.client.HttpClientBuilder;
import com.google.gson.JsonObject;
import com.google.gson.JsonParser;
public class NgrokController {
private final String NGROK_URL = "http://localhost:4040/api/tunnels";
HttpClient client = HttpClientBuilder.create().build();
public String getNgrokPublicUrl() throws ClientProtocolException, IOException {
HttpClient client = HttpClientBuilder.create().build();
HttpGet request = new HttpGet(NGROK_URL);
HttpResponse response = client.execute(request);
BufferedReader rd = new BufferedReader(new InputStreamReader(response.getEntity().getContent()));
StringBuffer result = new StringBuffer();
String line = "";
while ((line = rd.readLine()) != null) {
result.append(line);
}
JsonObject json = (JsonObject) new JsonParser().parse(result.toString());
String publicUrl = json.getAsJsonArray("tunnels").get(0).getAsJsonObject().get("public_url").getAsString();
publicUrl = publicUrl.replaceFirst("http://", "https://");
return publicUrl;
}
}

View File

@ -14,16 +14,13 @@
* limitations under the License.
*
*/
package org.openvidu.server.rest;
package io.openvidu.server.rest;
import static org.kurento.commons.PropertiesManager.getProperty;
import java.util.Map;
import java.util.Set;
import org.json.simple.JSONObject;
import org.openvidu.client.OpenViduException;
import org.openvidu.server.core.NotificationRoomManager;
import org.openvidu.server.security.ParticipantRole;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.HttpStatus;
import org.springframework.http.ResponseEntity;
@ -32,6 +29,10 @@ import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;
import io.openvidu.client.OpenViduException;
import io.openvidu.server.core.NotificationRoomManager;
import io.openvidu.server.security.ParticipantRole;
/**
*
* @author Raquel Díaz González

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.server.rpc;
package io.openvidu.server.rpc;
import java.io.IOException;
import java.util.concurrent.ConcurrentHashMap;
@ -23,14 +23,15 @@ import java.util.concurrent.ConcurrentMap;
import org.kurento.jsonrpc.Session;
import org.kurento.jsonrpc.Transaction;
import org.kurento.jsonrpc.message.Request;
import org.openvidu.client.OpenViduException;
import org.openvidu.server.core.api.UserNotificationService;
import org.openvidu.server.core.api.pojo.ParticipantRequest;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import com.google.gson.JsonObject;
import io.openvidu.client.OpenViduException;
import io.openvidu.server.core.api.UserNotificationService;
import io.openvidu.server.core.api.pojo.ParticipantRequest;
/**
* JSON-RPC implementation of {@link UserNotificationService} for WebSockets.
*

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.server.rpc;
package io.openvidu.server.rpc;
import java.io.IOException;
import java.util.concurrent.ExecutionException;
@ -22,18 +22,19 @@ import java.util.concurrent.ExecutionException;
import org.kurento.jsonrpc.Session;
import org.kurento.jsonrpc.Transaction;
import org.kurento.jsonrpc.message.Request;
import org.openvidu.client.OpenViduException;
import org.openvidu.client.OpenViduException.Code;
import org.openvidu.client.internal.ProtocolElements;
import org.openvidu.server.core.NotificationRoomManager;
import org.openvidu.server.core.api.pojo.ParticipantRequest;
import org.openvidu.server.core.api.pojo.UserParticipant;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import com.google.gson.JsonObject;
import io.openvidu.client.OpenViduException;
import io.openvidu.client.OpenViduException.Code;
import io.openvidu.client.internal.ProtocolElements;
import io.openvidu.server.core.NotificationRoomManager;
import io.openvidu.server.core.api.pojo.ParticipantRequest;
import io.openvidu.server.core.api.pojo.UserParticipant;
/**
* Controls the user interactions by delegating her JSON-RPC requests to the room API.
*

View File

@ -15,7 +15,7 @@
*
*/
package org.openvidu.server.rpc;
package io.openvidu.server.rpc;
/**
* Participant information that should be stored in the WebSocket session.

View File

@ -15,7 +15,7 @@
*
*/
package org.openvidu.server.rpc;
package io.openvidu.server.rpc;
import java.util.Collection;
import java.util.concurrent.ConcurrentHashMap;

View File

@ -1,4 +1,4 @@
package org.openvidu.server.security;
package io.openvidu.server.security;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;

View File

@ -1,4 +1,4 @@
package org.openvidu.server.security;
package io.openvidu.server.security;
public enum ParticipantRole {
SUBSCRIBER,

View File

@ -1,4 +1,4 @@
package org.openvidu.server.security;
package io.openvidu.server.security;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;

View File

@ -1,4 +1,4 @@
package org.openvidu.server.security;
package io.openvidu.server.security;
public class Token {

View File

@ -0,0 +1,9 @@
spring.profiles.active=ngrok
server.port: 5000
server.address: 0.0.0.0
kms.uris=[\"ws://localhost:8888/kurento\"]
openvidu.secret: MY_SECRET
openvidu.security: true

View File

@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.openvidu.server.test;
package io.openvidu.server.test;
import static org.junit.Assert.fail;
@ -30,17 +30,18 @@ import java.util.concurrent.TimeUnit;
import org.junit.Test;
import org.kurento.client.internal.KmsProvider;
import org.kurento.client.internal.NotEnoughResourcesException;
import org.openvidu.server.OpenViduServer;
import org.openvidu.server.core.NotificationRoomManager;
import org.openvidu.server.core.RoomManager;
import org.openvidu.server.core.api.KurentoClientSessionInfo;
import org.openvidu.server.core.internal.DefaultKurentoClientSessionInfo;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.context.ConfigurableApplicationContext;
import com.google.common.base.StandardSystemProperty;
import io.openvidu.server.OpenViduServer;
import io.openvidu.server.core.NotificationRoomManager;
import io.openvidu.server.core.RoomManager;
import io.openvidu.server.core.api.KurentoClientSessionInfo;
import io.openvidu.server.core.internal.DefaultKurentoClientSessionInfo;
/**
* Integration server test, checks the autodiscovery of KMS URLs.
*

View File

@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.openvidu.server.test;
package io.openvidu.server.test;
import static org.hamcrest.CoreMatchers.equalTo;
import static org.hamcrest.CoreMatchers.is;
@ -47,23 +47,24 @@ import org.mockito.Mock;
import org.mockito.invocation.InvocationOnMock;
import org.mockito.runners.MockitoJUnitRunner;
import org.mockito.stubbing.Answer;
import org.openvidu.client.OpenViduClient;
import org.openvidu.client.ServerJsonRpcHandler;
import org.openvidu.client.internal.Notification;
import org.openvidu.client.internal.ParticipantJoinedInfo;
import org.openvidu.client.internal.ProtocolElements;
import org.openvidu.client.internal.Notification.Method;
import org.openvidu.server.RoomJsonRpcHandler;
import org.openvidu.server.core.api.pojo.ParticipantRequest;
import org.openvidu.server.core.api.pojo.UserParticipant;
import org.openvidu.server.core.internal.DefaultNotificationRoomHandler;
import org.openvidu.server.rpc.JsonRpcNotificationService;
import org.openvidu.server.rpc.JsonRpcUserControl;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import com.google.gson.JsonObject;
import io.openvidu.client.OpenViduClient;
import io.openvidu.client.ServerJsonRpcHandler;
import io.openvidu.client.internal.Notification;
import io.openvidu.client.internal.ParticipantJoinedInfo;
import io.openvidu.client.internal.ProtocolElements;
import io.openvidu.client.internal.Notification.Method;
import io.openvidu.server.RoomJsonRpcHandler;
import io.openvidu.server.core.api.pojo.ParticipantRequest;
import io.openvidu.server.core.api.pojo.UserParticipant;
import io.openvidu.server.core.internal.DefaultNotificationRoomHandler;
import io.openvidu.server.rpc.JsonRpcNotificationService;
import io.openvidu.server.rpc.JsonRpcUserControl;
/**
* Integration tests for the room server protocol.
*

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.server.test.core;
package io.openvidu.server.test.core;
import static org.hamcrest.CoreMatchers.containsString;
import static org.hamcrest.CoreMatchers.equalTo;
@ -64,15 +64,6 @@ import org.mockito.Matchers;
import org.mockito.Mock;
import org.mockito.invocation.InvocationOnMock;
import org.mockito.stubbing.Answer;
import org.openvidu.client.OpenViduException;
import org.openvidu.client.internal.ProtocolElements;
import org.openvidu.server.core.NotificationRoomManager;
import org.openvidu.server.core.api.KurentoClientProvider;
import org.openvidu.server.core.api.KurentoClientSessionInfo;
import org.openvidu.server.core.api.UserNotificationService;
import org.openvidu.server.core.api.pojo.ParticipantRequest;
import org.openvidu.server.core.api.pojo.UserParticipant;
import org.openvidu.server.core.internal.DefaultNotificationRoomHandler;
import org.powermock.core.classloader.annotations.PrepareForTest;
import org.powermock.modules.junit4.PowerMockRunner;
@ -80,6 +71,16 @@ import com.google.gson.JsonArray;
import com.google.gson.JsonElement;
import com.google.gson.JsonObject;
import io.openvidu.client.OpenViduException;
import io.openvidu.client.internal.ProtocolElements;
import io.openvidu.server.core.NotificationRoomManager;
import io.openvidu.server.core.api.KurentoClientProvider;
import io.openvidu.server.core.api.KurentoClientSessionInfo;
import io.openvidu.server.core.api.UserNotificationService;
import io.openvidu.server.core.api.pojo.ParticipantRequest;
import io.openvidu.server.core.api.pojo.UserParticipant;
import io.openvidu.server.core.internal.DefaultNotificationRoomHandler;
/**
* Tests for {@link NotificationRoomManager} when using {@link DefaultNotificationRoomHandler}
* (mocked {@link UserNotificationService} and {@link KurentoClient} resources).

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.openvidu.server.test.core;
package io.openvidu.server.test.core;
import static org.hamcrest.CoreMatchers.containsString;
import static org.hamcrest.CoreMatchers.hasItem;
@ -79,17 +79,18 @@ import org.mockito.Matchers;
import org.mockito.Mock;
import org.mockito.invocation.InvocationOnMock;
import org.mockito.stubbing.Answer;
import org.openvidu.client.OpenViduException;
import org.openvidu.client.OpenViduException.Code;
import org.openvidu.server.core.RoomManager;
import org.openvidu.server.core.api.KurentoClientProvider;
import org.openvidu.server.core.api.KurentoClientSessionInfo;
import org.openvidu.server.core.api.MutedMediaType;
import org.openvidu.server.core.api.RoomHandler;
import org.openvidu.server.core.api.pojo.UserParticipant;
import org.powermock.core.classloader.annotations.PrepareForTest;
import org.powermock.modules.junit4.PowerMockRunner;
import io.openvidu.client.OpenViduException;
import io.openvidu.client.OpenViduException.Code;
import io.openvidu.server.core.RoomManager;
import io.openvidu.server.core.api.KurentoClientProvider;
import io.openvidu.server.core.api.KurentoClientSessionInfo;
import io.openvidu.server.core.api.MutedMediaType;
import io.openvidu.server.core.api.RoomHandler;
import io.openvidu.server.core.api.pojo.UserParticipant;
/**
* Tests for {@link RoomManager} when using mocked {@link KurentoClient} resources.
*

Some files were not shown because too many files have changed in this diff Show More