@webex/plugin-meetings 3.0.0-stream-classes.4 → 3.0.0-test.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +12 -0
- package/dist/breakouts/breakout.js +1 -1
- package/dist/breakouts/index.js +1 -1
- package/dist/common/errors/no-meeting-info.js +51 -0
- package/dist/common/errors/no-meeting-info.js.map +1 -0
- package/dist/common/errors/reclaim-host-role-errors.js +158 -0
- package/dist/common/errors/reclaim-host-role-errors.js.map +1 -0
- package/dist/common/errors/webex-errors.js +23 -3
- package/dist/common/errors/webex-errors.js.map +1 -1
- package/dist/common/logs/request.js +5 -1
- package/dist/common/logs/request.js.map +1 -1
- package/dist/config.js +1 -1
- package/dist/config.js.map +1 -1
- package/dist/constants.js +69 -9
- package/dist/constants.js.map +1 -1
- package/dist/index.js +11 -1
- package/dist/index.js.map +1 -1
- package/dist/interceptors/index.js +15 -0
- package/dist/interceptors/index.js.map +1 -0
- package/dist/interceptors/locusRetry.js +93 -0
- package/dist/interceptors/locusRetry.js.map +1 -0
- package/dist/interpretation/index.js +16 -2
- package/dist/interpretation/index.js.map +1 -1
- package/dist/interpretation/siLanguage.js +1 -1
- package/dist/locus-info/index.js +40 -11
- package/dist/locus-info/index.js.map +1 -1
- package/dist/locus-info/mediaSharesUtils.js +15 -1
- package/dist/locus-info/mediaSharesUtils.js.map +1 -1
- package/dist/locus-info/parser.js +42 -21
- package/dist/locus-info/parser.js.map +1 -1
- package/dist/media/index.js +10 -6
- package/dist/media/index.js.map +1 -1
- package/dist/media/properties.js +13 -3
- package/dist/media/properties.js.map +1 -1
- package/dist/mediaQualityMetrics/config.js +135 -330
- package/dist/mediaQualityMetrics/config.js.map +1 -1
- package/dist/meeting/in-meeting-actions.js +4 -0
- package/dist/meeting/in-meeting-actions.js.map +1 -1
- package/dist/meeting/index.js +2187 -1074
- package/dist/meeting/index.js.map +1 -1
- package/dist/meeting/muteState.js +37 -25
- package/dist/meeting/muteState.js.map +1 -1
- package/dist/meeting/request.js +34 -19
- package/dist/meeting/request.js.map +1 -1
- package/dist/meeting/util.js +71 -0
- package/dist/meeting/util.js.map +1 -1
- package/dist/meeting-info/index.js +48 -23
- package/dist/meeting-info/index.js.map +1 -1
- package/dist/meeting-info/meeting-info-v2.js +25 -4
- package/dist/meeting-info/meeting-info-v2.js.map +1 -1
- package/dist/meeting-info/utilv2.js +1 -1
- package/dist/meeting-info/utilv2.js.map +1 -1
- package/dist/meetings/collection.js +17 -0
- package/dist/meetings/collection.js.map +1 -1
- package/dist/meetings/index.js +142 -57
- package/dist/meetings/index.js.map +1 -1
- package/dist/meetings/util.js +2 -6
- package/dist/meetings/util.js.map +1 -1
- package/dist/member/index.js +9 -0
- package/dist/member/index.js.map +1 -1
- package/dist/member/util.js +11 -0
- package/dist/member/util.js.map +1 -1
- package/dist/members/index.js +17 -1
- package/dist/members/index.js.map +1 -1
- package/dist/members/types.js.map +1 -1
- package/dist/members/util.js +15 -4
- package/dist/members/util.js.map +1 -1
- package/dist/metrics/constants.js +15 -1
- package/dist/metrics/constants.js.map +1 -1
- package/dist/multistream/mediaRequestManager.js +1 -1
- package/dist/multistream/mediaRequestManager.js.map +1 -1
- package/dist/multistream/remoteMediaGroup.js +16 -2
- package/dist/multistream/remoteMediaGroup.js.map +1 -1
- package/dist/multistream/remoteMediaManager.js +222 -73
- package/dist/multistream/remoteMediaManager.js.map +1 -1
- package/dist/multistream/sendSlotManager.js +22 -0
- package/dist/multistream/sendSlotManager.js.map +1 -1
- package/dist/reachability/clusterReachability.js +356 -0
- package/dist/reachability/clusterReachability.js.map +1 -0
- package/dist/reachability/index.js +262 -432
- package/dist/reachability/index.js.map +1 -1
- package/dist/reachability/request.js +1 -1
- package/dist/reachability/request.js.map +1 -1
- package/dist/reachability/util.js +29 -0
- package/dist/reachability/util.js.map +1 -0
- package/dist/reconnection-manager/index.js +113 -96
- package/dist/reconnection-manager/index.js.map +1 -1
- package/dist/roap/index.js +57 -25
- package/dist/roap/index.js.map +1 -1
- package/dist/roap/request.js +5 -13
- package/dist/roap/request.js.map +1 -1
- package/dist/roap/turnDiscovery.js +173 -81
- package/dist/roap/turnDiscovery.js.map +1 -1
- package/dist/rtcMetrics/index.js +68 -6
- package/dist/rtcMetrics/index.js.map +1 -1
- package/dist/statsAnalyzer/index.js +338 -289
- package/dist/statsAnalyzer/index.js.map +1 -1
- package/dist/statsAnalyzer/mqaUtil.js +296 -156
- package/dist/statsAnalyzer/mqaUtil.js.map +1 -1
- package/dist/types/common/errors/no-meeting-info.d.ts +14 -0
- package/dist/types/common/errors/reclaim-host-role-errors.d.ts +60 -0
- package/dist/types/common/errors/webex-errors.d.ts +13 -1
- package/dist/types/common/logs/request.d.ts +2 -0
- package/dist/types/config.d.ts +1 -1
- package/dist/types/constants.d.ts +66 -13
- package/dist/types/index.d.ts +1 -1
- package/dist/types/interceptors/index.d.ts +2 -0
- package/dist/types/interceptors/locusRetry.d.ts +27 -0
- package/dist/types/locus-info/index.d.ts +1 -1
- package/dist/types/locus-info/parser.d.ts +3 -2
- package/dist/types/mediaQualityMetrics/config.d.ts +99 -223
- package/dist/types/meeting/in-meeting-actions.d.ts +4 -0
- package/dist/types/meeting/index.d.ts +285 -34
- package/dist/types/meeting/locusMediaRequest.d.ts +1 -2
- package/dist/types/meeting/muteState.d.ts +2 -8
- package/dist/types/meeting/request.d.ts +4 -1
- package/dist/types/meeting/util.d.ts +25 -1
- package/dist/types/meeting-info/index.d.ts +7 -0
- package/dist/types/meeting-info/meeting-info-v2.d.ts +1 -0
- package/dist/types/meetings/collection.d.ts +9 -0
- package/dist/types/meetings/index.d.ts +42 -14
- package/dist/types/member/index.d.ts +1 -0
- package/dist/types/members/types.d.ts +1 -0
- package/dist/types/members/util.d.ts +5 -0
- package/dist/types/metrics/constants.d.ts +15 -0
- package/dist/types/multistream/mediaRequestManager.d.ts +2 -0
- package/dist/types/multistream/remoteMediaGroup.d.ts +2 -0
- package/dist/types/multistream/remoteMediaManager.d.ts +25 -1
- package/dist/types/multistream/sendSlotManager.d.ts +9 -0
- package/dist/types/reachability/clusterReachability.d.ts +109 -0
- package/dist/types/reachability/index.d.ts +59 -112
- package/dist/types/reachability/request.d.ts +1 -1
- package/dist/types/reachability/util.d.ts +8 -0
- package/dist/types/reconnection-manager/index.d.ts +10 -0
- package/dist/types/roap/index.d.ts +2 -1
- package/dist/types/roap/request.d.ts +2 -1
- package/dist/types/roap/turnDiscovery.d.ts +21 -4
- package/dist/types/rtcMetrics/index.d.ts +15 -1
- package/dist/types/statsAnalyzer/index.d.ts +28 -11
- package/dist/types/statsAnalyzer/mqaUtil.d.ts +28 -4
- package/dist/types/webinar/collection.d.ts +16 -0
- package/dist/types/webinar/index.d.ts +5 -0
- package/dist/webinar/collection.js +44 -0
- package/dist/webinar/collection.js.map +1 -0
- package/dist/webinar/index.js +69 -0
- package/dist/webinar/index.js.map +1 -0
- package/package.json +3 -2
- package/src/common/errors/no-meeting-info.ts +24 -0
- package/src/common/errors/reclaim-host-role-errors.ts +134 -0
- package/src/common/errors/webex-errors.ts +19 -2
- package/src/common/logs/request.ts +5 -1
- package/src/config.ts +1 -1
- package/src/constants.ts +71 -6
- package/src/index.ts +5 -0
- package/src/interceptors/index.ts +3 -0
- package/src/interceptors/locusRetry.ts +67 -0
- package/src/interpretation/index.ts +18 -1
- package/src/locus-info/index.ts +52 -16
- package/src/locus-info/mediaSharesUtils.ts +16 -0
- package/src/locus-info/parser.ts +47 -21
- package/src/media/index.ts +8 -6
- package/src/media/properties.ts +17 -2
- package/src/mediaQualityMetrics/config.ts +103 -238
- package/src/meeting/in-meeting-actions.ts +8 -0
- package/src/meeting/index.ts +1510 -529
- package/src/meeting/muteState.ts +34 -20
- package/src/meeting/request.ts +19 -1
- package/src/meeting/util.ts +97 -0
- package/src/meeting-info/index.ts +47 -20
- package/src/meeting-info/meeting-info-v2.ts +27 -5
- package/src/meeting-info/utilv2.ts +1 -1
- package/src/meetings/collection.ts +13 -0
- package/src/meetings/index.ts +112 -31
- package/src/meetings/util.ts +2 -8
- package/src/member/index.ts +9 -0
- package/src/member/util.ts +14 -0
- package/src/members/index.ts +29 -2
- package/src/members/types.ts +1 -0
- package/src/members/util.ts +15 -1
- package/src/metrics/constants.ts +14 -0
- package/src/multistream/mediaRequestManager.ts +4 -1
- package/src/multistream/remoteMediaGroup.ts +19 -0
- package/src/multistream/remoteMediaManager.ts +141 -18
- package/src/multistream/sendSlotManager.ts +29 -0
- package/src/reachability/clusterReachability.ts +320 -0
- package/src/reachability/index.ts +221 -382
- package/src/reachability/request.ts +1 -1
- package/src/reachability/util.ts +24 -0
- package/src/reconnection-manager/index.ts +87 -83
- package/src/roap/index.ts +60 -24
- package/src/roap/request.ts +3 -16
- package/src/roap/turnDiscovery.ts +112 -39
- package/src/rtcMetrics/index.ts +71 -5
- package/src/statsAnalyzer/index.ts +430 -427
- package/src/statsAnalyzer/mqaUtil.ts +317 -168
- package/src/webinar/collection.ts +31 -0
- package/src/webinar/index.ts +62 -0
- package/test/integration/spec/converged-space-meetings.js +7 -7
- package/test/integration/spec/journey.js +86 -104
- package/test/integration/spec/space-meeting.js +9 -9
- package/test/unit/spec/interceptors/locusRetry.ts +131 -0
- package/test/unit/spec/interpretation/index.ts +36 -3
- package/test/unit/spec/locus-info/index.js +205 -12
- package/test/unit/spec/locus-info/lib/SeqCmp.json +16 -0
- package/test/unit/spec/locus-info/mediaSharesUtils.ts +10 -0
- package/test/unit/spec/locus-info/parser.js +54 -13
- package/test/unit/spec/media/index.ts +20 -4
- package/test/unit/spec/media/properties.ts +2 -2
- package/test/unit/spec/meeting/in-meeting-actions.ts +4 -0
- package/test/unit/spec/meeting/index.js +4027 -1075
- package/test/unit/spec/meeting/muteState.js +219 -67
- package/test/unit/spec/meeting/request.js +63 -12
- package/test/unit/spec/meeting/utils.js +93 -0
- package/test/unit/spec/meeting-info/index.js +180 -61
- package/test/unit/spec/meeting-info/meetinginfov2.js +196 -53
- package/test/unit/spec/meetings/collection.js +12 -0
- package/test/unit/spec/meetings/index.js +619 -206
- package/test/unit/spec/meetings/utils.js +35 -12
- package/test/unit/spec/member/index.js +8 -7
- package/test/unit/spec/member/util.js +32 -0
- package/test/unit/spec/members/index.js +130 -17
- package/test/unit/spec/members/utils.js +26 -0
- package/test/unit/spec/multistream/mediaRequestManager.ts +20 -2
- package/test/unit/spec/multistream/remoteMediaGroup.ts +80 -1
- package/test/unit/spec/multistream/remoteMediaManager.ts +210 -3
- package/test/unit/spec/multistream/sendSlotManager.ts +50 -18
- package/test/unit/spec/reachability/clusterReachability.ts +279 -0
- package/test/unit/spec/reachability/index.ts +505 -135
- package/test/unit/spec/reachability/util.ts +40 -0
- package/test/unit/spec/reconnection-manager/index.js +74 -17
- package/test/unit/spec/roap/index.ts +181 -61
- package/test/unit/spec/roap/request.ts +27 -3
- package/test/unit/spec/roap/turnDiscovery.ts +362 -101
- package/test/unit/spec/rtcMetrics/index.ts +57 -3
- package/test/unit/spec/stats-analyzer/index.js +1225 -12
- package/test/unit/spec/webinar/collection.ts +13 -0
- package/test/unit/spec/webinar/index.ts +60 -0
- package/test/utils/integrationTestUtils.js +4 -4
- package/test/utils/webex-test-users.js +12 -4
package/src/meeting/muteState.ts
CHANGED
|
@@ -150,15 +150,30 @@ export class MuteState {
|
|
|
150
150
|
* @param {Boolean} [mute] true for muting, false for unmuting request
|
|
151
151
|
* @returns {void}
|
|
152
152
|
*/
|
|
153
|
-
public handleLocalStreamMuteStateChange(meeting?:
|
|
153
|
+
public handleLocalStreamMuteStateChange(meeting?: any) {
|
|
154
154
|
if (this.ignoreMuteStateChange) {
|
|
155
155
|
return;
|
|
156
156
|
}
|
|
157
|
+
|
|
158
|
+
// either user or system may have triggered a mute state change, but localMute should reflect both
|
|
159
|
+
let newMuteState: boolean;
|
|
160
|
+
let userMuteState: boolean;
|
|
161
|
+
let systemMuteState: boolean;
|
|
162
|
+
if (this.type === AUDIO) {
|
|
163
|
+
newMuteState = meeting.mediaProperties.audioStream?.muted;
|
|
164
|
+
userMuteState = meeting.mediaProperties.audioStream?.userMuted;
|
|
165
|
+
systemMuteState = meeting.mediaProperties.audioStream?.systemMuted;
|
|
166
|
+
} else {
|
|
167
|
+
newMuteState = meeting.mediaProperties.videoStream?.muted;
|
|
168
|
+
userMuteState = meeting.mediaProperties.videoStream?.userMuted;
|
|
169
|
+
systemMuteState = meeting.mediaProperties.videoStream?.systemMuted;
|
|
170
|
+
}
|
|
171
|
+
|
|
157
172
|
LoggerProxy.logger.info(
|
|
158
|
-
`Meeting:muteState#handleLocalStreamMuteStateChange --> ${this.type}: local stream new mute state: ${mute}`
|
|
173
|
+
`Meeting:muteState#handleLocalStreamMuteStateChange --> ${this.type}: local stream new mute state: ${newMuteState} (user mute: ${userMuteState}, system mute: ${systemMuteState})`
|
|
159
174
|
);
|
|
160
175
|
|
|
161
|
-
this.state.client.localMute =
|
|
176
|
+
this.state.client.localMute = newMuteState;
|
|
162
177
|
|
|
163
178
|
this.applyClientStateToServer(meeting);
|
|
164
179
|
}
|
|
@@ -249,7 +264,12 @@ export class MuteState {
|
|
|
249
264
|
`Meeting:muteState#applyClientStateToServer --> ${this.type}: error: ${e}`
|
|
250
265
|
);
|
|
251
266
|
|
|
252
|
-
|
|
267
|
+
// failed to apply client state to server, so revert stream mute state to server state
|
|
268
|
+
this.muteLocalStream(
|
|
269
|
+
meeting,
|
|
270
|
+
this.state.server.localMute || this.state.server.remoteMute,
|
|
271
|
+
'clientRequestFailed'
|
|
272
|
+
);
|
|
253
273
|
});
|
|
254
274
|
}
|
|
255
275
|
|
|
@@ -325,18 +345,6 @@ export class MuteState {
|
|
|
325
345
|
});
|
|
326
346
|
}
|
|
327
347
|
|
|
328
|
-
/** Sets the mute state of the local stream according to what server thinks is our state
|
|
329
|
-
* @param {Object} meeting - the meeting object
|
|
330
|
-
* @param {ServerMuteReason} serverMuteReason - reason why we're applying server mute to the local stream
|
|
331
|
-
* @returns {void}
|
|
332
|
-
*/
|
|
333
|
-
private applyServerMuteToLocalStream(meeting: any, serverMuteReason: ServerMuteReason) {
|
|
334
|
-
const muted = this.state.server.localMute || this.state.server.remoteMute;
|
|
335
|
-
|
|
336
|
-
// update the local stream mute state, but not this.state.client.localMute
|
|
337
|
-
this.muteLocalStream(meeting, muted, serverMuteReason);
|
|
338
|
-
}
|
|
339
|
-
|
|
340
348
|
/** Applies the current value for unmute allowed to the underlying stream
|
|
341
349
|
*
|
|
342
350
|
* @param {Meeting} meeting
|
|
@@ -371,7 +379,7 @@ export class MuteState {
|
|
|
371
379
|
}
|
|
372
380
|
if (muted !== undefined) {
|
|
373
381
|
this.state.server.remoteMute = muted;
|
|
374
|
-
this.
|
|
382
|
+
this.muteLocalStream(meeting, muted, 'remotelyMuted');
|
|
375
383
|
}
|
|
376
384
|
}
|
|
377
385
|
|
|
@@ -383,7 +391,7 @@ export class MuteState {
|
|
|
383
391
|
* @param {Object} [meeting] the meeting object
|
|
384
392
|
* @returns {undefined}
|
|
385
393
|
*/
|
|
386
|
-
public handleServerLocalUnmuteRequired(meeting?:
|
|
394
|
+
public handleServerLocalUnmuteRequired(meeting?: any) {
|
|
387
395
|
if (!this.state.client.enabled) {
|
|
388
396
|
LoggerProxy.logger.warn(
|
|
389
397
|
`Meeting:muteState#handleServerLocalUnmuteRequired --> ${this.type}: localAudioUnmuteRequired received while ${this.type} is disabled -> local unmute will not result in ${this.type} being sent`
|
|
@@ -396,9 +404,15 @@ export class MuteState {
|
|
|
396
404
|
|
|
397
405
|
// todo: I'm seeing "you can now unmute yourself " popup when this happens - but same thing happens on web.w.c so we can ignore for now
|
|
398
406
|
this.state.server.remoteMute = false;
|
|
399
|
-
this.state.client.localMute = false;
|
|
400
407
|
|
|
401
|
-
|
|
408
|
+
// change user mute state to false, but keep localMute true if overall mute state is still true
|
|
409
|
+
this.muteLocalStream(meeting, false, 'localUnmuteRequired');
|
|
410
|
+
if (this.type === AUDIO) {
|
|
411
|
+
this.state.client.localMute = meeting.mediaProperties.audioStream?.muted;
|
|
412
|
+
} else {
|
|
413
|
+
this.state.client.localMute = meeting.mediaProperties.videoStream?.muted;
|
|
414
|
+
}
|
|
415
|
+
|
|
402
416
|
this.applyClientStateToServer(meeting);
|
|
403
417
|
}
|
|
404
418
|
|
package/src/meeting/request.ts
CHANGED
|
@@ -4,6 +4,7 @@ import {debounce} from 'lodash';
|
|
|
4
4
|
import {StatelessWebexPlugin} from '@webex/webex-core';
|
|
5
5
|
// @ts-ignore
|
|
6
6
|
import {deviceType} from '@webex/common';
|
|
7
|
+
import {CallDiagnosticUtils} from '@webex/internal-plugin-metrics';
|
|
7
8
|
|
|
8
9
|
import LoggerProxy from '../common/logs/logger-proxy';
|
|
9
10
|
import {
|
|
@@ -184,6 +185,13 @@ export default class MeetingRequest extends StatelessWebexPlugin {
|
|
|
184
185
|
deviceCapabilities.push(ANNOTATION.ANNOTATION_ON_SHARE_SUPPORTED);
|
|
185
186
|
}
|
|
186
187
|
|
|
188
|
+
// append installationId to device config if it exists
|
|
189
|
+
// @ts-ignore
|
|
190
|
+
if (this.webex.internal.device.config.installationId) {
|
|
191
|
+
// @ts-ignore
|
|
192
|
+
body.device.installationId = this.webex.internal.device.config.installationId;
|
|
193
|
+
}
|
|
194
|
+
|
|
187
195
|
if (locale) {
|
|
188
196
|
body.locale = locale;
|
|
189
197
|
}
|
|
@@ -198,6 +206,10 @@ export default class MeetingRequest extends StatelessWebexPlugin {
|
|
|
198
206
|
body.device.countryCode = this.webex.meetings.geoHintInfo.countryCode;
|
|
199
207
|
// @ts-ignore
|
|
200
208
|
body.device.regionCode = this.webex.meetings.geoHintInfo.regionCode;
|
|
209
|
+
body.device.localIp =
|
|
210
|
+
// @ts-ignore
|
|
211
|
+
CallDiagnosticUtils.anonymizeIPAddress(this.webex.meetings.geoHintInfo.clientAddress) ||
|
|
212
|
+
undefined;
|
|
201
213
|
}
|
|
202
214
|
|
|
203
215
|
if (moderator !== undefined) {
|
|
@@ -416,7 +428,7 @@ export default class MeetingRequest extends StatelessWebexPlugin {
|
|
|
416
428
|
`Meeting:request#getLocusDTO --> Error getting latest locus, error ${err}`
|
|
417
429
|
);
|
|
418
430
|
|
|
419
|
-
|
|
431
|
+
throw err;
|
|
420
432
|
});
|
|
421
433
|
}
|
|
422
434
|
|
|
@@ -641,6 +653,7 @@ export default class MeetingRequest extends StatelessWebexPlugin {
|
|
|
641
653
|
* @param {String} options.deviceUrl Url of a device
|
|
642
654
|
* @param {String} options.resourceId Populated if you are paired to a device
|
|
643
655
|
* @param {String} options.uri floor grant uri
|
|
656
|
+
* @param {String} options.shareInstanceId id for current share
|
|
644
657
|
* @returns {Promise}
|
|
645
658
|
*/
|
|
646
659
|
changeMeetingFloor(
|
|
@@ -652,6 +665,7 @@ export default class MeetingRequest extends StatelessWebexPlugin {
|
|
|
652
665
|
resourceId: string;
|
|
653
666
|
uri: string;
|
|
654
667
|
annotationInfo: AnnotationInfo;
|
|
668
|
+
shareInstanceId: string;
|
|
655
669
|
}
|
|
656
670
|
| any
|
|
657
671
|
) {
|
|
@@ -682,6 +696,10 @@ export default class MeetingRequest extends StatelessWebexPlugin {
|
|
|
682
696
|
resourceUrl: options.resourceUrl,
|
|
683
697
|
};
|
|
684
698
|
|
|
699
|
+
if (options?.shareInstanceId) {
|
|
700
|
+
body.floor.shareInstanceId = options.shareInstanceId;
|
|
701
|
+
}
|
|
702
|
+
|
|
685
703
|
if (options?.resourceToken) {
|
|
686
704
|
body.resourceToken = options?.resourceToken;
|
|
687
705
|
}
|
package/src/meeting/util.ts
CHANGED
|
@@ -13,6 +13,7 @@ import {
|
|
|
13
13
|
FULL_STATE,
|
|
14
14
|
SELF_POLICY,
|
|
15
15
|
EVENT_TRIGGERS,
|
|
16
|
+
LOCAL_SHARE_ERRORS,
|
|
16
17
|
IP_VERSION,
|
|
17
18
|
} from '../constants';
|
|
18
19
|
import BrowserDetection from '../common/browser-detection';
|
|
@@ -692,6 +693,102 @@ const MeetingUtil = {
|
|
|
692
693
|
EVENT_TRIGGERS.MEETING_INTERPRETATION_UPDATE
|
|
693
694
|
);
|
|
694
695
|
},
|
|
696
|
+
|
|
697
|
+
/**
|
|
698
|
+
* Returns a CA-recognized error payload for the specified raw error message/reason.
|
|
699
|
+
*
|
|
700
|
+
* New errors can be added to this function for handling in the future
|
|
701
|
+
*
|
|
702
|
+
* @param {String} reason the raw error message
|
|
703
|
+
* @returns {Array<object>} an array of payload objects
|
|
704
|
+
*/
|
|
705
|
+
getChangeMeetingFloorErrorPayload: (reason: string) => {
|
|
706
|
+
const errorPayload = {
|
|
707
|
+
errorDescription: reason,
|
|
708
|
+
name: 'locus.response',
|
|
709
|
+
shownToUser: false,
|
|
710
|
+
};
|
|
711
|
+
if (reason.includes(LOCAL_SHARE_ERRORS.UNDEFINED)) {
|
|
712
|
+
return [
|
|
713
|
+
{
|
|
714
|
+
...errorPayload,
|
|
715
|
+
fatal: true,
|
|
716
|
+
category: 'signaling',
|
|
717
|
+
errorCode: 1100,
|
|
718
|
+
},
|
|
719
|
+
];
|
|
720
|
+
}
|
|
721
|
+
if (reason.includes(LOCAL_SHARE_ERRORS.DEVICE_NOT_JOINED)) {
|
|
722
|
+
return [
|
|
723
|
+
{
|
|
724
|
+
...errorPayload,
|
|
725
|
+
fatal: true,
|
|
726
|
+
category: 'signaling',
|
|
727
|
+
errorCode: 4050,
|
|
728
|
+
},
|
|
729
|
+
];
|
|
730
|
+
}
|
|
731
|
+
if (reason.includes(LOCAL_SHARE_ERRORS.NO_MEDIA_FOR_DEVICE)) {
|
|
732
|
+
return [
|
|
733
|
+
{
|
|
734
|
+
...errorPayload,
|
|
735
|
+
fatal: true,
|
|
736
|
+
category: 'media',
|
|
737
|
+
errorCode: 2048,
|
|
738
|
+
},
|
|
739
|
+
];
|
|
740
|
+
}
|
|
741
|
+
if (reason.includes(LOCAL_SHARE_ERRORS.NO_CONFLUENCE_ID)) {
|
|
742
|
+
return [
|
|
743
|
+
{
|
|
744
|
+
...errorPayload,
|
|
745
|
+
fatal: true,
|
|
746
|
+
category: 'signaling',
|
|
747
|
+
errorCode: 4064,
|
|
748
|
+
},
|
|
749
|
+
];
|
|
750
|
+
}
|
|
751
|
+
if (reason.includes(LOCAL_SHARE_ERRORS.CONTENT_SHARING_DISABLED)) {
|
|
752
|
+
return [
|
|
753
|
+
{
|
|
754
|
+
...errorPayload,
|
|
755
|
+
fatal: true,
|
|
756
|
+
category: 'expected',
|
|
757
|
+
errorCode: 4065,
|
|
758
|
+
},
|
|
759
|
+
];
|
|
760
|
+
}
|
|
761
|
+
if (reason.includes(LOCAL_SHARE_ERRORS.LOCUS_PARTICIPANT_DNE)) {
|
|
762
|
+
return [
|
|
763
|
+
{
|
|
764
|
+
...errorPayload,
|
|
765
|
+
fatal: true,
|
|
766
|
+
category: 'signaling',
|
|
767
|
+
errorCode: 4066,
|
|
768
|
+
},
|
|
769
|
+
];
|
|
770
|
+
}
|
|
771
|
+
if (reason.includes(LOCAL_SHARE_ERRORS.CONTENT_REQUEST_WHILE_PENDING_WHITEBOARD)) {
|
|
772
|
+
return [
|
|
773
|
+
{
|
|
774
|
+
...errorPayload,
|
|
775
|
+
fatal: true,
|
|
776
|
+
category: 'expected',
|
|
777
|
+
errorCode: 4067,
|
|
778
|
+
},
|
|
779
|
+
];
|
|
780
|
+
}
|
|
781
|
+
|
|
782
|
+
// return unknown error
|
|
783
|
+
return [
|
|
784
|
+
{
|
|
785
|
+
...errorPayload,
|
|
786
|
+
fatal: true,
|
|
787
|
+
category: 'signaling',
|
|
788
|
+
errorCode: 1100,
|
|
789
|
+
},
|
|
790
|
+
];
|
|
791
|
+
},
|
|
695
792
|
};
|
|
696
793
|
|
|
697
794
|
export default MeetingUtil;
|
|
@@ -71,20 +71,39 @@ export default class MeetingInfo {
|
|
|
71
71
|
* @memberof MeetingInfo
|
|
72
72
|
*/
|
|
73
73
|
private requestFetchInfo(options: any) {
|
|
74
|
-
const {meetingId} = options;
|
|
75
|
-
if (meetingId) {
|
|
74
|
+
const {meetingId, sendCAevents} = options;
|
|
75
|
+
if (meetingId && sendCAevents) {
|
|
76
76
|
this.webex.internal.newMetrics.submitInternalEvent({
|
|
77
77
|
name: 'internal.client.meetinginfo.request',
|
|
78
78
|
});
|
|
79
|
+
this.webex.internal.newMetrics.submitClientEvent({
|
|
80
|
+
name: 'client.meetinginfo.request',
|
|
81
|
+
options: {
|
|
82
|
+
meetingId,
|
|
83
|
+
},
|
|
84
|
+
});
|
|
79
85
|
}
|
|
80
86
|
|
|
81
87
|
return this.meetingInfoRequest
|
|
82
88
|
.fetchMeetingInfo(options)
|
|
83
89
|
.then((info) => {
|
|
84
|
-
if (meetingId) {
|
|
90
|
+
if (meetingId && sendCAevents) {
|
|
85
91
|
this.webex.internal.newMetrics.submitInternalEvent({
|
|
86
92
|
name: 'internal.client.meetinginfo.response',
|
|
87
93
|
});
|
|
94
|
+
this.webex.internal.newMetrics.submitClientEvent({
|
|
95
|
+
name: 'client.meetinginfo.response',
|
|
96
|
+
payload: {
|
|
97
|
+
identifiers: {
|
|
98
|
+
meetingLookupUrl: info?.url,
|
|
99
|
+
},
|
|
100
|
+
},
|
|
101
|
+
options: {
|
|
102
|
+
meetingId,
|
|
103
|
+
webexConferenceIdStr: info?.body?.confIdStr || info?.body?.confID,
|
|
104
|
+
globalMeetingId: info?.body?.meetingId,
|
|
105
|
+
},
|
|
106
|
+
});
|
|
88
107
|
}
|
|
89
108
|
if (info && info.body) {
|
|
90
109
|
this.setMeetingInfo(info.body.sipMeetingUri || info.body.meetingLink, info.body);
|
|
@@ -96,21 +115,23 @@ export default class MeetingInfo {
|
|
|
96
115
|
LoggerProxy.logger.error(
|
|
97
116
|
`Meeting-info:index#requestFetchInfo --> ${error} fetch meetingInfo`
|
|
98
117
|
);
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
118
|
+
if (meetingId && sendCAevents) {
|
|
119
|
+
this.webex.internal.newMetrics.submitInternalEvent({
|
|
120
|
+
name: 'internal.client.meetinginfo.response',
|
|
121
|
+
});
|
|
122
|
+
this.webex.internal.newMetrics.submitClientEvent({
|
|
123
|
+
name: 'client.meetinginfo.response',
|
|
124
|
+
payload: {
|
|
125
|
+
identifiers: {
|
|
126
|
+
meetingLookupUrl: error?.url,
|
|
127
|
+
},
|
|
128
|
+
},
|
|
129
|
+
options: {
|
|
130
|
+
meetingId,
|
|
131
|
+
rawError: error,
|
|
107
132
|
},
|
|
108
|
-
}
|
|
109
|
-
|
|
110
|
-
meetingId,
|
|
111
|
-
rawError: error,
|
|
112
|
-
},
|
|
113
|
-
});
|
|
133
|
+
});
|
|
134
|
+
}
|
|
114
135
|
|
|
115
136
|
return Promise.reject(error);
|
|
116
137
|
});
|
|
@@ -137,6 +158,12 @@ export default class MeetingInfo {
|
|
|
137
158
|
* Fetches meeting info from the server
|
|
138
159
|
* @param {String} destination one of many different types of destinations to look up info for
|
|
139
160
|
* @param {String} [type] to match up with the destination value
|
|
161
|
+
* @param {String} [password] meeting password
|
|
162
|
+
* @param {Object} [captchaInfo] captcha code and id
|
|
163
|
+
* @param {String} [installedOrgID]
|
|
164
|
+
* @param {String} [locusId]
|
|
165
|
+
* @param {Object} [extraParams]
|
|
166
|
+
* @param {Boolean} [options] meeting Id and whether Call Analyzer events should be sent
|
|
140
167
|
* @returns {Promise} returns a meeting info object
|
|
141
168
|
* @public
|
|
142
169
|
* @memberof MeetingInfo
|
|
@@ -157,7 +184,7 @@ export default class MeetingInfo {
|
|
|
157
184
|
locusId = null,
|
|
158
185
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
159
186
|
extraParams: object = {},
|
|
160
|
-
options: {meetingId?: string} = {}
|
|
187
|
+
options: {meetingId?: string; sendCAevents?: boolean} = {}
|
|
161
188
|
) {
|
|
162
189
|
if (type === _PERSONAL_ROOM_ && !destination) {
|
|
163
190
|
destination = this.webex.internal.device.userId;
|
|
@@ -166,13 +193,13 @@ export default class MeetingInfo {
|
|
|
166
193
|
return this.fetchInfoOptions(MeetingInfoUtil.extractDestination(destination, type), type).then(
|
|
167
194
|
(infoOptions) =>
|
|
168
195
|
// fetch meeting info
|
|
169
|
-
this.requestFetchInfo({...infoOptions,
|
|
196
|
+
this.requestFetchInfo({...infoOptions, ...options}).catch((error) => {
|
|
170
197
|
// if it failed the first time as meeting link
|
|
171
198
|
if (infoOptions.type === _MEETING_LINK_) {
|
|
172
199
|
// convert the meeting link to sip URI and retry
|
|
173
200
|
return this.requestFetchInfo({
|
|
174
201
|
...this.fetchInfoOptions(MeetingInfoUtil.convertLinkToSip(destination), _SIP_URI_),
|
|
175
|
-
|
|
202
|
+
...options,
|
|
176
203
|
});
|
|
177
204
|
}
|
|
178
205
|
|
|
@@ -279,9 +279,9 @@ export default class MeetingInfoV2 {
|
|
|
279
279
|
installedOrgID = null,
|
|
280
280
|
locusId = null,
|
|
281
281
|
extraParams: object = {},
|
|
282
|
-
options: {meetingId?: string} = {}
|
|
282
|
+
options: {meetingId?: string; sendCAevents?: boolean} = {}
|
|
283
283
|
) {
|
|
284
|
-
const {meetingId} = options;
|
|
284
|
+
const {meetingId, sendCAevents} = options;
|
|
285
285
|
|
|
286
286
|
const destinationType = await MeetingInfoUtil.getDestinationType({
|
|
287
287
|
destination,
|
|
@@ -336,29 +336,51 @@ export default class MeetingInfoV2 {
|
|
|
336
336
|
requestOptions.resource = 'meetingInfo';
|
|
337
337
|
}
|
|
338
338
|
|
|
339
|
-
if (meetingId) {
|
|
339
|
+
if (meetingId && sendCAevents) {
|
|
340
340
|
this.webex.internal.newMetrics.submitInternalEvent({
|
|
341
341
|
name: 'internal.client.meetinginfo.request',
|
|
342
342
|
});
|
|
343
|
+
|
|
344
|
+
this.webex.internal.newMetrics.submitClientEvent({
|
|
345
|
+
name: 'client.meetinginfo.request',
|
|
346
|
+
options: {
|
|
347
|
+
meetingId,
|
|
348
|
+
},
|
|
349
|
+
});
|
|
343
350
|
}
|
|
344
351
|
|
|
345
352
|
return this.webex
|
|
346
353
|
.request(requestOptions)
|
|
347
354
|
.then((response) => {
|
|
348
|
-
if (meetingId) {
|
|
355
|
+
if (meetingId && sendCAevents) {
|
|
349
356
|
this.webex.internal.newMetrics.submitInternalEvent({
|
|
350
357
|
name: 'internal.client.meetinginfo.response',
|
|
351
358
|
});
|
|
359
|
+
|
|
360
|
+
this.webex.internal.newMetrics.submitClientEvent({
|
|
361
|
+
name: 'client.meetinginfo.response',
|
|
362
|
+
payload: {
|
|
363
|
+
identifiers: {
|
|
364
|
+
meetingLookupUrl: response?.url,
|
|
365
|
+
},
|
|
366
|
+
},
|
|
367
|
+
options: {
|
|
368
|
+
meetingId,
|
|
369
|
+
webexConferenceIdStr: response?.body?.confIdStr || response?.body?.confID,
|
|
370
|
+
globalMeetingId: response?.body?.meetingId,
|
|
371
|
+
},
|
|
372
|
+
});
|
|
352
373
|
}
|
|
353
374
|
Metrics.sendBehavioralMetric(BEHAVIORAL_METRICS.FETCH_MEETING_INFO_V1_SUCCESS);
|
|
354
375
|
|
|
355
376
|
return response;
|
|
356
377
|
})
|
|
357
378
|
.catch((err) => {
|
|
358
|
-
if (meetingId) {
|
|
379
|
+
if (meetingId && sendCAevents) {
|
|
359
380
|
this.webex.internal.newMetrics.submitInternalEvent({
|
|
360
381
|
name: 'internal.client.meetinginfo.response',
|
|
361
382
|
});
|
|
383
|
+
|
|
362
384
|
this.webex.internal.newMetrics.submitClientEvent({
|
|
363
385
|
name: 'client.meetinginfo.response',
|
|
364
386
|
payload: {
|
|
@@ -195,7 +195,7 @@ MeetingInfoUtil.getDestinationType = async (from) => {
|
|
|
195
195
|
});
|
|
196
196
|
} else if (hydraId.room) {
|
|
197
197
|
LoggerProxy.logger.error(
|
|
198
|
-
`Meeting-info:util#getDestinationType --> Using the space ID as a destination is no longer supported. Please refer to the [migration guide](https://github.com/webex/webex-js-sdk/wiki/Migration-
|
|
198
|
+
`Meeting-info:util#getDestinationType --> Using the space ID as a destination is no longer supported. Please refer to the [migration guide](https://github.com/webex/webex-js-sdk/wiki/Migration-to-Unified-Space-Meetings) to migrate to use the meeting ID or SIP address.`
|
|
199
199
|
);
|
|
200
200
|
// Error code 30105 added as Space ID deprecated as of beta, Please refer migration guide.
|
|
201
201
|
throw new SpaceIDDeprecatedError();
|
|
@@ -60,4 +60,17 @@ export default class MeetingCollection extends Collection {
|
|
|
60
60
|
|
|
61
61
|
return null;
|
|
62
62
|
}
|
|
63
|
+
|
|
64
|
+
/**
|
|
65
|
+
* Gets the meeting that has a webrtc media connection
|
|
66
|
+
* NOTE: this function assumes there is no more than 1 such meeting
|
|
67
|
+
*
|
|
68
|
+
* @returns {Meeting} first meeting found, else undefined
|
|
69
|
+
* @public
|
|
70
|
+
* @memberof MeetingCollection
|
|
71
|
+
*/
|
|
72
|
+
public getActiveWebrtcMeeting() {
|
|
73
|
+
// @ts-ignore
|
|
74
|
+
return find(this.meetings, (meeting) => meeting.mediaProperties.webrtcMediaConnection);
|
|
75
|
+
}
|
|
63
76
|
}
|