mirror of https://github.com/OpenVidu/openvidu.git
openvidu-server: cancel KMS webrtc stats gathering for MediaEndpoint
parent
87e39e8a01
commit
77a5349487
|
@ -376,6 +376,10 @@ public class KurentoParticipant extends Participant {
|
|||
}
|
||||
|
||||
publisher.unregisterErrorListeners();
|
||||
if (publisher.kmsWebrtcStatsThread != null) {
|
||||
publisher.kmsWebrtcStatsThread.cancel(true);
|
||||
}
|
||||
|
||||
for (MediaElement el : publisher.getMediaElements()) {
|
||||
releaseElement(getParticipantPublicId(), el);
|
||||
}
|
||||
|
@ -393,7 +397,12 @@ public class KurentoParticipant extends Participant {
|
|||
|
||||
private void releaseSubscriberEndpoint(String senderName, SubscriberEndpoint subscriber, String reason) {
|
||||
if (subscriber != null) {
|
||||
|
||||
subscriber.unregisterErrorListeners();
|
||||
if (subscriber.kmsWebrtcStatsThread != null) {
|
||||
subscriber.kmsWebrtcStatsThread.cancel(true);
|
||||
}
|
||||
|
||||
releaseElement(senderName, subscriber.getEndpoint());
|
||||
|
||||
if (!ProtocolElements.RECORDER_PARTICIPANT_PUBLICID.equals(this.getParticipantPublicId())) {
|
||||
|
|
|
@ -22,6 +22,7 @@ import java.util.List;
|
|||
import java.util.Queue;
|
||||
import java.util.concurrent.ConcurrentLinkedQueue;
|
||||
import java.util.concurrent.CountDownLatch;
|
||||
import java.util.concurrent.Future;
|
||||
|
||||
import org.kurento.client.Continuation;
|
||||
import org.kurento.client.ErrorEvent;
|
||||
|
@ -87,6 +88,7 @@ public abstract class MediaEndpoint {
|
|||
public String selectedLocalIceCandidate;
|
||||
public String selectedRemoteIceCandidate;
|
||||
public Queue<KmsEvent> kmsEvents = new ConcurrentLinkedQueue<>();
|
||||
public Future<?> kmsWebrtcStatsThread;
|
||||
|
||||
/**
|
||||
* Constructor to set the owner, the endpoint's name and the media pipeline.
|
||||
|
|
Loading…
Reference in New Issue