Преглед изворни кода

HUE-7226 [frontend] Log when the editor operations hang

Romain Rigaux пре 8 година
родитељ
комит
61b5495
1 измењених фајлова са 5 додато и 0 уклоњено
  1. 5 0
      desktop/libs/notebook/src/notebook/static/notebook/js/notebook.ko.js

+ 5 - 0
desktop/libs/notebook/src/notebook/static/notebook/js/notebook.ko.js

@@ -1157,6 +1157,11 @@ var EditorViewModel = (function() {
 
     self.executingBlockingOperation = null; // A ExecuteStatement()
     self.showLongOperationWarning = ko.observable(false);
+    self.showLongOperationWarning.subscribe(function(newValue) {
+      if (newValue) {
+        hueAnalytics.convert('editor', 'showLongOperationWarning');
+      }
+    });
 
     var longOperationTimeout = -1;