Jitsi Meet - Secure, Simple and Scalable Video Conferences that you use as a standalone app or embed in your web application.
TypeScript debiandeep-videojitsijitsi-meetscalable-video-conferencessfuvideovideo-communicationvideo-conferencingwebrtc
feature(rtcstats): expose sendSdp as config option (#12072)
Nils Ohlmeier96099a06a809
diff --git a/config.js b/config.jsindex 9f01e98482..f7467ee503 100644--- a/config.js+++ b/config.js@@ -969,6 +969,10 @@ var config = {// will only send data related to RTCPeerConnection events.// rtcstatsPollInterval: 10000,+ // This determines if rtcstats sends the SDP to the rtcstats server or replaces+ // all SDPs with an emtpy string instead.+ // rtcstatsSendSdp: false,+// Array of script URLs to load as lib-jitsi-meet "analytics handlers".// scriptURLs: [// "libs/analytics-ga.min.js", // google-analyticsdiff --git a/react/features/rtcstats/RTCStats.js b/react/features/rtcstats/RTCStats.jsindex 4d158dd42a..ca5d6f21f3 100644--- a/react/features/rtcstats/RTCStats.js+++ b/react/features/rtcstats/RTCStats.js@@ -41,11 +41,12 @@ class RTCStats {* @param {string} options.useLegacy - Switch to legacy chrome webrtc statistics. Parameter will only have* an effect on chrome based applications.* @param {number} options.pollInterval - The getstats poll interval in ms.+ * @param {boolean} options.sendSdp - Determines if the client sends SDP to the rtcstats server.* @returns {void}*/init(options) {- const { endpoint, useLegacy, pollInterval } = options;+ const { endpoint, useLegacy, pollInterval, sendSdp } = options;const traceOptions = {endpoint,@@ -56,7 +57,8 @@ class RTCStats {const rtcstatsOptions = {connectionFilter,pollInterval,- useLegacy+ useLegacy,+ sendSdp};this.trace = traceInit(traceOptions);diff --git a/react/features/rtcstats/middleware.js b/react/features/rtcstats/middleware.jsindex 113500e865..dbafdbb5fc 100644--- a/react/features/rtcstats/middleware.js+++ b/react/features/rtcstats/middleware.js@@ -44,6 +44,7 @@ MiddlewareRegistry.register(store => next => action => {// Default poll interval is 10000ms and standard stats will be used, if not provided in the config.const pollInterval = analytics.rtcstatsPollInterval || 10000;const useLegacy = analytics.rtcstatsUseLegacy || false;+ const sendSdp = analytics.rtcstatsSendSdp || false;// Initialize but don't connect to the rtcstats server wss, as it will start sending data for all@@ -51,7 +52,8 @@ MiddlewareRegistry.register(store => next => action => {RTCStats.init({endpoint: analytics.rtcstatsEndpoint,useLegacy,- pollInterval+ pollInterval,+ sendSdp});} catch (error) {logger.error('Failed to initialize RTCStats: ', error);