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

feat(reload): on offer / answer error.

factor2
Hristo Terezov пре 6 година
родитељ
комит
a91b49c2c1

+ 1
- 7
conference.js Прегледај датотеку

@@ -379,13 +379,6 @@ class ConferenceConnector {
379 379
             APP.UI.notifyGracefulShutdown();
380 380
             break;
381 381
 
382
-        case JitsiConferenceErrors.JINGLE_FATAL_ERROR: {
383
-            const [ error ] = params;
384
-
385
-            APP.UI.notifyInternalError(error);
386
-            break;
387
-        }
388
-
389 382
         case JitsiConferenceErrors.CONFERENCE_DESTROYED: {
390 383
             const [ reason ] = params;
391 384
 
@@ -407,6 +400,7 @@ class ConferenceConnector {
407 400
 
408 401
         case JitsiConferenceErrors.FOCUS_LEFT:
409 402
         case JitsiConferenceErrors.VIDEOBRIDGE_NOT_AVAILABLE:
403
+        case JitsiConferenceErrors.OFFER_ANSWER_FAILED:
410 404
             APP.store.dispatch(conferenceWillLeave(room));
411 405
 
412 406
             // FIXME the conference should be stopped by the library and not by

+ 2
- 2
package-lock.json Прегледај датотеку

@@ -8946,8 +8946,8 @@
8946 8946
       }
8947 8947
     },
8948 8948
     "lib-jitsi-meet": {
8949
-      "version": "github:jitsi/lib-jitsi-meet#a89d67388f49cc18aae080cb388877380a7664b1",
8950
-      "from": "github:jitsi/lib-jitsi-meet#a89d67388f49cc18aae080cb388877380a7664b1",
8949
+      "version": "github:jitsi/lib-jitsi-meet#ee1854c1b12a229f70f351acaebe6686f38f6a85",
8950
+      "from": "github:jitsi/lib-jitsi-meet#ee1854c1b12a229f70f351acaebe6686f38f6a85",
8951 8951
       "requires": {
8952 8952
         "@jitsi/sdp-interop": "0.1.14",
8953 8953
         "@jitsi/sdp-simulcast": "0.2.1",

+ 1
- 1
package.json Прегледај датотеку

@@ -52,7 +52,7 @@
52 52
     "js-utils": "github:jitsi/js-utils#73a67a7a60d52f8e895f50939c8fcbd1f20fe7b5",
53 53
     "jsrsasign": "8.0.12",
54 54
     "jwt-decode": "2.2.0",
55
-    "lib-jitsi-meet": "github:jitsi/lib-jitsi-meet#a89d67388f49cc18aae080cb388877380a7664b1",
55
+    "lib-jitsi-meet": "github:jitsi/lib-jitsi-meet#ee1854c1b12a229f70f351acaebe6686f38f6a85",
56 56
     "libflacjs": "github:mmig/libflac.js#93d37e7f811f01cf7d8b6a603e38bd3c3810907d",
57 57
     "lodash": "4.17.11",
58 58
     "moment": "2.19.4",

+ 12
- 0
react/features/analytics/AnalyticsEvents.js Прегледај датотеку

@@ -271,6 +271,18 @@ export function createInviteDialogEvent(
271 271
     };
272 272
 }
273 273
 
274
+/**
275
+ * Creates an "offer/answer failure" event.
276
+ *
277
+ * @returns {Object} The event in a format suitable for sending via
278
+ * sendAnalytics.
279
+ */
280
+export function createOfferAnswerFailedEvent() {
281
+    return {
282
+        action: 'offer.answer.failure'
283
+    };
284
+}
285
+
274 286
 /**
275 287
  * Creates a "page reload" event.
276 288
  *

+ 8
- 2
react/features/base/conference/middleware.js Прегледај датотеку

@@ -6,10 +6,12 @@ import {
6 6
     ACTION_UNPINNED,
7 7
     createAudioOnlyChangedEvent,
8 8
     createConnectionEvent,
9
+    createOfferAnswerFailedEvent,
9 10
     createPinnedEvent,
10 11
     sendAnalytics
11 12
 } from '../../analytics';
12 13
 import { CONNECTION_ESTABLISHED, CONNECTION_FAILED } from '../connection';
14
+import { JitsiConferenceErrors } from '../lib-jitsi-meet';
13 15
 import { setVideoMuted, VIDEO_MUTISM_AUTHORITY } from '../media';
14 16
 import {
15 17
     getLocalParticipant,
@@ -152,6 +154,12 @@ StateListenerRegistry.register(
152 154
 function _conferenceFailed(store, next, action) {
153 155
     const result = next(action);
154 156
 
157
+    const { conference, error } = action;
158
+
159
+    if (error.name === JitsiConferenceErrors.OFFER_ANSWER_FAILED) {
160
+        sendAnalytics(createOfferAnswerFailedEvent());
161
+    }
162
+
155 163
     // FIXME: Workaround for the web version. Currently, the creation of the
156 164
     // conference is handled by /conference.js and appropriate failure handlers
157 165
     // are set there.
@@ -165,8 +173,6 @@ function _conferenceFailed(store, next, action) {
165 173
     }
166 174
 
167 175
     // XXX After next(action), it is clear whether the error is recoverable.
168
-    const { conference, error } = action;
169
-
170 176
     !error.recoverable
171 177
         && conference
172 178
         && conference.leave().catch(reason => {

+ 1
- 0
react/features/base/lib-jitsi-meet/functions.js Прегледај датотеку

@@ -70,6 +70,7 @@ export function isFatalJitsiConferenceError(error: Object | string) {
70 70
     return (
71 71
         error === JitsiConferenceErrors.FOCUS_DISCONNECTED
72 72
             || error === JitsiConferenceErrors.FOCUS_LEFT
73
+            || error === JitsiConferenceErrors.OFFER_ANSWER_FAILED
73 74
             || error === JitsiConferenceErrors.VIDEOBRIDGE_NOT_AVAILABLE);
74 75
 }
75 76
 

Loading…
Откажи
Сачувај