mirror of https://github.com/OpenVidu/openvidu.git
openvidu-server: update WebMvcConfigurer to new non-deprecated API
parent
f3310b2abf
commit
56c4cbdd98
|
@ -62,7 +62,6 @@ import io.openvidu.server.kurento.core.KurentoSessionManager;
|
||||||
import io.openvidu.server.kurento.kms.DummyLoadManager;
|
import io.openvidu.server.kurento.kms.DummyLoadManager;
|
||||||
import io.openvidu.server.kurento.kms.FixedOneKmsManager;
|
import io.openvidu.server.kurento.kms.FixedOneKmsManager;
|
||||||
import io.openvidu.server.kurento.kms.KmsManager;
|
import io.openvidu.server.kurento.kms.KmsManager;
|
||||||
import io.openvidu.server.kurento.kms.LoadManager;
|
|
||||||
import io.openvidu.server.recording.service.RecordingManager;
|
import io.openvidu.server.recording.service.RecordingManager;
|
||||||
import io.openvidu.server.rpc.RpcHandler;
|
import io.openvidu.server.rpc.RpcHandler;
|
||||||
import io.openvidu.server.rpc.RpcNotificationService;
|
import io.openvidu.server.rpc.RpcNotificationService;
|
||||||
|
@ -104,7 +103,7 @@ public class OpenViduServer implements JsonRpcConfigurer {
|
||||||
}
|
}
|
||||||
|
|
||||||
String firstKmsWsUri = kmsWsUris.get(0);
|
String firstKmsWsUri = kmsWsUris.get(0);
|
||||||
log.info("OpenVidu Server using one KMS: {}", kmsWsUris);
|
log.info("OpenVidu Server using one KMS: {}", firstKmsWsUri);
|
||||||
return new FixedOneKmsManager(firstKmsWsUri, new DummyLoadManager());
|
return new FixedOneKmsManager(firstKmsWsUri, new DummyLoadManager());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -80,8 +80,6 @@ public abstract class SessionManager {
|
||||||
protected ConcurrentMap<String, Boolean> insecureUsers = new ConcurrentHashMap<>();
|
protected ConcurrentMap<String, Boolean> insecureUsers = new ConcurrentHashMap<>();
|
||||||
public ConcurrentMap<String, ConcurrentHashMap<String, Token>> sessionidTokenTokenobj = new ConcurrentHashMap<>();
|
public ConcurrentMap<String, ConcurrentHashMap<String, Token>> sessionidTokenTokenobj = new ConcurrentHashMap<>();
|
||||||
|
|
||||||
private volatile boolean closed = false;
|
|
||||||
|
|
||||||
public abstract void joinRoom(Participant participant, String sessionId, Integer transactionId);
|
public abstract void joinRoom(Participant participant, String sessionId, Integer transactionId);
|
||||||
|
|
||||||
public abstract void leaveRoom(Participant participant, Integer transactionId, EndReason reason,
|
public abstract void leaveRoom(Participant participant, Integer transactionId, EndReason reason,
|
||||||
|
@ -407,7 +405,6 @@ public abstract class SessionManager {
|
||||||
*/
|
*/
|
||||||
@PreDestroy
|
@PreDestroy
|
||||||
public void close() {
|
public void close() {
|
||||||
closed = true;
|
|
||||||
log.info("Closing all sessions");
|
log.info("Closing all sessions");
|
||||||
for (String sessionId : sessions.keySet()) {
|
for (String sessionId : sessions.keySet()) {
|
||||||
try {
|
try {
|
||||||
|
|
|
@ -21,13 +21,13 @@ import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
|
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
|
||||||
import org.springframework.context.annotation.Configuration;
|
import org.springframework.context.annotation.Configuration;
|
||||||
import org.springframework.web.servlet.config.annotation.ResourceHandlerRegistry;
|
import org.springframework.web.servlet.config.annotation.ResourceHandlerRegistry;
|
||||||
import org.springframework.web.servlet.config.annotation.WebMvcConfigurerAdapter;
|
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;
|
||||||
|
|
||||||
import io.openvidu.server.config.OpenviduConfig;
|
import io.openvidu.server.config.OpenviduConfig;
|
||||||
|
|
||||||
@Configuration
|
@Configuration
|
||||||
@ConditionalOnProperty(name = "openvidu.recording", havingValue = "true")
|
@ConditionalOnProperty(name = "openvidu.recording", havingValue = "true")
|
||||||
public class CustomLayoutsHttpHandler extends WebMvcConfigurerAdapter {
|
public class CustomLayoutsHttpHandler implements WebMvcConfigurer {
|
||||||
|
|
||||||
@Autowired
|
@Autowired
|
||||||
OpenviduConfig openviduConfig;
|
OpenviduConfig openviduConfig;
|
||||||
|
|
|
@ -20,12 +20,12 @@ package io.openvidu.server.recording;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.context.annotation.Configuration;
|
import org.springframework.context.annotation.Configuration;
|
||||||
import org.springframework.web.servlet.config.annotation.ResourceHandlerRegistry;
|
import org.springframework.web.servlet.config.annotation.ResourceHandlerRegistry;
|
||||||
import org.springframework.web.servlet.config.annotation.WebMvcConfigurerAdapter;
|
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;
|
||||||
|
|
||||||
import io.openvidu.server.config.OpenviduConfig;
|
import io.openvidu.server.config.OpenviduConfig;
|
||||||
|
|
||||||
@Configuration
|
@Configuration
|
||||||
public class RecordingsHttpHandler extends WebMvcConfigurerAdapter {
|
public class RecordingsHttpHandler implements WebMvcConfigurer {
|
||||||
|
|
||||||
@Autowired
|
@Autowired
|
||||||
OpenviduConfig openviduConfig;
|
OpenviduConfig openviduConfig;
|
||||||
|
|
2
pom.xml
2
pom.xml
|
@ -42,7 +42,7 @@
|
||||||
</developers>
|
</developers>
|
||||||
|
|
||||||
<properties>
|
<properties>
|
||||||
<version.kurento>6.10.1-SNAPSHOT</version.kurento>
|
<version.kurento>6.10.0</version.kurento>
|
||||||
<version.spring-boot>2.1.5.RELEASE</version.spring-boot>
|
<version.spring-boot>2.1.5.RELEASE</version.spring-boot>
|
||||||
<version.junit>4.12</version.junit>
|
<version.junit>4.12</version.junit>
|
||||||
<version.junit.jupiter>5.5.0-M1</version.junit.jupiter>
|
<version.junit.jupiter>5.5.0-M1</version.junit.jupiter>
|
||||||
|
|
Loading…
Reference in New Issue