소스 검색

Adds analytics event and console log for TTFM (time to first media).

j8
damencho 9 년 전
부모
커밋
06c636311d
2개의 변경된 파일12개의 추가작업 그리고 0개의 파일을 삭제
  1. 6
    0
      conference.js
  2. 6
    0
      modules/UI/videolayout/SmallVideo.js

+ 6
- 0
conference.js 파일 보기

628
     sendFeedback (overallFeedback, detailedFeedback) {
628
     sendFeedback (overallFeedback, detailedFeedback) {
629
         return room.sendFeedback (overallFeedback, detailedFeedback);
629
         return room.sendFeedback (overallFeedback, detailedFeedback);
630
     },
630
     },
631
+    /**
632
+     * Returns the connection times stored in the library.
633
+     */
634
+    getConnectionTimes () {
635
+        return this._room.getConnectionTimes();
636
+    },
631
     // used by torture currently
637
     // used by torture currently
632
     isJoined () {
638
     isJoined () {
633
         return this._room
639
         return this._room

+ 6
- 0
modules/UI/videolayout/SmallVideo.js 파일 보기

167
         console.log("(TIME) Render " + type + ":\t",
167
         console.log("(TIME) Render " + type + ":\t",
168
                     now);
168
                     now);
169
         AnalyticsAdapter.sendEvent('render.' + type, now);
169
         AnalyticsAdapter.sendEvent('render.' + type, now);
170
+
171
+        var ttfm = now - APP.connectionTimes["document.ready"]
172
+            - (APP.conference.getConnectionTimes()["session.initiate"]
173
+                - APP.conference.getConnectionTimes()["muc.joined"]);
174
+        console.log("(TIME) TTFM " + type + ":\t", ttfm);
175
+        AnalyticsAdapter.sendEvent('ttfm.' + type, ttfm);
170
     };
176
     };
171
     return element;
177
     return element;
172
 };
178
 };

Loading…
취소
저장