Browse Source

feat(logging_config): add "disableLogCollector" option

master
paweldomas 9 years ago
parent
commit
94bd6bc330
2 changed files with 7 additions and 3 deletions
  1. 5
    3
      app.js
  2. 2
    0
      logging_config.js

+ 5
- 3
app.js View File

@@ -162,7 +162,7 @@ const APP = {
162 162
         // Adjust logging level
163 163
         configureLoggingLevels();
164 164
         // Start the LogCollector and register it as the global log transport
165
-        if (!this.logCollector) {
165
+        if (!this.logCollector && !loggingConfig.disableLogCollector) {
166 166
             this.logCollector = new LogCollector({
167 167
                 storeLogs: (logJSON) => {
168 168
                     // Try catch was used, because there are many variables
@@ -211,8 +211,10 @@ function init() {
211 211
     if (isUIReady) {
212 212
         // Start the LogCollector's periodic "store logs" task only if we're in
213 213
         // the conference and not on the welcome page.
214
-        APP.logCollector.start();
215
-        APP.logCollectorStarted = true;
214
+        if (APP.logCollector) {
215
+            APP.logCollector.start();
216
+            APP.logCollectorStarted = true;
217
+        }
216 218
 
217 219
         APP.conference.init({roomName: buildRoomName()}).then(function () {
218 220
 

+ 2
- 0
logging_config.js View File

@@ -2,6 +2,8 @@
2 2
 var loggingConfig = { // eslint-disable-line no-unused-vars
3 3
     //default log level for the app and lib-jitsi-meet
4 4
     //defaultLogLevel: 'trace',
5
+    // Option to disable LogCollector (which stores the logs on CallStats)
6
+    //disableLogCollector: true,
5 7
     // Examples:
6 8
     //'modules/version/ComponentsVersions.js': 'info',
7 9
     //'modules/xmpp/ChatRoom.js': 'log'

Loading…
Cancel
Save