@webex/plugin-meetings 3.0.0-next.10 → 3.0.0-next.12
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/dist/breakouts/breakout.js +1 -1
- package/dist/breakouts/index.js +1 -1
- package/dist/constants.d.ts +1 -2
- package/dist/constants.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +6 -0
- package/dist/index.js.map +1 -1
- package/dist/interpretation/index.js +3 -3
- package/dist/interpretation/index.js.map +1 -1
- package/dist/interpretation/siLanguage.js +1 -1
- package/dist/locus-info/mediaSharesUtils.js +15 -1
- package/dist/locus-info/mediaSharesUtils.js.map +1 -1
- package/dist/media/index.js +4 -1
- package/dist/media/index.js.map +1 -1
- package/dist/meeting/index.d.ts +15 -5
- package/dist/meeting/index.js +702 -561
- package/dist/meeting/index.js.map +1 -1
- package/dist/meeting/muteState.d.ts +2 -8
- package/dist/meeting/muteState.js +37 -25
- package/dist/meeting/muteState.js.map +1 -1
- package/dist/meeting/request.d.ts +3 -0
- package/dist/meeting/request.js +32 -23
- package/dist/meeting/request.js.map +1 -1
- package/dist/meeting/util.js +1 -0
- package/dist/meeting/util.js.map +1 -1
- package/dist/multistream/mediaRequestManager.d.ts +1 -2
- package/dist/multistream/mediaRequestManager.js.map +1 -1
- package/dist/multistream/remoteMediaGroup.d.ts +1 -1
- package/dist/multistream/remoteMediaGroup.js.map +1 -1
- package/dist/multistream/remoteMediaManager.d.ts +1 -2
- package/dist/multistream/remoteMediaManager.js.map +1 -1
- package/dist/multistream/sendSlotManager.d.ts +1 -2
- package/dist/multistream/sendSlotManager.js.map +1 -1
- package/dist/reconnection-manager/index.js +2 -1
- package/dist/reconnection-manager/index.js.map +1 -1
- package/dist/roap/index.d.ts +10 -2
- package/dist/roap/index.js +15 -0
- package/dist/roap/index.js.map +1 -1
- package/dist/roap/turnDiscovery.d.ts +64 -17
- package/dist/roap/turnDiscovery.js +307 -126
- package/dist/roap/turnDiscovery.js.map +1 -1
- package/dist/webinar/index.js +1 -1
- package/package.json +22 -22
- package/src/constants.ts +1 -1
- package/src/index.ts +1 -0
- package/src/interpretation/index.ts +2 -2
- package/src/locus-info/mediaSharesUtils.ts +16 -0
- package/src/media/index.ts +3 -1
- package/src/meeting/index.ts +220 -82
- package/src/meeting/muteState.ts +34 -20
- package/src/meeting/request.ts +18 -2
- package/src/meeting/util.ts +1 -0
- package/src/multistream/mediaRequestManager.ts +1 -1
- package/src/multistream/remoteMediaGroup.ts +1 -1
- package/src/multistream/remoteMediaManager.ts +1 -2
- package/src/multistream/sendSlotManager.ts +1 -2
- package/src/reconnection-manager/index.ts +1 -1
- package/src/roap/index.ts +25 -3
- package/src/roap/turnDiscovery.ts +244 -78
- package/test/integration/spec/journey.js +13 -13
- package/test/unit/spec/interpretation/index.ts +4 -1
- package/test/unit/spec/locus-info/mediaSharesUtils.ts +9 -0
- package/test/unit/spec/media/index.ts +89 -78
- package/test/unit/spec/meeting/index.js +460 -75
- package/test/unit/spec/meeting/muteState.js +219 -67
- package/test/unit/spec/meeting/request.js +21 -0
- package/test/unit/spec/meeting/utils.js +6 -1
- package/test/unit/spec/multistream/remoteMediaGroup.ts +0 -1
- package/test/unit/spec/multistream/remoteMediaManager.ts +0 -1
- package/test/unit/spec/reconnection-manager/index.js +28 -0
- package/test/unit/spec/roap/index.ts +61 -6
- package/test/unit/spec/roap/turnDiscovery.ts +298 -16
package/dist/meeting/index.js
CHANGED
|
@@ -69,7 +69,6 @@ var _constants = require("../constants");
|
|
|
69
69
|
var _constants2 = _interopRequireDefault(require("../metrics/constants"));
|
|
70
70
|
var _parameter = _interopRequireDefault(require("../common/errors/parameter"));
|
|
71
71
|
var _meetingInfoV = require("../meeting-info/meeting-info-v2");
|
|
72
|
-
var _browserDetection = _interopRequireDefault(require("../common/browser-detection"));
|
|
73
72
|
var _receiveSlotManager = require("../multistream/receiveSlotManager");
|
|
74
73
|
var _sendSlotManager = _interopRequireDefault(require("../multistream/sendSlotManager"));
|
|
75
74
|
var _mediaRequestManager = require("../multistream/mediaRequestManager");
|
|
@@ -92,8 +91,6 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
|
|
|
92
91
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = _Reflect$construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
|
|
93
92
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !_Reflect$construct) return false; if (_Reflect$construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(_Reflect$construct(Boolean, [], function () {})); return true; } catch (e) { return false; } } // @ts-ignore - Fix this
|
|
94
93
|
// @ts-ignore - Types not available for @webex/common
|
|
95
|
-
var _BrowserDetection = (0, _browserDetection.default)(),
|
|
96
|
-
isBrowser = _BrowserDetection.isBrowser;
|
|
97
94
|
var logRequest = function logRequest(request, _ref) {
|
|
98
95
|
var _ref$logText = _ref.logText,
|
|
99
96
|
logText = _ref$logText === void 0 ? '' : _ref$logText;
|
|
@@ -1941,11 +1938,11 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
1941
1938
|
* helper class for managing remote streams
|
|
1942
1939
|
*/
|
|
1943
1940
|
_this.remoteMediaManager = null;
|
|
1944
|
-
_this.localAudioStreamMuteStateHandler = function (
|
|
1945
|
-
_this.audio.handleLocalStreamMuteStateChange((0, _assertThisInitialized2.default)(_this)
|
|
1941
|
+
_this.localAudioStreamMuteStateHandler = function () {
|
|
1942
|
+
_this.audio.handleLocalStreamMuteStateChange((0, _assertThisInitialized2.default)(_this));
|
|
1946
1943
|
};
|
|
1947
|
-
_this.localVideoStreamMuteStateHandler = function (
|
|
1948
|
-
_this.video.handleLocalStreamMuteStateChange((0, _assertThisInitialized2.default)(_this)
|
|
1944
|
+
_this.localVideoStreamMuteStateHandler = function () {
|
|
1945
|
+
_this.video.handleLocalStreamMuteStateChange((0, _assertThisInitialized2.default)(_this));
|
|
1949
1946
|
};
|
|
1950
1947
|
|
|
1951
1948
|
// The handling of output track changes should be done inside
|
|
@@ -3012,7 +3009,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
3012
3009
|
function: 'triggerAnnotationInfoEvent'
|
|
3013
3010
|
}, _constants.EVENT_TRIGGERS.MEETING_UPDATE_ANNOTATION_INFO, {
|
|
3014
3011
|
annotationInfo: contentShare === null || contentShare === void 0 ? void 0 : contentShare.annotation,
|
|
3015
|
-
meetingId: this.id
|
|
3012
|
+
meetingId: this.id,
|
|
3013
|
+
resourceType: contentShare === null || contentShare === void 0 ? void 0 : contentShare.resourceType
|
|
3016
3014
|
});
|
|
3017
3015
|
}
|
|
3018
3016
|
}
|
|
@@ -3041,7 +3039,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
3041
3039
|
previousContentShare = (_payload$previous = payload.previous) === null || _payload$previous === void 0 ? void 0 : _payload$previous.content;
|
|
3042
3040
|
previousWhiteboardShare = (_payload$previous2 = payload.previous) === null || _payload$previous2 === void 0 ? void 0 : _payload$previous2.whiteboard;
|
|
3043
3041
|
_this14.triggerAnnotationInfoEvent(contentShare, previousContentShare);
|
|
3044
|
-
if (!(contentShare.beneficiaryId === (previousContentShare === null || previousContentShare === void 0 ? void 0 : previousContentShare.beneficiaryId) && contentShare.disposition === (previousContentShare === null || previousContentShare === void 0 ? void 0 : previousContentShare.disposition) && contentShare.deviceUrlSharing === previousContentShare.deviceUrlSharing && whiteboardShare.beneficiaryId === (previousWhiteboardShare === null || previousWhiteboardShare === void 0 ? void 0 : previousWhiteboardShare.beneficiaryId) && whiteboardShare.disposition === (previousWhiteboardShare === null || previousWhiteboardShare === void 0 ? void 0 : previousWhiteboardShare.disposition) && whiteboardShare.resourceUrl === (previousWhiteboardShare === null || previousWhiteboardShare === void 0 ? void 0 : previousWhiteboardShare.resourceUrl))) {
|
|
3042
|
+
if (!(contentShare.beneficiaryId === (previousContentShare === null || previousContentShare === void 0 ? void 0 : previousContentShare.beneficiaryId) && contentShare.disposition === (previousContentShare === null || previousContentShare === void 0 ? void 0 : previousContentShare.disposition) && contentShare.deviceUrlSharing === previousContentShare.deviceUrlSharing && whiteboardShare.beneficiaryId === (previousWhiteboardShare === null || previousWhiteboardShare === void 0 ? void 0 : previousWhiteboardShare.beneficiaryId) && whiteboardShare.disposition === (previousWhiteboardShare === null || previousWhiteboardShare === void 0 ? void 0 : previousWhiteboardShare.disposition) && whiteboardShare.resourceUrl === (previousWhiteboardShare === null || previousWhiteboardShare === void 0 ? void 0 : previousWhiteboardShare.resourceUrl) && contentShare.resourceType === (previousContentShare === null || previousContentShare === void 0 ? void 0 : previousContentShare.resourceType))) {
|
|
3045
3043
|
_context8.next = 6;
|
|
3046
3044
|
break;
|
|
3047
3045
|
}
|
|
@@ -3122,7 +3120,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
3122
3120
|
memberId: contentShare.beneficiaryId,
|
|
3123
3121
|
url: contentShare.url,
|
|
3124
3122
|
shareInstanceId: _this14.remoteShareInstanceId,
|
|
3125
|
-
annotationInfo: contentShare.annotation
|
|
3123
|
+
annotationInfo: contentShare.annotation,
|
|
3124
|
+
resourceType: contentShare.resourceType
|
|
3126
3125
|
});
|
|
3127
3126
|
};
|
|
3128
3127
|
_context8.prev = 26;
|
|
@@ -3194,7 +3193,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
3194
3193
|
memberId: contentShare.beneficiaryId,
|
|
3195
3194
|
url: contentShare.url,
|
|
3196
3195
|
shareInstanceId: _this14.remoteShareInstanceId,
|
|
3197
|
-
annotationInfo: contentShare.annotation
|
|
3196
|
+
annotationInfo: contentShare.annotation,
|
|
3197
|
+
resourceType: contentShare.resourceType
|
|
3198
3198
|
});
|
|
3199
3199
|
_this14.members.locusMediaSharesUpdate(payload);
|
|
3200
3200
|
} else if (newShareStatus === _constants.SHARE_STATUS.WHITEBOARD_SHARE_ACTIVE) {
|
|
@@ -3473,7 +3473,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
3473
3473
|
}
|
|
3474
3474
|
});
|
|
3475
3475
|
}
|
|
3476
|
-
|
|
3476
|
+
_this19.updateLLMConnection();
|
|
3477
|
+
case 3:
|
|
3477
3478
|
case "end":
|
|
3478
3479
|
return _context9.stop();
|
|
3479
3480
|
}
|
|
@@ -4236,24 +4237,26 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
4236
4237
|
while (1) switch (_context11.prev = _context11.next) {
|
|
4237
4238
|
case 0:
|
|
4238
4239
|
oldStream = this.mediaProperties.audioStream;
|
|
4239
|
-
oldStream === null || oldStream === void 0 ? void 0 : oldStream.off(_mediaHelpers.
|
|
4240
|
+
oldStream === null || oldStream === void 0 ? void 0 : oldStream.off(_mediaHelpers.LocalStreamEventNames.UserMuteStateChange, this.localAudioStreamMuteStateHandler);
|
|
4241
|
+
oldStream === null || oldStream === void 0 ? void 0 : oldStream.off(_mediaHelpers.LocalStreamEventNames.SystemMuteStateChange, this.localAudioStreamMuteStateHandler);
|
|
4240
4242
|
oldStream === null || oldStream === void 0 ? void 0 : oldStream.off(_mediaHelpers.LocalStreamEventNames.OutputTrackChange, this.localOutputTrackChangeHandler);
|
|
4241
4243
|
|
|
4242
4244
|
// we don't update this.mediaProperties.mediaDirection.sendAudio, because we always keep it as true to avoid extra SDP exchanges
|
|
4243
4245
|
this.mediaProperties.setLocalAudioStream(localStream);
|
|
4244
4246
|
this.audio.handleLocalStreamChange(this);
|
|
4245
|
-
localStream === null || localStream === void 0 ? void 0 : localStream.on(_mediaHelpers.
|
|
4247
|
+
localStream === null || localStream === void 0 ? void 0 : localStream.on(_mediaHelpers.LocalStreamEventNames.UserMuteStateChange, this.localAudioStreamMuteStateHandler);
|
|
4248
|
+
localStream === null || localStream === void 0 ? void 0 : localStream.on(_mediaHelpers.LocalStreamEventNames.SystemMuteStateChange, this.localAudioStreamMuteStateHandler);
|
|
4246
4249
|
localStream === null || localStream === void 0 ? void 0 : localStream.on(_mediaHelpers.LocalStreamEventNames.OutputTrackChange, this.localOutputTrackChangeHandler);
|
|
4247
4250
|
if (!(!this.isMultistream || !localStream)) {
|
|
4248
|
-
_context11.next =
|
|
4251
|
+
_context11.next = 12;
|
|
4249
4252
|
break;
|
|
4250
4253
|
}
|
|
4251
|
-
_context11.next = 10;
|
|
4252
|
-
return this.unpublishStream(_internalMediaCore.MediaType.AudioMain, oldStream);
|
|
4253
|
-
case 10:
|
|
4254
4254
|
_context11.next = 12;
|
|
4255
|
-
return this.
|
|
4255
|
+
return this.unpublishStream(_internalMediaCore.MediaType.AudioMain, oldStream);
|
|
4256
4256
|
case 12:
|
|
4257
|
+
_context11.next = 14;
|
|
4258
|
+
return this.publishStream(_internalMediaCore.MediaType.AudioMain, this.mediaProperties.audioStream);
|
|
4259
|
+
case 14:
|
|
4257
4260
|
case "end":
|
|
4258
4261
|
return _context11.stop();
|
|
4259
4262
|
}
|
|
@@ -4281,24 +4284,26 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
4281
4284
|
while (1) switch (_context12.prev = _context12.next) {
|
|
4282
4285
|
case 0:
|
|
4283
4286
|
oldStream = this.mediaProperties.videoStream;
|
|
4284
|
-
oldStream === null || oldStream === void 0 ? void 0 : oldStream.off(_mediaHelpers.
|
|
4287
|
+
oldStream === null || oldStream === void 0 ? void 0 : oldStream.off(_mediaHelpers.LocalStreamEventNames.UserMuteStateChange, this.localVideoStreamMuteStateHandler);
|
|
4288
|
+
oldStream === null || oldStream === void 0 ? void 0 : oldStream.off(_mediaHelpers.LocalStreamEventNames.SystemMuteStateChange, this.localVideoStreamMuteStateHandler);
|
|
4285
4289
|
oldStream === null || oldStream === void 0 ? void 0 : oldStream.off(_mediaHelpers.LocalStreamEventNames.OutputTrackChange, this.localOutputTrackChangeHandler);
|
|
4286
4290
|
|
|
4287
4291
|
// we don't update this.mediaProperties.mediaDirection.sendVideo, because we always keep it as true to avoid extra SDP exchanges
|
|
4288
4292
|
this.mediaProperties.setLocalVideoStream(localStream);
|
|
4289
4293
|
this.video.handleLocalStreamChange(this);
|
|
4290
|
-
localStream === null || localStream === void 0 ? void 0 : localStream.on(_mediaHelpers.
|
|
4294
|
+
localStream === null || localStream === void 0 ? void 0 : localStream.on(_mediaHelpers.LocalStreamEventNames.UserMuteStateChange, this.localVideoStreamMuteStateHandler);
|
|
4295
|
+
localStream === null || localStream === void 0 ? void 0 : localStream.on(_mediaHelpers.LocalStreamEventNames.SystemMuteStateChange, this.localVideoStreamMuteStateHandler);
|
|
4291
4296
|
localStream === null || localStream === void 0 ? void 0 : localStream.on(_mediaHelpers.LocalStreamEventNames.OutputTrackChange, this.localOutputTrackChangeHandler);
|
|
4292
4297
|
if (!(!this.isMultistream || !localStream)) {
|
|
4293
|
-
_context12.next =
|
|
4298
|
+
_context12.next = 12;
|
|
4294
4299
|
break;
|
|
4295
4300
|
}
|
|
4296
|
-
_context12.next = 10;
|
|
4297
|
-
return this.unpublishStream(_internalMediaCore.MediaType.VideoMain, oldStream);
|
|
4298
|
-
case 10:
|
|
4299
4301
|
_context12.next = 12;
|
|
4300
|
-
return this.
|
|
4302
|
+
return this.unpublishStream(_internalMediaCore.MediaType.VideoMain, oldStream);
|
|
4301
4303
|
case 12:
|
|
4304
|
+
_context12.next = 14;
|
|
4305
|
+
return this.publishStream(_internalMediaCore.MediaType.VideoMain, this.mediaProperties.videoStream);
|
|
4306
|
+
case 14:
|
|
4302
4307
|
case "end":
|
|
4303
4308
|
return _context12.stop();
|
|
4304
4309
|
}
|
|
@@ -4327,11 +4332,11 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
4327
4332
|
while (1) switch (_context13.prev = _context13.next) {
|
|
4328
4333
|
case 0:
|
|
4329
4334
|
oldStream = this.mediaProperties.shareVideoStream;
|
|
4330
|
-
oldStream === null || oldStream === void 0 ? void 0 : oldStream.off(_mediaHelpers.
|
|
4335
|
+
oldStream === null || oldStream === void 0 ? void 0 : oldStream.off(_mediaHelpers.LocalStreamEventNames.SystemMuteStateChange, this.handleShareVideoStreamMuteStateChange);
|
|
4331
4336
|
oldStream === null || oldStream === void 0 ? void 0 : oldStream.off(_mediaHelpers.StreamEventNames.Ended, this.handleShareVideoStreamEnded);
|
|
4332
4337
|
oldStream === null || oldStream === void 0 ? void 0 : oldStream.off(_mediaHelpers.LocalStreamEventNames.OutputTrackChange, this.localOutputTrackChangeHandler);
|
|
4333
4338
|
this.mediaProperties.setLocalShareVideoStream(localDisplayStream);
|
|
4334
|
-
localDisplayStream === null || localDisplayStream === void 0 ? void 0 : localDisplayStream.on(_mediaHelpers.
|
|
4339
|
+
localDisplayStream === null || localDisplayStream === void 0 ? void 0 : localDisplayStream.on(_mediaHelpers.LocalStreamEventNames.SystemMuteStateChange, this.handleShareVideoStreamMuteStateChange);
|
|
4335
4340
|
localDisplayStream === null || localDisplayStream === void 0 ? void 0 : localDisplayStream.on(_mediaHelpers.StreamEventNames.Ended, this.handleShareVideoStreamEnded);
|
|
4336
4341
|
localDisplayStream === null || localDisplayStream === void 0 ? void 0 : localDisplayStream.on(_mediaHelpers.LocalStreamEventNames.OutputTrackChange, this.localOutputTrackChangeHandler);
|
|
4337
4342
|
this.mediaProperties.mediaDirection.sendShare = this.mediaProperties.hasLocalShareStream();
|
|
@@ -4437,13 +4442,15 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
4437
4442
|
videoStream = _this$mediaProperties5.videoStream,
|
|
4438
4443
|
shareAudioStream = _this$mediaProperties5.shareAudioStream,
|
|
4439
4444
|
shareVideoStream = _this$mediaProperties5.shareVideoStream;
|
|
4440
|
-
audioStream === null || audioStream === void 0 ? void 0 : audioStream.off(_mediaHelpers.
|
|
4445
|
+
audioStream === null || audioStream === void 0 ? void 0 : audioStream.off(_mediaHelpers.LocalStreamEventNames.UserMuteStateChange, this.localAudioStreamMuteStateHandler);
|
|
4446
|
+
audioStream === null || audioStream === void 0 ? void 0 : audioStream.off(_mediaHelpers.LocalStreamEventNames.SystemMuteStateChange, this.localAudioStreamMuteStateHandler);
|
|
4441
4447
|
audioStream === null || audioStream === void 0 ? void 0 : audioStream.off(_mediaHelpers.LocalStreamEventNames.OutputTrackChange, this.localOutputTrackChangeHandler);
|
|
4442
|
-
videoStream === null || videoStream === void 0 ? void 0 : videoStream.off(_mediaHelpers.
|
|
4448
|
+
videoStream === null || videoStream === void 0 ? void 0 : videoStream.off(_mediaHelpers.LocalStreamEventNames.UserMuteStateChange, this.localVideoStreamMuteStateHandler);
|
|
4449
|
+
videoStream === null || videoStream === void 0 ? void 0 : videoStream.off(_mediaHelpers.LocalStreamEventNames.SystemMuteStateChange, this.localVideoStreamMuteStateHandler);
|
|
4443
4450
|
videoStream === null || videoStream === void 0 ? void 0 : videoStream.off(_mediaHelpers.LocalStreamEventNames.OutputTrackChange, this.localOutputTrackChangeHandler);
|
|
4444
4451
|
shareAudioStream === null || shareAudioStream === void 0 ? void 0 : shareAudioStream.off(_mediaHelpers.StreamEventNames.Ended, this.handleShareAudioStreamEnded);
|
|
4445
4452
|
shareAudioStream === null || shareAudioStream === void 0 ? void 0 : shareAudioStream.off(_mediaHelpers.LocalStreamEventNames.OutputTrackChange, this.localOutputTrackChangeHandler);
|
|
4446
|
-
shareVideoStream === null || shareVideoStream === void 0 ? void 0 : shareVideoStream.off(_mediaHelpers.
|
|
4453
|
+
shareVideoStream === null || shareVideoStream === void 0 ? void 0 : shareVideoStream.off(_mediaHelpers.LocalStreamEventNames.SystemMuteStateChange, this.handleShareVideoStreamMuteStateChange);
|
|
4447
4454
|
shareVideoStream === null || shareVideoStream === void 0 ? void 0 : shareVideoStream.off(_mediaHelpers.StreamEventNames.Ended, this.handleShareVideoStreamEnded);
|
|
4448
4455
|
shareVideoStream === null || shareVideoStream === void 0 ? void 0 : shareVideoStream.off(_mediaHelpers.LocalStreamEventNames.OutputTrackChange, this.localOutputTrackChangeHandler);
|
|
4449
4456
|
this.mediaProperties.setLocalAudioStream(undefined);
|
|
@@ -4838,36 +4845,123 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
4838
4845
|
*/
|
|
4839
4846
|
}, {
|
|
4840
4847
|
key: "joinWithMedia",
|
|
4841
|
-
value: function
|
|
4842
|
-
var
|
|
4843
|
-
|
|
4844
|
-
|
|
4845
|
-
|
|
4846
|
-
|
|
4847
|
-
|
|
4848
|
+
value: (function () {
|
|
4849
|
+
var _joinWithMedia = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee15() {
|
|
4850
|
+
var options,
|
|
4851
|
+
mediaOptions,
|
|
4852
|
+
_options$joinOptions,
|
|
4853
|
+
joinOptions,
|
|
4854
|
+
joined,
|
|
4855
|
+
turnServerInfo,
|
|
4856
|
+
turnDiscoverySkippedReason,
|
|
4857
|
+
turnDiscoveryRequest,
|
|
4858
|
+
joinResponse,
|
|
4859
|
+
_yield$this$roap$hand,
|
|
4860
|
+
mediaResponse,
|
|
4861
|
+
_this$locusUrl,
|
|
4862
|
+
_leaveError,
|
|
4863
|
+
leaveError,
|
|
4864
|
+
_args15 = arguments;
|
|
4865
|
+
return _regenerator.default.wrap(function _callee15$(_context15) {
|
|
4866
|
+
while (1) switch (_context15.prev = _context15.next) {
|
|
4867
|
+
case 0:
|
|
4868
|
+
options = _args15.length > 0 && _args15[0] !== undefined ? _args15[0] : {};
|
|
4869
|
+
mediaOptions = options.mediaOptions, _options$joinOptions = options.joinOptions, joinOptions = _options$joinOptions === void 0 ? {} : _options$joinOptions;
|
|
4870
|
+
if (mediaOptions !== null && mediaOptions !== void 0 && mediaOptions.allowMediaInLobby) {
|
|
4871
|
+
_context15.next = 4;
|
|
4872
|
+
break;
|
|
4873
|
+
}
|
|
4874
|
+
return _context15.abrupt("return", _promise.default.reject(new _parameter.default('joinWithMedia() can only be used with allowMediaInLobby set to true')));
|
|
4875
|
+
case 4:
|
|
4876
|
+
this.allowMediaInLobby = true;
|
|
4877
|
+
_loggerProxy.default.logger.info('Meeting:index#joinWithMedia called');
|
|
4878
|
+
joined = false;
|
|
4879
|
+
_context15.prev = 7;
|
|
4880
|
+
_context15.next = 10;
|
|
4881
|
+
return this.webex.meetings.reachability.getReachabilityResults();
|
|
4882
|
+
case 10:
|
|
4883
|
+
joinOptions.reachability = _context15.sent;
|
|
4884
|
+
_context15.next = 13;
|
|
4885
|
+
return this.roap.generateTurnDiscoveryRequestMessage(this, true);
|
|
4886
|
+
case 13:
|
|
4887
|
+
turnDiscoveryRequest = _context15.sent;
|
|
4888
|
+
turnDiscoverySkippedReason = turnDiscoveryRequest.turnDiscoverySkippedReason;
|
|
4889
|
+
joinOptions.roapMessage = turnDiscoveryRequest.roapMessage;
|
|
4890
|
+
_context15.next = 18;
|
|
4891
|
+
return this.join(joinOptions);
|
|
4892
|
+
case 18:
|
|
4893
|
+
joinResponse = _context15.sent;
|
|
4894
|
+
joined = true;
|
|
4895
|
+
if (!joinOptions.roapMessage) {
|
|
4896
|
+
_context15.next = 29;
|
|
4897
|
+
break;
|
|
4898
|
+
}
|
|
4899
|
+
_context15.next = 23;
|
|
4900
|
+
return this.roap.handleTurnDiscoveryHttpResponse(this, joinResponse);
|
|
4901
|
+
case 23:
|
|
4902
|
+
_yield$this$roap$hand = _context15.sent;
|
|
4903
|
+
turnServerInfo = _yield$this$roap$hand.turnServerInfo;
|
|
4904
|
+
turnDiscoverySkippedReason = _yield$this$roap$hand.turnDiscoverySkippedReason;
|
|
4905
|
+
this.turnDiscoverySkippedReason = turnDiscoverySkippedReason;
|
|
4906
|
+
this.turnServerUsed = !!turnServerInfo;
|
|
4907
|
+
if (turnServerInfo === undefined) {
|
|
4908
|
+
this.roap.abortTurnDiscovery();
|
|
4909
|
+
}
|
|
4910
|
+
case 29:
|
|
4911
|
+
_context15.next = 31;
|
|
4912
|
+
return this.addMedia(mediaOptions, turnServerInfo);
|
|
4913
|
+
case 31:
|
|
4914
|
+
mediaResponse = _context15.sent;
|
|
4915
|
+
return _context15.abrupt("return", {
|
|
4916
|
+
join: joinResponse,
|
|
4917
|
+
media: mediaResponse
|
|
4918
|
+
});
|
|
4919
|
+
case 35:
|
|
4920
|
+
_context15.prev = 35;
|
|
4921
|
+
_context15.t0 = _context15["catch"](7);
|
|
4922
|
+
_loggerProxy.default.logger.error('Meeting:index#joinWithMedia --> ', _context15.t0);
|
|
4923
|
+
this.roap.abortTurnDiscovery();
|
|
4924
|
+
if (!joined) {
|
|
4925
|
+
_context15.next = 49;
|
|
4926
|
+
break;
|
|
4927
|
+
}
|
|
4928
|
+
_context15.prev = 40;
|
|
4929
|
+
_context15.next = 43;
|
|
4930
|
+
return this.leave({
|
|
4931
|
+
resourceId: joinOptions === null || joinOptions === void 0 ? void 0 : joinOptions.resourceId,
|
|
4932
|
+
reason: 'joinWithMedia failure'
|
|
4933
|
+
});
|
|
4934
|
+
case 43:
|
|
4935
|
+
_context15.next = 49;
|
|
4936
|
+
break;
|
|
4937
|
+
case 45:
|
|
4938
|
+
_context15.prev = 45;
|
|
4939
|
+
_context15.t1 = _context15["catch"](40);
|
|
4940
|
+
_loggerProxy.default.logger.error('Meeting:index#joinWithMedia --> leave error', _context15.t1);
|
|
4941
|
+
leaveError = _context15.t1;
|
|
4942
|
+
case 49:
|
|
4943
|
+
_metrics.default.sendBehavioralMetric(_constants2.default.JOIN_WITH_MEDIA_FAILURE, {
|
|
4944
|
+
correlation_id: this.correlationId,
|
|
4945
|
+
locus_id: (_this$locusUrl = this.locusUrl) === null || _this$locusUrl === void 0 ? void 0 : _this$locusUrl.split('/').pop(),
|
|
4946
|
+
// if join fails, we may end up with no locusUrl
|
|
4947
|
+
reason: _context15.t0.message,
|
|
4948
|
+
stack: _context15.t0.stack,
|
|
4949
|
+
leaveErrorReason: (_leaveError = leaveError) === null || _leaveError === void 0 ? void 0 : _leaveError.message
|
|
4950
|
+
}, {
|
|
4951
|
+
type: _context15.t0.name
|
|
4952
|
+
});
|
|
4953
|
+
throw _context15.t0;
|
|
4954
|
+
case 51:
|
|
4955
|
+
case "end":
|
|
4956
|
+
return _context15.stop();
|
|
4957
|
+
}
|
|
4958
|
+
}, _callee15, this, [[7, 35], [40, 45]]);
|
|
4959
|
+
}));
|
|
4960
|
+
function joinWithMedia() {
|
|
4961
|
+
return _joinWithMedia.apply(this, arguments);
|
|
4848
4962
|
}
|
|
4849
|
-
|
|
4850
|
-
|
|
4851
|
-
return _this28.addMedia(mediaOptions).then(function (mediaResponse) {
|
|
4852
|
-
return {
|
|
4853
|
-
join: joinResponse,
|
|
4854
|
-
media: mediaResponse
|
|
4855
|
-
};
|
|
4856
|
-
});
|
|
4857
|
-
}).catch(function (error) {
|
|
4858
|
-
_loggerProxy.default.logger.error('Meeting:index#joinWithMedia --> ', error);
|
|
4859
|
-
_metrics.default.sendBehavioralMetric(_constants2.default.JOIN_WITH_MEDIA_FAILURE, {
|
|
4860
|
-
correlation_id: _this28.correlationId,
|
|
4861
|
-
locus_id: _this28.locusUrl.split('/').pop(),
|
|
4862
|
-
reason: error.message,
|
|
4863
|
-
stack: error.stack
|
|
4864
|
-
}, {
|
|
4865
|
-
type: error.name
|
|
4866
|
-
});
|
|
4867
|
-
return _promise.default.reject(error);
|
|
4868
|
-
});
|
|
4869
|
-
}
|
|
4870
|
-
|
|
4963
|
+
return joinWithMedia;
|
|
4964
|
+
}()
|
|
4871
4965
|
/**
|
|
4872
4966
|
* Initiates the reconnection of the media in the meeting
|
|
4873
4967
|
*
|
|
@@ -4876,10 +4970,11 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
4876
4970
|
* @public
|
|
4877
4971
|
* @memberof Meeting
|
|
4878
4972
|
*/
|
|
4973
|
+
)
|
|
4879
4974
|
}, {
|
|
4880
4975
|
key: "reconnect",
|
|
4881
4976
|
value: function reconnect(options) {
|
|
4882
|
-
var
|
|
4977
|
+
var _this28 = this;
|
|
4883
4978
|
_loggerProxy.default.logger.log("Meeting:index#reconnect --> attempting to reconnect meeting ".concat(this.id));
|
|
4884
4979
|
if (!this.reconnectionManager || !this.reconnectionManager.reconnect) {
|
|
4885
4980
|
return _promise.default.reject(new _parameter.default('Cannot reconnect, ReconnectionManager must first be defined.'));
|
|
@@ -4907,29 +5002,29 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
4907
5002
|
function: 'reconnect'
|
|
4908
5003
|
}, _constants.EVENT_TRIGGERS.MEETING_RECONNECTION_STARTING);
|
|
4909
5004
|
return this.reconnectionManager.reconnect(options).then(function () {
|
|
4910
|
-
return
|
|
5005
|
+
return _this28.waitForRemoteSDPAnswer();
|
|
4911
5006
|
}).then(function () {
|
|
4912
|
-
return
|
|
5007
|
+
return _this28.waitForMediaConnectionConnected();
|
|
4913
5008
|
}).then(function () {
|
|
4914
|
-
_triggerProxy.default.trigger(
|
|
5009
|
+
_triggerProxy.default.trigger(_this28, {
|
|
4915
5010
|
file: 'meeting/index',
|
|
4916
5011
|
function: 'reconnect'
|
|
4917
5012
|
}, _constants.EVENT_TRIGGERS.MEETING_RECONNECTION_SUCCESS);
|
|
4918
5013
|
_loggerProxy.default.logger.log('Meeting:index#reconnect --> Meeting reconnect success');
|
|
4919
5014
|
|
|
4920
5015
|
// @ts-ignore
|
|
4921
|
-
|
|
5016
|
+
_this28.webex.internal.newMetrics.submitClientEvent({
|
|
4922
5017
|
name: 'client.media.recovered',
|
|
4923
5018
|
payload: {
|
|
4924
5019
|
recoveredBy: 'new'
|
|
4925
5020
|
},
|
|
4926
5021
|
options: {
|
|
4927
|
-
meetingId:
|
|
5022
|
+
meetingId: _this28.id
|
|
4928
5023
|
}
|
|
4929
5024
|
});
|
|
4930
|
-
|
|
5025
|
+
_this28.reconnectionManager.setStatus(_constants.RECONNECTION.STATE.COMPLETE);
|
|
4931
5026
|
}).catch(function (error) {
|
|
4932
|
-
_triggerProxy.default.trigger(
|
|
5027
|
+
_triggerProxy.default.trigger(_this28, {
|
|
4933
5028
|
file: 'meeting/index',
|
|
4934
5029
|
function: 'reconnect'
|
|
4935
5030
|
}, _constants.EVENT_TRIGGERS.MEETING_RECONNECTION_FAILURE, {
|
|
@@ -4937,18 +5032,18 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
4937
5032
|
});
|
|
4938
5033
|
_loggerProxy.default.logger.error('Meeting:index#reconnect --> Meeting reconnect failed', error);
|
|
4939
5034
|
_metrics.default.sendBehavioralMetric(_constants2.default.MEETING_RECONNECT_FAILURE, {
|
|
4940
|
-
correlation_id:
|
|
4941
|
-
locus_id:
|
|
5035
|
+
correlation_id: _this28.correlationId,
|
|
5036
|
+
locus_id: _this28.locusUrl.split('/').pop(),
|
|
4942
5037
|
reason: error.message,
|
|
4943
5038
|
stack: error.stack
|
|
4944
5039
|
});
|
|
4945
|
-
|
|
5040
|
+
_this28.uploadLogs({
|
|
4946
5041
|
file: 'meeting/index',
|
|
4947
5042
|
function: 'reconnect'
|
|
4948
5043
|
});
|
|
4949
5044
|
return _promise.default.reject(new _reconnection.default('Reconnection failure event', error));
|
|
4950
5045
|
}).finally(function () {
|
|
4951
|
-
|
|
5046
|
+
_this28.reconnectionManager.reset();
|
|
4952
5047
|
});
|
|
4953
5048
|
}
|
|
4954
5049
|
|
|
@@ -4991,19 +5086,19 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
4991
5086
|
}, {
|
|
4992
5087
|
key: "setCaptionLanguage",
|
|
4993
5088
|
value: function setCaptionLanguage(language) {
|
|
4994
|
-
var
|
|
5089
|
+
var _this29 = this;
|
|
4995
5090
|
return new _promise.default(function (resolve, reject) {
|
|
4996
|
-
if (!
|
|
5091
|
+
if (!_this29.isTranscriptionSupported()) {
|
|
4997
5092
|
_loggerProxy.default.logger.error('Meeting:index#setCaptionLanguage --> Webex Assistant is not enabled/supported');
|
|
4998
5093
|
reject(new Error('Webex Assistant is not enabled/supported'));
|
|
4999
5094
|
}
|
|
5000
5095
|
try {
|
|
5001
5096
|
var voiceaListenerCaptionUpdate = function voiceaListenerCaptionUpdate(payload) {
|
|
5002
5097
|
// @ts-ignore
|
|
5003
|
-
|
|
5098
|
+
_this29.webex.internal.voicea.off(_internalPluginVoicea.EVENT_TRIGGERS.CAPTION_LANGUAGE_UPDATE, voiceaListenerCaptionUpdate);
|
|
5004
5099
|
var statusCode = payload.statusCode;
|
|
5005
5100
|
if (statusCode === 200) {
|
|
5006
|
-
|
|
5101
|
+
_this29.transcription.languageOptions = _objectSpread(_objectSpread({}, _this29.transcription.languageOptions), {}, {
|
|
5007
5102
|
currentCaptionLanguage: language
|
|
5008
5103
|
});
|
|
5009
5104
|
resolve(language);
|
|
@@ -5012,9 +5107,9 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5012
5107
|
}
|
|
5013
5108
|
};
|
|
5014
5109
|
// @ts-ignore
|
|
5015
|
-
|
|
5110
|
+
_this29.webex.internal.voicea.on(_internalPluginVoicea.EVENT_TRIGGERS.CAPTION_LANGUAGE_UPDATE, voiceaListenerCaptionUpdate);
|
|
5016
5111
|
// @ts-ignore
|
|
5017
|
-
|
|
5112
|
+
_this29.webex.internal.voicea.requestLanguage(language);
|
|
5018
5113
|
} catch (error) {
|
|
5019
5114
|
_loggerProxy.default.logger.error("Meeting:index#setCaptionLanguage --> ".concat(error));
|
|
5020
5115
|
reject(error);
|
|
@@ -5030,19 +5125,19 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5030
5125
|
}, {
|
|
5031
5126
|
key: "setSpokenLanguage",
|
|
5032
5127
|
value: function setSpokenLanguage(language) {
|
|
5033
|
-
var
|
|
5128
|
+
var _this30 = this;
|
|
5034
5129
|
return new _promise.default(function (resolve, reject) {
|
|
5035
|
-
if (!
|
|
5130
|
+
if (!_this30.isTranscriptionSupported()) {
|
|
5036
5131
|
_loggerProxy.default.logger.error('Meeting:index#setCaptionLanguage --> Webex Assistant is not enabled/supported');
|
|
5037
5132
|
reject(new Error('Webex Assistant is not enabled/supported'));
|
|
5038
5133
|
}
|
|
5039
5134
|
try {
|
|
5040
5135
|
var voiceaListenerLanguageUpdate = function voiceaListenerLanguageUpdate(payload) {
|
|
5041
5136
|
// @ts-ignore
|
|
5042
|
-
|
|
5137
|
+
_this30.webex.internal.voicea.off(_internalPluginVoicea.EVENT_TRIGGERS.SPOKEN_LANGUAGE_UPDATE, voiceaListenerLanguageUpdate);
|
|
5043
5138
|
var languageCode = payload.languageCode;
|
|
5044
5139
|
if (languageCode) {
|
|
5045
|
-
|
|
5140
|
+
_this30.transcription.languageOptions = _objectSpread(_objectSpread({}, _this30.transcription.languageOptions), {}, {
|
|
5046
5141
|
currentSpokenLanguage: languageCode
|
|
5047
5142
|
});
|
|
5048
5143
|
resolve(languageCode);
|
|
@@ -5052,10 +5147,10 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5052
5147
|
};
|
|
5053
5148
|
|
|
5054
5149
|
// @ts-ignore
|
|
5055
|
-
|
|
5150
|
+
_this30.webex.internal.voicea.on(_internalPluginVoicea.EVENT_TRIGGERS.SPOKEN_LANGUAGE_UPDATE, voiceaListenerLanguageUpdate);
|
|
5056
5151
|
|
|
5057
5152
|
// @ts-ignore
|
|
5058
|
-
|
|
5153
|
+
_this30.webex.internal.voicea.setSpokenLanguage(language);
|
|
5059
5154
|
} catch (error) {
|
|
5060
5155
|
_loggerProxy.default.logger.error("Meeting:index#setSpokenLanguage --> ".concat(error));
|
|
5061
5156
|
reject(error);
|
|
@@ -5072,48 +5167,48 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5072
5167
|
}, {
|
|
5073
5168
|
key: "startTranscription",
|
|
5074
5169
|
value: (function () {
|
|
5075
|
-
var _startTranscription = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function
|
|
5076
|
-
return _regenerator.default.wrap(function
|
|
5077
|
-
while (1) switch (
|
|
5170
|
+
var _startTranscription = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee16(options) {
|
|
5171
|
+
return _regenerator.default.wrap(function _callee16$(_context16) {
|
|
5172
|
+
while (1) switch (_context16.prev = _context16.next) {
|
|
5078
5173
|
case 0:
|
|
5079
5174
|
if (!this.isJoined()) {
|
|
5080
|
-
|
|
5175
|
+
_context16.next = 15;
|
|
5081
5176
|
break;
|
|
5082
5177
|
}
|
|
5083
5178
|
_loggerProxy.default.logger.info('Meeting:index#startTranscription --> Attempting to enable transcription!');
|
|
5084
|
-
|
|
5179
|
+
_context16.prev = 2;
|
|
5085
5180
|
if (!this.areVoiceaEventsSetup) {
|
|
5086
5181
|
this.setUpVoiceaListeners();
|
|
5087
5182
|
}
|
|
5088
5183
|
if (!(this.getCurUserType() === 'host')) {
|
|
5089
|
-
|
|
5184
|
+
_context16.next = 7;
|
|
5090
5185
|
break;
|
|
5091
5186
|
}
|
|
5092
|
-
|
|
5187
|
+
_context16.next = 7;
|
|
5093
5188
|
return this.webex.internal.voicea.toggleTranscribing(true, options === null || options === void 0 ? void 0 : options.spokenLanguage);
|
|
5094
5189
|
case 7:
|
|
5095
|
-
|
|
5190
|
+
_context16.next = 13;
|
|
5096
5191
|
break;
|
|
5097
5192
|
case 9:
|
|
5098
|
-
|
|
5099
|
-
|
|
5100
|
-
_loggerProxy.default.logger.error("Meeting:index#startTranscription --> ".concat(
|
|
5193
|
+
_context16.prev = 9;
|
|
5194
|
+
_context16.t0 = _context16["catch"](2);
|
|
5195
|
+
_loggerProxy.default.logger.error("Meeting:index#startTranscription --> ".concat(_context16.t0));
|
|
5101
5196
|
_metrics.default.sendBehavioralMetric(_constants2.default.RECEIVE_TRANSCRIPTION_FAILURE, {
|
|
5102
5197
|
correlation_id: this.correlationId,
|
|
5103
|
-
reason:
|
|
5104
|
-
stack:
|
|
5198
|
+
reason: _context16.t0.message,
|
|
5199
|
+
stack: _context16.t0.stack
|
|
5105
5200
|
});
|
|
5106
5201
|
case 13:
|
|
5107
|
-
|
|
5202
|
+
_context16.next = 17;
|
|
5108
5203
|
break;
|
|
5109
5204
|
case 15:
|
|
5110
5205
|
_loggerProxy.default.logger.error("Meeting:index#startTranscription --> meeting joined : ".concat(this.isJoined()));
|
|
5111
5206
|
throw new Error('Meeting is not joined');
|
|
5112
5207
|
case 17:
|
|
5113
5208
|
case "end":
|
|
5114
|
-
return
|
|
5209
|
+
return _context16.stop();
|
|
5115
5210
|
}
|
|
5116
|
-
},
|
|
5211
|
+
}, _callee16, this, [[2, 9]]);
|
|
5117
5212
|
}));
|
|
5118
5213
|
function startTranscription(_x15) {
|
|
5119
5214
|
return _startTranscription.apply(this, arguments);
|
|
@@ -5176,8 +5271,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5176
5271
|
}, {
|
|
5177
5272
|
key: "join",
|
|
5178
5273
|
value: (function () {
|
|
5179
|
-
var _join = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function
|
|
5180
|
-
var
|
|
5274
|
+
var _join = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee17() {
|
|
5275
|
+
var _this31 = this;
|
|
5181
5276
|
var options,
|
|
5182
5277
|
errorMessage,
|
|
5183
5278
|
error,
|
|
@@ -5187,25 +5282,25 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5187
5282
|
_error,
|
|
5188
5283
|
_errorMessage2,
|
|
5189
5284
|
_error2,
|
|
5190
|
-
|
|
5191
|
-
return _regenerator.default.wrap(function
|
|
5192
|
-
while (1) switch (
|
|
5285
|
+
_args17 = arguments;
|
|
5286
|
+
return _regenerator.default.wrap(function _callee17$(_context17) {
|
|
5287
|
+
while (1) switch (_context17.prev = _context17.next) {
|
|
5193
5288
|
case 0:
|
|
5194
|
-
options =
|
|
5289
|
+
options = _args17.length > 0 && _args17[0] !== undefined ? _args17[0] : {};
|
|
5195
5290
|
if (this.webex.meetings.registered) {
|
|
5196
|
-
|
|
5291
|
+
_context17.next = 6;
|
|
5197
5292
|
break;
|
|
5198
5293
|
}
|
|
5199
5294
|
errorMessage = 'Meeting:index#join --> Device not registered';
|
|
5200
5295
|
error = new Error(errorMessage);
|
|
5201
5296
|
_loggerProxy.default.logger.error(errorMessage);
|
|
5202
|
-
return
|
|
5297
|
+
return _context17.abrupt("return", _promise.default.reject(error));
|
|
5203
5298
|
case 6:
|
|
5204
5299
|
if (!this.deferJoin) {
|
|
5205
|
-
|
|
5300
|
+
_context17.next = 8;
|
|
5206
5301
|
break;
|
|
5207
5302
|
}
|
|
5208
|
-
return
|
|
5303
|
+
return _context17.abrupt("return", this.deferJoin);
|
|
5209
5304
|
case 8:
|
|
5210
5305
|
// Create a deferred promise for a consistent resolve value from utils.
|
|
5211
5306
|
// This also prevents redundant API calls.
|
|
@@ -5254,15 +5349,15 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5254
5349
|
this.wirelessShare = true;
|
|
5255
5350
|
}
|
|
5256
5351
|
if (!options.meetingQuality) {
|
|
5257
|
-
|
|
5352
|
+
_context17.next = 36;
|
|
5258
5353
|
break;
|
|
5259
5354
|
}
|
|
5260
5355
|
if (!(typeof options.meetingQuality === 'string')) {
|
|
5261
|
-
|
|
5356
|
+
_context17.next = 27;
|
|
5262
5357
|
break;
|
|
5263
5358
|
}
|
|
5264
5359
|
if (_constants.QUALITY_LEVELS[options.meetingQuality]) {
|
|
5265
|
-
|
|
5360
|
+
_context17.next = 26;
|
|
5266
5361
|
break;
|
|
5267
5362
|
}
|
|
5268
5363
|
_errorMessage = "Meeting:index#join --> ".concat(options.meetingQuality, " not defined");
|
|
@@ -5270,16 +5365,16 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5270
5365
|
_loggerProxy.default.logger.error(_errorMessage);
|
|
5271
5366
|
joinFailed(_error);
|
|
5272
5367
|
this.deferJoin = undefined;
|
|
5273
|
-
return
|
|
5368
|
+
return _context17.abrupt("return", _promise.default.reject(_error));
|
|
5274
5369
|
case 26:
|
|
5275
5370
|
this.mediaProperties.setRemoteQualityLevel(options.meetingQuality);
|
|
5276
5371
|
case 27:
|
|
5277
5372
|
if (!((0, _typeof2.default)(options.meetingQuality) === 'object')) {
|
|
5278
|
-
|
|
5373
|
+
_context17.next = 36;
|
|
5279
5374
|
break;
|
|
5280
5375
|
}
|
|
5281
5376
|
if (_constants.QUALITY_LEVELS[options.meetingQuality.remote]) {
|
|
5282
|
-
|
|
5377
|
+
_context17.next = 35;
|
|
5283
5378
|
break;
|
|
5284
5379
|
}
|
|
5285
5380
|
_errorMessage2 = "Meeting:index#join --> ".concat(options.meetingQuality.remote, " not defined");
|
|
@@ -5287,97 +5382,97 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5287
5382
|
_error2 = new Error(_errorMessage2);
|
|
5288
5383
|
joinFailed(_error2);
|
|
5289
5384
|
this.deferJoin = undefined;
|
|
5290
|
-
return
|
|
5385
|
+
return _context17.abrupt("return", _promise.default.reject(new Error(_errorMessage2)));
|
|
5291
5386
|
case 35:
|
|
5292
5387
|
if (options.meetingQuality.remote) {
|
|
5293
5388
|
this.mediaProperties.setRemoteQualityLevel(options.meetingQuality.remote);
|
|
5294
5389
|
}
|
|
5295
5390
|
case 36:
|
|
5296
5391
|
this.isMultistream = !!options.enableMultistream;
|
|
5297
|
-
|
|
5298
|
-
|
|
5392
|
+
_context17.prev = 37;
|
|
5393
|
+
_context17.next = 40;
|
|
5299
5394
|
return this.checkAndRefreshPermissionToken(_constants.MEETING_PERMISSION_TOKEN_REFRESH_THRESHOLD_IN_SEC, _constants.MEETING_PERMISSION_TOKEN_REFRESH_REASON);
|
|
5300
5395
|
case 40:
|
|
5301
|
-
|
|
5396
|
+
_context17.next = 51;
|
|
5302
5397
|
break;
|
|
5303
5398
|
case 42:
|
|
5304
|
-
|
|
5305
|
-
|
|
5306
|
-
_loggerProxy.default.logger.error('Meeting:index#join --> Failed to refresh permission token:',
|
|
5307
|
-
if (!(
|
|
5308
|
-
|
|
5399
|
+
_context17.prev = 42;
|
|
5400
|
+
_context17.t0 = _context17["catch"](37);
|
|
5401
|
+
_loggerProxy.default.logger.error('Meeting:index#join --> Failed to refresh permission token:', _context17.t0);
|
|
5402
|
+
if (!(_context17.t0 instanceof _captchaError.default || _context17.t0 instanceof _passwordError.default || _context17.t0 instanceof _permission.default)) {
|
|
5403
|
+
_context17.next = 51;
|
|
5309
5404
|
break;
|
|
5310
5405
|
}
|
|
5311
|
-
this.meetingFiniteStateMachine.fail(
|
|
5406
|
+
this.meetingFiniteStateMachine.fail(_context17.t0);
|
|
5312
5407
|
|
|
5313
5408
|
// Upload logs on refreshpermissionToken refresh Failure
|
|
5314
5409
|
_triggerProxy.default.trigger(this, {
|
|
5315
5410
|
file: 'meeting/index',
|
|
5316
5411
|
function: 'join'
|
|
5317
5412
|
}, _constants.EVENTS.REQUEST_UPLOAD_LOGS, this);
|
|
5318
|
-
joinFailed(
|
|
5413
|
+
joinFailed(_context17.t0);
|
|
5319
5414
|
this.deferJoin = undefined;
|
|
5320
5415
|
|
|
5321
5416
|
// if refresh permission token requires captcha, password or permission, we are throwing the errors
|
|
5322
5417
|
// and bubble it up to client
|
|
5323
|
-
return
|
|
5418
|
+
return _context17.abrupt("return", _promise.default.reject(_context17.t0));
|
|
5324
5419
|
case 51:
|
|
5325
|
-
return
|
|
5326
|
-
|
|
5420
|
+
return _context17.abrupt("return", _util.default.joinMeetingOptions(this, options).then(function (join) {
|
|
5421
|
+
_this31.meetingFiniteStateMachine.join();
|
|
5327
5422
|
_loggerProxy.default.logger.log('Meeting:index#join --> Success');
|
|
5328
5423
|
_metrics.default.sendBehavioralMetric(_constants2.default.JOIN_SUCCESS, {
|
|
5329
|
-
correlation_id:
|
|
5424
|
+
correlation_id: _this31.correlationId
|
|
5330
5425
|
});
|
|
5331
5426
|
joinSuccess(join);
|
|
5332
|
-
|
|
5427
|
+
_this31.deferJoin = undefined;
|
|
5333
5428
|
return join;
|
|
5334
5429
|
}).catch(function (error) {
|
|
5335
|
-
var
|
|
5336
|
-
|
|
5430
|
+
var _this31$meetingInfo, _error$error;
|
|
5431
|
+
_this31.meetingFiniteStateMachine.fail(error);
|
|
5337
5432
|
_loggerProxy.default.logger.error('Meeting:index#join --> Failed', error);
|
|
5338
5433
|
|
|
5339
5434
|
// @ts-ignore
|
|
5340
|
-
|
|
5435
|
+
_this31.webex.internal.newMetrics.submitClientEvent({
|
|
5341
5436
|
name: 'client.locus.join.response',
|
|
5342
5437
|
payload: {
|
|
5343
5438
|
identifiers: {
|
|
5344
|
-
meetingLookupUrl: (
|
|
5439
|
+
meetingLookupUrl: (_this31$meetingInfo = _this31.meetingInfo) === null || _this31$meetingInfo === void 0 ? void 0 : _this31$meetingInfo.meetingLookupUrl
|
|
5345
5440
|
}
|
|
5346
5441
|
},
|
|
5347
5442
|
options: {
|
|
5348
|
-
meetingId:
|
|
5443
|
+
meetingId: _this31.id,
|
|
5349
5444
|
rawError: error
|
|
5350
5445
|
}
|
|
5351
5446
|
});
|
|
5352
5447
|
|
|
5353
5448
|
// TODO: change this to error codes and pre defined dictionary
|
|
5354
5449
|
_metrics.default.sendBehavioralMetric(_constants2.default.JOIN_FAILURE, {
|
|
5355
|
-
correlation_id:
|
|
5450
|
+
correlation_id: _this31.correlationId,
|
|
5356
5451
|
reason: (_error$error = error.error) === null || _error$error === void 0 ? void 0 : _error$error.message,
|
|
5357
5452
|
stack: error.stack
|
|
5358
5453
|
});
|
|
5359
5454
|
|
|
5360
5455
|
// Upload logs on join Failure
|
|
5361
|
-
_triggerProxy.default.trigger(
|
|
5456
|
+
_triggerProxy.default.trigger(_this31, {
|
|
5362
5457
|
file: 'meeting/index',
|
|
5363
5458
|
function: 'join'
|
|
5364
|
-
}, _constants.EVENTS.REQUEST_UPLOAD_LOGS,
|
|
5459
|
+
}, _constants.EVENTS.REQUEST_UPLOAD_LOGS, _this31);
|
|
5365
5460
|
joinFailed(error);
|
|
5366
|
-
|
|
5461
|
+
_this31.deferJoin = undefined;
|
|
5367
5462
|
return _promise.default.reject(error);
|
|
5368
5463
|
}).then(function (join) {
|
|
5369
5464
|
// @ts-ignore - config coming from registerPlugin
|
|
5370
|
-
if (
|
|
5371
|
-
|
|
5465
|
+
if (_this31.config.enableAutomaticLLM) {
|
|
5466
|
+
_this31.updateLLMConnection().catch(function (error) {
|
|
5372
5467
|
_loggerProxy.default.logger.error('Meeting:index#join --> Transcription Socket Connection Failed', error);
|
|
5373
5468
|
_metrics.default.sendBehavioralMetric(_constants2.default.LLM_CONNECTION_AFTER_JOIN_FAILURE, {
|
|
5374
|
-
correlation_id:
|
|
5469
|
+
correlation_id: _this31.correlationId,
|
|
5375
5470
|
reason: error === null || error === void 0 ? void 0 : error.message,
|
|
5376
5471
|
stack: error.stack
|
|
5377
5472
|
});
|
|
5378
5473
|
}).then(function () {
|
|
5379
5474
|
_loggerProxy.default.logger.info('Meeting:index#join --> Transcription Socket Connection Success');
|
|
5380
|
-
_triggerProxy.default.trigger(
|
|
5475
|
+
_triggerProxy.default.trigger(_this31, {
|
|
5381
5476
|
file: 'meeting/index',
|
|
5382
5477
|
function: 'join'
|
|
5383
5478
|
}, _constants.EVENT_TRIGGERS.MEETING_TRANSCRIPTION_CONNECTED, undefined);
|
|
@@ -5387,9 +5482,9 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5387
5482
|
}));
|
|
5388
5483
|
case 52:
|
|
5389
5484
|
case "end":
|
|
5390
|
-
return
|
|
5485
|
+
return _context17.stop();
|
|
5391
5486
|
}
|
|
5392
|
-
},
|
|
5487
|
+
}, _callee17, this, [[37, 42]]);
|
|
5393
5488
|
}));
|
|
5394
5489
|
function join() {
|
|
5395
5490
|
return _join.apply(this, arguments);
|
|
@@ -5406,50 +5501,50 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5406
5501
|
}, {
|
|
5407
5502
|
key: "updateLLMConnection",
|
|
5408
5503
|
value: (function () {
|
|
5409
|
-
var _updateLLMConnection = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function
|
|
5410
|
-
var
|
|
5504
|
+
var _updateLLMConnection = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee18() {
|
|
5505
|
+
var _this32 = this;
|
|
5411
5506
|
var _this$locusInfo6, url, _this$locusInfo6$info, _this$locusInfo6$info2, datachannelUrl, isJoined;
|
|
5412
|
-
return _regenerator.default.wrap(function
|
|
5413
|
-
while (1) switch (
|
|
5507
|
+
return _regenerator.default.wrap(function _callee18$(_context18) {
|
|
5508
|
+
while (1) switch (_context18.prev = _context18.next) {
|
|
5414
5509
|
case 0:
|
|
5415
5510
|
// @ts-ignore - Fix type
|
|
5416
5511
|
_this$locusInfo6 = this.locusInfo, url = _this$locusInfo6.url, _this$locusInfo6$info = _this$locusInfo6.info, _this$locusInfo6$info2 = _this$locusInfo6$info === void 0 ? {} : _this$locusInfo6$info, datachannelUrl = _this$locusInfo6$info2.datachannelUrl;
|
|
5417
5512
|
isJoined = this.isJoined(); // @ts-ignore - Fix type
|
|
5418
5513
|
if (!this.webex.internal.llm.isConnected()) {
|
|
5419
|
-
|
|
5514
|
+
_context18.next = 8;
|
|
5420
5515
|
break;
|
|
5421
5516
|
}
|
|
5422
5517
|
if (!(url === this.webex.internal.llm.getLocusUrl() && isJoined)) {
|
|
5423
|
-
|
|
5518
|
+
_context18.next = 5;
|
|
5424
5519
|
break;
|
|
5425
5520
|
}
|
|
5426
|
-
return
|
|
5521
|
+
return _context18.abrupt("return", undefined);
|
|
5427
5522
|
case 5:
|
|
5428
|
-
|
|
5523
|
+
_context18.next = 7;
|
|
5429
5524
|
return this.webex.internal.llm.disconnectLLM();
|
|
5430
5525
|
case 7:
|
|
5431
5526
|
// @ts-ignore - Fix type
|
|
5432
5527
|
this.webex.internal.llm.off('event:relay.event', this.processRelayEvent);
|
|
5433
5528
|
case 8:
|
|
5434
5529
|
if (isJoined) {
|
|
5435
|
-
|
|
5530
|
+
_context18.next = 10;
|
|
5436
5531
|
break;
|
|
5437
5532
|
}
|
|
5438
|
-
return
|
|
5533
|
+
return _context18.abrupt("return", undefined);
|
|
5439
5534
|
case 10:
|
|
5440
|
-
return
|
|
5535
|
+
return _context18.abrupt("return", this.webex.internal.llm.registerAndConnect(url, datachannelUrl).then(function (registerAndConnectResult) {
|
|
5441
5536
|
// @ts-ignore - Fix type
|
|
5442
|
-
|
|
5537
|
+
_this32.webex.internal.llm.off('event:relay.event', _this32.processRelayEvent);
|
|
5443
5538
|
// @ts-ignore - Fix type
|
|
5444
|
-
|
|
5539
|
+
_this32.webex.internal.llm.on('event:relay.event', _this32.processRelayEvent);
|
|
5445
5540
|
_loggerProxy.default.logger.info('Meeting:index#updateLLMConnection --> enabled to receive relay events!');
|
|
5446
5541
|
return _promise.default.resolve(registerAndConnectResult);
|
|
5447
5542
|
}));
|
|
5448
5543
|
case 11:
|
|
5449
5544
|
case "end":
|
|
5450
|
-
return
|
|
5545
|
+
return _context18.stop();
|
|
5451
5546
|
}
|
|
5452
|
-
},
|
|
5547
|
+
}, _callee18, this);
|
|
5453
5548
|
}));
|
|
5454
5549
|
function updateLLMConnection() {
|
|
5455
5550
|
return _updateLLMConnection.apply(this, arguments);
|
|
@@ -5495,7 +5590,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5495
5590
|
}, {
|
|
5496
5591
|
key: "dialInPstn",
|
|
5497
5592
|
value: function dialInPstn() {
|
|
5498
|
-
var
|
|
5593
|
+
var _this33 = this;
|
|
5499
5594
|
if (this.isPhoneProvisioned(this.dialInDeviceStatus)) return _promise.default.resolve(); // prevent multiple dial in devices from being provisioned
|
|
5500
5595
|
|
|
5501
5596
|
var correlationId = this.correlationId,
|
|
@@ -5511,10 +5606,10 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5511
5606
|
}).catch(function (error) {
|
|
5512
5607
|
var _error$error2;
|
|
5513
5608
|
_metrics.default.sendBehavioralMetric(_constants2.default.ADD_DIAL_IN_FAILURE, {
|
|
5514
|
-
correlation_id:
|
|
5515
|
-
dial_in_url:
|
|
5609
|
+
correlation_id: _this33.correlationId,
|
|
5610
|
+
dial_in_url: _this33.dialInUrl,
|
|
5516
5611
|
locus_id: locusUrl.split('/').pop(),
|
|
5517
|
-
client_url:
|
|
5612
|
+
client_url: _this33.deviceUrl,
|
|
5518
5613
|
reason: (_error$error2 = error.error) === null || _error$error2 === void 0 ? void 0 : _error$error2.message,
|
|
5519
5614
|
stack: error.stack
|
|
5520
5615
|
});
|
|
@@ -5532,7 +5627,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5532
5627
|
}, {
|
|
5533
5628
|
key: "dialOutPstn",
|
|
5534
5629
|
value: function dialOutPstn(phoneNumber) {
|
|
5535
|
-
var
|
|
5630
|
+
var _this34 = this;
|
|
5536
5631
|
if (this.isPhoneProvisioned(this.dialOutDeviceStatus)) return _promise.default.resolve(); // prevent multiple dial out devices from being provisioned
|
|
5537
5632
|
|
|
5538
5633
|
var correlationId = this.correlationId,
|
|
@@ -5549,10 +5644,10 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5549
5644
|
}).catch(function (error) {
|
|
5550
5645
|
var _error$error3;
|
|
5551
5646
|
_metrics.default.sendBehavioralMetric(_constants2.default.ADD_DIAL_OUT_FAILURE, {
|
|
5552
|
-
correlation_id:
|
|
5553
|
-
dial_out_url:
|
|
5647
|
+
correlation_id: _this34.correlationId,
|
|
5648
|
+
dial_out_url: _this34.dialOutUrl,
|
|
5554
5649
|
locus_id: locusUrl.split('/').pop(),
|
|
5555
|
-
client_url:
|
|
5650
|
+
client_url: _this34.deviceUrl,
|
|
5556
5651
|
reason: (_error$error3 = error.error) === null || _error$error3 === void 0 ? void 0 : _error$error3.message,
|
|
5557
5652
|
stack: error.stack
|
|
5558
5653
|
});
|
|
@@ -5583,7 +5678,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5583
5678
|
}, {
|
|
5584
5679
|
key: "moveTo",
|
|
5585
5680
|
value: function moveTo(resourceId) {
|
|
5586
|
-
var
|
|
5681
|
+
var _this35 = this;
|
|
5587
5682
|
if (!resourceId) {
|
|
5588
5683
|
throw new _parameter.default('Cannot move call without a resourceId.');
|
|
5589
5684
|
}
|
|
@@ -5621,18 +5716,18 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5621
5716
|
meetingId: this.id
|
|
5622
5717
|
}
|
|
5623
5718
|
});
|
|
5624
|
-
this.locusInfo.once(_constants.LOCUSINFO.EVENTS.SELF_OBSERVING, /*#__PURE__*/(0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function
|
|
5719
|
+
this.locusInfo.once(_constants.LOCUSINFO.EVENTS.SELF_OBSERVING, /*#__PURE__*/(0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee19() {
|
|
5625
5720
|
var mediaSettings;
|
|
5626
|
-
return _regenerator.default.wrap(function
|
|
5627
|
-
while (1) switch (
|
|
5721
|
+
return _regenerator.default.wrap(function _callee19$(_context19) {
|
|
5722
|
+
while (1) switch (_context19.prev = _context19.next) {
|
|
5628
5723
|
case 0:
|
|
5629
|
-
|
|
5630
|
-
if (!(
|
|
5631
|
-
|
|
5724
|
+
_context19.prev = 0;
|
|
5725
|
+
if (!(_this35.screenShareFloorState === ScreenShareFloorStatus.GRANTED)) {
|
|
5726
|
+
_context19.next = 4;
|
|
5632
5727
|
break;
|
|
5633
5728
|
}
|
|
5634
|
-
|
|
5635
|
-
return
|
|
5729
|
+
_context19.next = 4;
|
|
5730
|
+
return _this35.releaseScreenShareFloor();
|
|
5636
5731
|
case 4:
|
|
5637
5732
|
mediaSettings = {
|
|
5638
5733
|
mediaDirection: {
|
|
@@ -5644,47 +5739,47 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5644
5739
|
receiveShare: true
|
|
5645
5740
|
}
|
|
5646
5741
|
};
|
|
5647
|
-
|
|
5648
|
-
|
|
5649
|
-
|
|
5742
|
+
_this35.cleanupLocalStreams();
|
|
5743
|
+
_this35.mediaProperties.setMediaDirection(mediaSettings.mediaDirection);
|
|
5744
|
+
_this35.mediaProperties.unsetRemoteMedia();
|
|
5650
5745
|
|
|
5651
5746
|
// when a move to is intiated by the client , Locus delets the existing media node from the server as soon the DX answers the meeting
|
|
5652
5747
|
// once the DX answers we establish connection back the media server with only receiveShare enabled
|
|
5653
5748
|
// @ts-ignore - reconnectMedia does not accept any argument
|
|
5654
|
-
|
|
5655
|
-
return
|
|
5749
|
+
_context19.next = 10;
|
|
5750
|
+
return _this35.reconnectionManager.reconnectMedia(mediaSettings).then(function () {
|
|
5656
5751
|
_metrics.default.sendBehavioralMetric(_constants2.default.MOVE_TO_SUCCESS);
|
|
5657
5752
|
});
|
|
5658
5753
|
case 10:
|
|
5659
|
-
|
|
5754
|
+
_context19.next = 16;
|
|
5660
5755
|
break;
|
|
5661
5756
|
case 12:
|
|
5662
|
-
|
|
5663
|
-
|
|
5664
|
-
_loggerProxy.default.logger.error('Meeting:index#moveTo --> Failed to moveTo resourceId',
|
|
5757
|
+
_context19.prev = 12;
|
|
5758
|
+
_context19.t0 = _context19["catch"](0);
|
|
5759
|
+
_loggerProxy.default.logger.error('Meeting:index#moveTo --> Failed to moveTo resourceId', _context19.t0);
|
|
5665
5760
|
_metrics.default.sendBehavioralMetric(_constants2.default.MOVE_TO_FAILURE, {
|
|
5666
|
-
correlation_id:
|
|
5667
|
-
locus_id:
|
|
5668
|
-
reason:
|
|
5669
|
-
stack:
|
|
5761
|
+
correlation_id: _this35.correlationId,
|
|
5762
|
+
locus_id: _this35.locusUrl.split('/').pop(),
|
|
5763
|
+
reason: _context19.t0.message,
|
|
5764
|
+
stack: _context19.t0.stack
|
|
5670
5765
|
});
|
|
5671
5766
|
case 16:
|
|
5672
5767
|
case "end":
|
|
5673
|
-
return
|
|
5768
|
+
return _context19.stop();
|
|
5674
5769
|
}
|
|
5675
|
-
},
|
|
5770
|
+
}, _callee19, null, [[0, 12]]);
|
|
5676
5771
|
})));
|
|
5677
5772
|
_loggerProxy.default.logger.info('Meeting:index#moveTo --> Initated moved to using resourceId', resourceId);
|
|
5678
5773
|
return _util.default.joinMeetingOptions(this, {
|
|
5679
5774
|
resourceId: resourceId,
|
|
5680
5775
|
moveToResource: true
|
|
5681
5776
|
}).then(function () {
|
|
5682
|
-
|
|
5777
|
+
_this35.meetingFiniteStateMachine.join();
|
|
5683
5778
|
}).catch(function (error) {
|
|
5684
|
-
|
|
5779
|
+
_this35.meetingFiniteStateMachine.fail(error);
|
|
5685
5780
|
_metrics.default.sendBehavioralMetric(_constants2.default.MOVE_TO_FAILURE, {
|
|
5686
|
-
correlation_id:
|
|
5687
|
-
locus_id:
|
|
5781
|
+
correlation_id: _this35.correlationId,
|
|
5782
|
+
locus_id: _this35.locusUrl.split('/').pop(),
|
|
5688
5783
|
reason: error.message,
|
|
5689
5784
|
stack: error.stack
|
|
5690
5785
|
});
|
|
@@ -5703,7 +5798,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5703
5798
|
}, {
|
|
5704
5799
|
key: "moveFrom",
|
|
5705
5800
|
value: function moveFrom(resourceId) {
|
|
5706
|
-
var
|
|
5801
|
+
var _this36 = this;
|
|
5707
5802
|
// On moveFrom ask the developer to re capture it moveFrom then updateMedia
|
|
5708
5803
|
if (!resourceId) {
|
|
5709
5804
|
throw new _parameter.default('Cannot move call without a resourceId.');
|
|
@@ -5718,19 +5813,19 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5718
5813
|
}
|
|
5719
5814
|
});
|
|
5720
5815
|
return _util.default.joinMeetingOptions(this).then(function () {
|
|
5721
|
-
return _util.default.leaveMeeting(
|
|
5816
|
+
return _util.default.leaveMeeting(_this36, {
|
|
5722
5817
|
resourceId: resourceId,
|
|
5723
5818
|
correlationId: oldCorrelationId,
|
|
5724
5819
|
moveMeeting: true
|
|
5725
5820
|
}).then(function () {
|
|
5726
|
-
|
|
5821
|
+
_this36.resourceId = '';
|
|
5727
5822
|
_metrics.default.sendBehavioralMetric(_constants2.default.MOVE_FROM_SUCCESS);
|
|
5728
5823
|
});
|
|
5729
5824
|
}).catch(function (error) {
|
|
5730
|
-
|
|
5825
|
+
_this36.meetingFiniteStateMachine.fail(error);
|
|
5731
5826
|
_metrics.default.sendBehavioralMetric(_constants2.default.MOVE_FROM_FAILURE, {
|
|
5732
|
-
correlation_id:
|
|
5733
|
-
locus_id:
|
|
5827
|
+
correlation_id: _this36.correlationId,
|
|
5828
|
+
locus_id: _this36.locusUrl.split('/').pop(),
|
|
5734
5829
|
reason: error.message,
|
|
5735
5830
|
stack: error.stack
|
|
5736
5831
|
});
|
|
@@ -5755,10 +5850,10 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5755
5850
|
}, {
|
|
5756
5851
|
key: "createMediaConnection",
|
|
5757
5852
|
value: (function () {
|
|
5758
|
-
var _createMediaConnection = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function
|
|
5853
|
+
var _createMediaConnection = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee20(turnServerInfo, bundlePolicy) {
|
|
5759
5854
|
var mc, audioEnabled, videoEnabled, shareEnabled;
|
|
5760
|
-
return _regenerator.default.wrap(function
|
|
5761
|
-
while (1) switch (
|
|
5855
|
+
return _regenerator.default.wrap(function _callee20$(_context20) {
|
|
5856
|
+
while (1) switch (_context20.prev = _context20.next) {
|
|
5762
5857
|
case 0:
|
|
5763
5858
|
mc = _media.default.createMediaConnection(this.isMultistream, this.getMediaConnectionDebugId(),
|
|
5764
5859
|
// @ts-ignore
|
|
@@ -5784,40 +5879,40 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5784
5879
|
|
|
5785
5880
|
// publish the streams
|
|
5786
5881
|
if (!this.mediaProperties.audioStream) {
|
|
5787
|
-
|
|
5882
|
+
_context20.next = 8;
|
|
5788
5883
|
break;
|
|
5789
5884
|
}
|
|
5790
5885
|
this.setSendNamedMediaGroup(_internalMediaCore.MediaType.AudioMain);
|
|
5791
|
-
|
|
5886
|
+
_context20.next = 8;
|
|
5792
5887
|
return this.publishStream(_internalMediaCore.MediaType.AudioMain, this.mediaProperties.audioStream);
|
|
5793
5888
|
case 8:
|
|
5794
5889
|
if (!this.mediaProperties.videoStream) {
|
|
5795
|
-
|
|
5890
|
+
_context20.next = 11;
|
|
5796
5891
|
break;
|
|
5797
5892
|
}
|
|
5798
|
-
|
|
5893
|
+
_context20.next = 11;
|
|
5799
5894
|
return this.publishStream(_internalMediaCore.MediaType.VideoMain, this.mediaProperties.videoStream);
|
|
5800
5895
|
case 11:
|
|
5801
5896
|
if (!this.mediaProperties.shareVideoStream) {
|
|
5802
|
-
|
|
5897
|
+
_context20.next = 14;
|
|
5803
5898
|
break;
|
|
5804
5899
|
}
|
|
5805
|
-
|
|
5900
|
+
_context20.next = 14;
|
|
5806
5901
|
return this.publishStream(_internalMediaCore.MediaType.VideoSlides, this.mediaProperties.shareVideoStream);
|
|
5807
5902
|
case 14:
|
|
5808
5903
|
if (!(this.isMultistream && this.mediaProperties.shareAudioStream)) {
|
|
5809
|
-
|
|
5904
|
+
_context20.next = 17;
|
|
5810
5905
|
break;
|
|
5811
5906
|
}
|
|
5812
|
-
|
|
5907
|
+
_context20.next = 17;
|
|
5813
5908
|
return this.publishStream(_internalMediaCore.MediaType.AudioSlides, this.mediaProperties.shareAudioStream);
|
|
5814
5909
|
case 17:
|
|
5815
|
-
return
|
|
5910
|
+
return _context20.abrupt("return", mc);
|
|
5816
5911
|
case 18:
|
|
5817
5912
|
case "end":
|
|
5818
|
-
return
|
|
5913
|
+
return _context20.stop();
|
|
5819
5914
|
}
|
|
5820
|
-
},
|
|
5915
|
+
}, _callee20, this);
|
|
5821
5916
|
}));
|
|
5822
5917
|
function createMediaConnection(_x16, _x17) {
|
|
5823
5918
|
return _createMediaConnection.apply(this, arguments);
|
|
@@ -5837,9 +5932,9 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5837
5932
|
}, {
|
|
5838
5933
|
key: "forwardEvent",
|
|
5839
5934
|
value: function forwardEvent(eventEmitter, eventTypeToForward, meetingEventType) {
|
|
5840
|
-
var
|
|
5935
|
+
var _this37 = this;
|
|
5841
5936
|
eventEmitter.on(eventTypeToForward, function (data) {
|
|
5842
|
-
return _triggerProxy.default.trigger(
|
|
5937
|
+
return _triggerProxy.default.trigger(_this37, {
|
|
5843
5938
|
file: 'meetings',
|
|
5844
5939
|
function: 'addMedia'
|
|
5845
5940
|
}, meetingEventType, data);
|
|
@@ -5857,41 +5952,41 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5857
5952
|
}, {
|
|
5858
5953
|
key: "setUpLocalStreamReferences",
|
|
5859
5954
|
value: (function () {
|
|
5860
|
-
var _setUpLocalStreamReferences = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function
|
|
5861
|
-
var _localStreams$screenS, _localStreams$screenS2;
|
|
5955
|
+
var _setUpLocalStreamReferences = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee21(localStreams) {
|
|
5956
|
+
var _localStreams$microph, _localStreams$camera, _localStreams$screenS, _localStreams$screenS2, _localStreams$screenS3, _localStreams$screenS4, _localStreams$screenS5, _localStreams$screenS6;
|
|
5862
5957
|
var setUpStreamPromises;
|
|
5863
|
-
return _regenerator.default.wrap(function
|
|
5864
|
-
while (1) switch (
|
|
5958
|
+
return _regenerator.default.wrap(function _callee21$(_context21) {
|
|
5959
|
+
while (1) switch (_context21.prev = _context21.next) {
|
|
5865
5960
|
case 0:
|
|
5866
5961
|
setUpStreamPromises = [];
|
|
5867
|
-
if (localStreams !== null && localStreams !== void 0 && localStreams.microphone) {
|
|
5962
|
+
if (localStreams !== null && localStreams !== void 0 && localStreams.microphone && (localStreams === null || localStreams === void 0 ? void 0 : (_localStreams$microph = localStreams.microphone) === null || _localStreams$microph === void 0 ? void 0 : _localStreams$microph.readyState) !== 'ended') {
|
|
5868
5963
|
setUpStreamPromises.push(this.setLocalAudioStream(localStreams.microphone));
|
|
5869
5964
|
}
|
|
5870
|
-
if (localStreams !== null && localStreams !== void 0 && localStreams.camera) {
|
|
5965
|
+
if (localStreams !== null && localStreams !== void 0 && localStreams.camera && (localStreams === null || localStreams === void 0 ? void 0 : (_localStreams$camera = localStreams.camera) === null || _localStreams$camera === void 0 ? void 0 : _localStreams$camera.readyState) !== 'ended') {
|
|
5871
5966
|
setUpStreamPromises.push(this.setLocalVideoStream(localStreams.camera));
|
|
5872
5967
|
}
|
|
5873
|
-
if (localStreams !== null && localStreams !== void 0 && (_localStreams$screenS = localStreams.screenShare) !== null && _localStreams$screenS !== void 0 && _localStreams$screenS.video) {
|
|
5968
|
+
if (localStreams !== null && localStreams !== void 0 && (_localStreams$screenS = localStreams.screenShare) !== null && _localStreams$screenS !== void 0 && _localStreams$screenS.video && (localStreams === null || localStreams === void 0 ? void 0 : (_localStreams$screenS2 = localStreams.screenShare) === null || _localStreams$screenS2 === void 0 ? void 0 : (_localStreams$screenS3 = _localStreams$screenS2.video) === null || _localStreams$screenS3 === void 0 ? void 0 : _localStreams$screenS3.readyState) !== 'ended') {
|
|
5874
5969
|
setUpStreamPromises.push(this.setLocalShareVideoStream(localStreams.screenShare.video));
|
|
5875
5970
|
}
|
|
5876
|
-
if (localStreams !== null && localStreams !== void 0 && (_localStreams$
|
|
5971
|
+
if (localStreams !== null && localStreams !== void 0 && (_localStreams$screenS4 = localStreams.screenShare) !== null && _localStreams$screenS4 !== void 0 && _localStreams$screenS4.audio && (localStreams === null || localStreams === void 0 ? void 0 : (_localStreams$screenS5 = localStreams.screenShare) === null || _localStreams$screenS5 === void 0 ? void 0 : (_localStreams$screenS6 = _localStreams$screenS5.audio) === null || _localStreams$screenS6 === void 0 ? void 0 : _localStreams$screenS6.readyState) !== 'ended') {
|
|
5877
5972
|
setUpStreamPromises.push(this.setLocalShareAudioStream(localStreams.screenShare.audio));
|
|
5878
5973
|
}
|
|
5879
|
-
|
|
5880
|
-
|
|
5974
|
+
_context21.prev = 5;
|
|
5975
|
+
_context21.next = 8;
|
|
5881
5976
|
return _promise.default.all(setUpStreamPromises);
|
|
5882
5977
|
case 8:
|
|
5883
|
-
|
|
5978
|
+
_context21.next = 14;
|
|
5884
5979
|
break;
|
|
5885
5980
|
case 10:
|
|
5886
|
-
|
|
5887
|
-
|
|
5888
|
-
_loggerProxy.default.logger.error("Meeting:index#addMedia():setUpLocalStreamReferences --> Error , ",
|
|
5889
|
-
throw
|
|
5981
|
+
_context21.prev = 10;
|
|
5982
|
+
_context21.t0 = _context21["catch"](5);
|
|
5983
|
+
_loggerProxy.default.logger.error("Meeting:index#addMedia():setUpLocalStreamReferences --> Error , ", _context21.t0);
|
|
5984
|
+
throw _context21.t0;
|
|
5890
5985
|
case 14:
|
|
5891
5986
|
case "end":
|
|
5892
|
-
return
|
|
5987
|
+
return _context21.stop();
|
|
5893
5988
|
}
|
|
5894
|
-
},
|
|
5989
|
+
}, _callee21, this, [[5, 10]]);
|
|
5895
5990
|
}));
|
|
5896
5991
|
function setUpLocalStreamReferences(_x18) {
|
|
5897
5992
|
return _setUpLocalStreamReferences.apply(this, arguments);
|
|
@@ -5908,20 +6003,20 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5908
6003
|
}, {
|
|
5909
6004
|
key: "waitForMediaConnectionConnected",
|
|
5910
6005
|
value: (function () {
|
|
5911
|
-
var _waitForMediaConnectionConnected = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function
|
|
6006
|
+
var _waitForMediaConnectionConnected = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee22() {
|
|
5912
6007
|
var _this$mediaProperties6, _this$mediaProperties7, _this$mediaProperties8, _this$mediaProperties9, _this$mediaProperties10, _this$mediaProperties11, _this$mediaProperties12, _this$mediaProperties13, _this$mediaProperties14, _this$mediaProperties15, _this$mediaProperties16, _this$mediaProperties17, _this$mediaProperties18, _this$mediaProperties19;
|
|
5913
|
-
return _regenerator.default.wrap(function
|
|
5914
|
-
while (1) switch (
|
|
6008
|
+
return _regenerator.default.wrap(function _callee22$(_context22) {
|
|
6009
|
+
while (1) switch (_context22.prev = _context22.next) {
|
|
5915
6010
|
case 0:
|
|
5916
|
-
|
|
5917
|
-
|
|
6011
|
+
_context22.prev = 0;
|
|
6012
|
+
_context22.next = 3;
|
|
5918
6013
|
return this.mediaProperties.waitForMediaConnectionConnected();
|
|
5919
6014
|
case 3:
|
|
5920
|
-
|
|
6015
|
+
_context22.next = 9;
|
|
5921
6016
|
break;
|
|
5922
6017
|
case 5:
|
|
5923
|
-
|
|
5924
|
-
|
|
6018
|
+
_context22.prev = 5;
|
|
6019
|
+
_context22.t0 = _context22["catch"](0);
|
|
5925
6020
|
if (!this.hasMediaConnectionConnectedAtLeastOnce) {
|
|
5926
6021
|
// Only send CA event for join flow if we haven't successfully connected media yet
|
|
5927
6022
|
// @ts-ignore
|
|
@@ -5949,9 +6044,9 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5949
6044
|
throw new Error("Timed out waiting for media connection to be connected, correlationId=".concat(this.correlationId));
|
|
5950
6045
|
case 9:
|
|
5951
6046
|
case "end":
|
|
5952
|
-
return
|
|
6047
|
+
return _context22.stop();
|
|
5953
6048
|
}
|
|
5954
|
-
},
|
|
6049
|
+
}, _callee22, this, [[0, 5]]);
|
|
5955
6050
|
}));
|
|
5956
6051
|
function waitForMediaConnectionConnected() {
|
|
5957
6052
|
return _waitForMediaConnectionConnected.apply(this, arguments);
|
|
@@ -5968,7 +6063,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5968
6063
|
}, {
|
|
5969
6064
|
key: "createStatsAnalyzer",
|
|
5970
6065
|
value: function createStatsAnalyzer() {
|
|
5971
|
-
var
|
|
6066
|
+
var _this38 = this;
|
|
5972
6067
|
// @ts-ignore - config coming from registerPlugin
|
|
5973
6068
|
if (this.config.stats.enableStatsAnalyzer) {
|
|
5974
6069
|
// @ts-ignore - config coming from registerPlugin
|
|
@@ -5976,7 +6071,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
5976
6071
|
this.statsAnalyzer = new _statsAnalyzer.StatsAnalyzer(
|
|
5977
6072
|
// @ts-ignore - config coming from registerPlugin
|
|
5978
6073
|
this.config.stats, function (ssrc) {
|
|
5979
|
-
return
|
|
6074
|
+
return _this38.receiveSlotManager.findReceiveSlotBySsrc(ssrc);
|
|
5980
6075
|
}, this.networkQualityMonitor);
|
|
5981
6076
|
this.setupStatsAnalyzerEventHandlers();
|
|
5982
6077
|
this.networkQualityMonitor.on(_constants.EVENT_TRIGGERS.NETWORK_QUALITY, this.sendNetworkQualityEvent.bind(this));
|
|
@@ -6001,18 +6096,18 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6001
6096
|
* @returns {Promise<void>}
|
|
6002
6097
|
*/
|
|
6003
6098
|
function () {
|
|
6004
|
-
var _waitForRemoteSDPAnswer = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function
|
|
6099
|
+
var _waitForRemoteSDPAnswer = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee23() {
|
|
6005
6100
|
var LOG_HEADER, deferSDPAnswer;
|
|
6006
|
-
return _regenerator.default.wrap(function
|
|
6007
|
-
while (1) switch (
|
|
6101
|
+
return _regenerator.default.wrap(function _callee23$(_context23) {
|
|
6102
|
+
while (1) switch (_context23.prev = _context23.next) {
|
|
6008
6103
|
case 0:
|
|
6009
6104
|
LOG_HEADER = 'Meeting:index#addMedia():waitForRemoteSDPAnswer -->';
|
|
6010
6105
|
if (this.deferSDPAnswer) {
|
|
6011
|
-
|
|
6106
|
+
_context23.next = 4;
|
|
6012
6107
|
break;
|
|
6013
6108
|
}
|
|
6014
6109
|
_loggerProxy.default.logger.warn("".concat(LOG_HEADER, " offer not created yet"));
|
|
6015
|
-
return
|
|
6110
|
+
return _context23.abrupt("return", _promise.default.reject(new Error('waitForRemoteSDPAnswer() called before local sdp offer created')));
|
|
6016
6111
|
case 4:
|
|
6017
6112
|
deferSDPAnswer = this.deferSDPAnswer;
|
|
6018
6113
|
this.sdpResponseTimer = setTimeout(function () {
|
|
@@ -6020,12 +6115,12 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6020
6115
|
deferSDPAnswer.reject(new Error('Timed out waiting for REMOTE SDP ANSWER'));
|
|
6021
6116
|
}, _constants.ROAP_OFFER_ANSWER_EXCHANGE_TIMEOUT);
|
|
6022
6117
|
_loggerProxy.default.logger.info("".concat(LOG_HEADER, " waiting for REMOTE SDP ANSWER..."));
|
|
6023
|
-
return
|
|
6118
|
+
return _context23.abrupt("return", deferSDPAnswer.promise);
|
|
6024
6119
|
case 8:
|
|
6025
6120
|
case "end":
|
|
6026
|
-
return
|
|
6121
|
+
return _context23.stop();
|
|
6027
6122
|
}
|
|
6028
|
-
},
|
|
6123
|
+
}, _callee23, this);
|
|
6029
6124
|
}));
|
|
6030
6125
|
function waitForRemoteSDPAnswer() {
|
|
6031
6126
|
return _waitForRemoteSDPAnswer.apply(this, arguments);
|
|
@@ -6044,28 +6139,28 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6044
6139
|
}, {
|
|
6045
6140
|
key: "retryEstablishMediaConnectionWithForcedTurnDiscovery",
|
|
6046
6141
|
value: (function () {
|
|
6047
|
-
var _retryEstablishMediaConnectionWithForcedTurnDiscovery = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function
|
|
6142
|
+
var _retryEstablishMediaConnectionWithForcedTurnDiscovery = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee24(remoteMediaManagerConfig, bundlePolicy) {
|
|
6048
6143
|
var LOG_HEADER;
|
|
6049
|
-
return _regenerator.default.wrap(function
|
|
6050
|
-
while (1) switch (
|
|
6144
|
+
return _regenerator.default.wrap(function _callee24$(_context24) {
|
|
6145
|
+
while (1) switch (_context24.prev = _context24.next) {
|
|
6051
6146
|
case 0:
|
|
6052
6147
|
LOG_HEADER = 'Meeting:index#addMedia():retryEstablishMediaConnectionWithForcedTurnDiscovery -->';
|
|
6053
|
-
|
|
6054
|
-
|
|
6148
|
+
_context24.prev = 1;
|
|
6149
|
+
_context24.next = 4;
|
|
6055
6150
|
return this.establishMediaConnection(remoteMediaManagerConfig, bundlePolicy, true);
|
|
6056
6151
|
case 4:
|
|
6057
|
-
|
|
6152
|
+
_context24.next = 10;
|
|
6058
6153
|
break;
|
|
6059
6154
|
case 6:
|
|
6060
|
-
|
|
6061
|
-
|
|
6062
|
-
_loggerProxy.default.logger.error("".concat(LOG_HEADER, " retry with TURN-TLS failed, media connection unable to connect, "),
|
|
6063
|
-
throw
|
|
6155
|
+
_context24.prev = 6;
|
|
6156
|
+
_context24.t0 = _context24["catch"](1);
|
|
6157
|
+
_loggerProxy.default.logger.error("".concat(LOG_HEADER, " retry with TURN-TLS failed, media connection unable to connect, "), _context24.t0);
|
|
6158
|
+
throw _context24.t0;
|
|
6064
6159
|
case 10:
|
|
6065
6160
|
case "end":
|
|
6066
|
-
return
|
|
6161
|
+
return _context24.stop();
|
|
6067
6162
|
}
|
|
6068
|
-
},
|
|
6163
|
+
}, _callee24, this, [[1, 6]]);
|
|
6069
6164
|
}));
|
|
6070
6165
|
function retryEstablishMediaConnectionWithForcedTurnDiscovery(_x19, _x20) {
|
|
6071
6166
|
return _retryEstablishMediaConnectionWithForcedTurnDiscovery.apply(this, arguments);
|
|
@@ -6085,14 +6180,14 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6085
6180
|
}, {
|
|
6086
6181
|
key: "retryWithForcedTurnDiscovery",
|
|
6087
6182
|
value: (function () {
|
|
6088
|
-
var _retryWithForcedTurnDiscovery = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function
|
|
6183
|
+
var _retryWithForcedTurnDiscovery = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee25(remoteMediaManagerConfig, bundlePolicy) {
|
|
6089
6184
|
var LOG_HEADER;
|
|
6090
|
-
return _regenerator.default.wrap(function
|
|
6091
|
-
while (1) switch (
|
|
6185
|
+
return _regenerator.default.wrap(function _callee25$(_context25) {
|
|
6186
|
+
while (1) switch (_context25.prev = _context25.next) {
|
|
6092
6187
|
case 0:
|
|
6093
6188
|
this.retriedWithTurnServer = true;
|
|
6094
6189
|
LOG_HEADER = 'Meeting:index#addMedia():retryWithForcedTurnDiscovery -->';
|
|
6095
|
-
|
|
6190
|
+
_context25.next = 4;
|
|
6096
6191
|
return this.cleanUpBeforeRetryWithTurnServer();
|
|
6097
6192
|
case 4:
|
|
6098
6193
|
_metrics.default.sendBehavioralMetric(_constants2.default.ADD_MEDIA_RETRY, {
|
|
@@ -6102,22 +6197,22 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6102
6197
|
reason: 'forcingTurnTls'
|
|
6103
6198
|
});
|
|
6104
6199
|
if (!(this.state === _constants.MEETING_STATE.STATES.LEFT)) {
|
|
6105
|
-
|
|
6200
|
+
_context25.next = 9;
|
|
6106
6201
|
break;
|
|
6107
6202
|
}
|
|
6108
6203
|
_loggerProxy.default.logger.info("".concat(LOG_HEADER, " meeting state was LEFT after first attempt to establish media connection. Attempting to rejoin. "));
|
|
6109
|
-
|
|
6204
|
+
_context25.next = 9;
|
|
6110
6205
|
return this.join({
|
|
6111
6206
|
rejoin: true
|
|
6112
6207
|
});
|
|
6113
6208
|
case 9:
|
|
6114
|
-
|
|
6209
|
+
_context25.next = 11;
|
|
6115
6210
|
return this.retryEstablishMediaConnectionWithForcedTurnDiscovery(remoteMediaManagerConfig, bundlePolicy);
|
|
6116
6211
|
case 11:
|
|
6117
6212
|
case "end":
|
|
6118
|
-
return
|
|
6213
|
+
return _context25.stop();
|
|
6119
6214
|
}
|
|
6120
|
-
},
|
|
6215
|
+
}, _callee25, this);
|
|
6121
6216
|
}));
|
|
6122
6217
|
function retryWithForcedTurnDiscovery(_x21, _x22) {
|
|
6123
6218
|
return _retryWithForcedTurnDiscovery.apply(this, arguments);
|
|
@@ -6139,30 +6234,30 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6139
6234
|
}, {
|
|
6140
6235
|
key: "handleWaitForMediaConnectionConnectedError",
|
|
6141
6236
|
value: (function () {
|
|
6142
|
-
var _handleWaitForMediaConnectionConnectedError = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function
|
|
6237
|
+
var _handleWaitForMediaConnectionConnectedError = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee26(error, remoteMediaManagerConfig, bundlePolicy) {
|
|
6143
6238
|
var LOG_HEADER;
|
|
6144
|
-
return _regenerator.default.wrap(function
|
|
6145
|
-
while (1) switch (
|
|
6239
|
+
return _regenerator.default.wrap(function _callee26$(_context26) {
|
|
6240
|
+
while (1) switch (_context26.prev = _context26.next) {
|
|
6146
6241
|
case 0:
|
|
6147
6242
|
LOG_HEADER = 'Meeting:index#addMedia():handleWaitForMediaConnectionConnectedError -->'; // @ts-ignore - config coming from registerPlugin
|
|
6148
6243
|
if (this.turnServerUsed) {
|
|
6149
|
-
|
|
6244
|
+
_context26.next = 7;
|
|
6150
6245
|
break;
|
|
6151
6246
|
}
|
|
6152
6247
|
_loggerProxy.default.logger.info("".concat(LOG_HEADER, " error waiting for media to connect on UDP, TCP, retrying using TURN-TLS, "), error);
|
|
6153
|
-
|
|
6248
|
+
_context26.next = 5;
|
|
6154
6249
|
return this.retryWithForcedTurnDiscovery(remoteMediaManagerConfig, bundlePolicy);
|
|
6155
6250
|
case 5:
|
|
6156
|
-
|
|
6251
|
+
_context26.next = 9;
|
|
6157
6252
|
break;
|
|
6158
6253
|
case 7:
|
|
6159
6254
|
_loggerProxy.default.logger.error("".concat(LOG_HEADER, " error waiting for media to connect using UDP, TCP and TURN-TLS"), error);
|
|
6160
6255
|
throw new _webexErrors.AddMediaFailed();
|
|
6161
6256
|
case 9:
|
|
6162
6257
|
case "end":
|
|
6163
|
-
return
|
|
6258
|
+
return _context26.stop();
|
|
6164
6259
|
}
|
|
6165
|
-
},
|
|
6260
|
+
}, _callee26, this);
|
|
6166
6261
|
}));
|
|
6167
6262
|
function handleWaitForMediaConnectionConnectedError(_x23, _x24, _x25) {
|
|
6168
6263
|
return _handleWaitForMediaConnectionConnectedError.apply(this, arguments);
|
|
@@ -6170,44 +6265,38 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6170
6265
|
return handleWaitForMediaConnectionConnectedError;
|
|
6171
6266
|
}()
|
|
6172
6267
|
/**
|
|
6173
|
-
*
|
|
6268
|
+
* Performs TURN discovery as a separate call to the Locus /media API
|
|
6174
6269
|
*
|
|
6175
|
-
* @
|
|
6176
|
-
* @param {
|
|
6177
|
-
* @
|
|
6178
|
-
* @param {boolean} [isForced] - let isForced be true to do turn discovery regardless of reachability results
|
|
6179
|
-
* @returns {Promise<void>}
|
|
6270
|
+
* @param {boolean} isRetry
|
|
6271
|
+
* @param {boolean} isForced
|
|
6272
|
+
* @returns {Promise}
|
|
6180
6273
|
*/
|
|
6181
6274
|
)
|
|
6182
6275
|
}, {
|
|
6183
|
-
key: "
|
|
6276
|
+
key: "doTurnDiscovery",
|
|
6184
6277
|
value: (function () {
|
|
6185
|
-
var
|
|
6186
|
-
var
|
|
6187
|
-
return _regenerator.default.wrap(function
|
|
6188
|
-
while (1) switch (
|
|
6278
|
+
var _doTurnDiscovery = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee27(isRetry, isForced) {
|
|
6279
|
+
var cdl, turnDiscoveryResult;
|
|
6280
|
+
return _regenerator.default.wrap(function _callee27$(_context27) {
|
|
6281
|
+
while (1) switch (_context27.prev = _context27.next) {
|
|
6189
6282
|
case 0:
|
|
6190
|
-
LOG_HEADER = 'Meeting:index#addMedia():establishMediaConnection -->'; // @ts-ignore
|
|
6191
|
-
cdl = this.webex.internal.newMetrics.callDiagnosticLatencies;
|
|
6192
|
-
isRetry = this.retriedWithTurnServer;
|
|
6193
|
-
_context26.prev = 3;
|
|
6194
6283
|
// @ts-ignore
|
|
6284
|
+
cdl = this.webex.internal.newMetrics.callDiagnosticLatencies; // @ts-ignore
|
|
6195
6285
|
this.webex.internal.newMetrics.submitInternalEvent({
|
|
6196
6286
|
name: 'internal.client.add-media.turn-discovery.start'
|
|
6197
6287
|
});
|
|
6198
|
-
|
|
6288
|
+
_context27.next = 4;
|
|
6199
6289
|
return this.roap.doTurnDiscovery(this, isRetry, isForced);
|
|
6200
|
-
case
|
|
6201
|
-
|
|
6202
|
-
this.turnDiscoverySkippedReason =
|
|
6290
|
+
case 4:
|
|
6291
|
+
turnDiscoveryResult = _context27.sent;
|
|
6292
|
+
this.turnDiscoverySkippedReason = turnDiscoveryResult === null || turnDiscoveryResult === void 0 ? void 0 : turnDiscoveryResult.turnDiscoverySkippedReason;
|
|
6203
6293
|
this.turnServerUsed = !this.turnDiscoverySkippedReason;
|
|
6204
6294
|
|
|
6205
6295
|
// @ts-ignore
|
|
6206
6296
|
this.webex.internal.newMetrics.submitInternalEvent({
|
|
6207
6297
|
name: 'internal.client.add-media.turn-discovery.end'
|
|
6208
6298
|
});
|
|
6209
|
-
|
|
6210
|
-
if (this.turnServerUsed && turnServerInfo) {
|
|
6299
|
+
if (this.turnServerUsed && turnDiscoveryResult.turnServerInfo) {
|
|
6211
6300
|
_metrics.default.sendBehavioralMetric(_constants2.default.TURN_DISCOVERY_LATENCY, {
|
|
6212
6301
|
correlation_id: this.correlationId,
|
|
6213
6302
|
latency: cdl.getTurnDiscoveryTime(),
|
|
@@ -6215,13 +6304,57 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6215
6304
|
retriedWithTurnServer: this.retriedWithTurnServer
|
|
6216
6305
|
});
|
|
6217
6306
|
}
|
|
6218
|
-
|
|
6307
|
+
return _context27.abrupt("return", turnDiscoveryResult);
|
|
6308
|
+
case 10:
|
|
6309
|
+
case "end":
|
|
6310
|
+
return _context27.stop();
|
|
6311
|
+
}
|
|
6312
|
+
}, _callee27, this);
|
|
6313
|
+
}));
|
|
6314
|
+
function doTurnDiscovery(_x26, _x27) {
|
|
6315
|
+
return _doTurnDiscovery.apply(this, arguments);
|
|
6316
|
+
}
|
|
6317
|
+
return doTurnDiscovery;
|
|
6318
|
+
}()
|
|
6319
|
+
/**
|
|
6320
|
+
* Does TURN discovery, SDP offer/answer exhange, establishes ICE connection and DTLS handshake.
|
|
6321
|
+
*
|
|
6322
|
+
* @private
|
|
6323
|
+
* @param {RemoteMediaManagerConfiguration} [remoteMediaManagerConfig]
|
|
6324
|
+
* @param {BundlePolicy} [bundlePolicy]
|
|
6325
|
+
* @param {boolean} [isForced] - let isForced be true to do turn discovery regardless of reachability results
|
|
6326
|
+
* @param {TurnServerInfo} [turnServerInfo]
|
|
6327
|
+
* @returns {Promise<void>}
|
|
6328
|
+
*/
|
|
6329
|
+
)
|
|
6330
|
+
}, {
|
|
6331
|
+
key: "establishMediaConnection",
|
|
6332
|
+
value: (function () {
|
|
6333
|
+
var _establishMediaConnection = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee28(remoteMediaManagerConfig, bundlePolicy, isForced, turnServerInfo) {
|
|
6334
|
+
var LOG_HEADER, isRetry, _yield$this$doTurnDis, mc;
|
|
6335
|
+
return _regenerator.default.wrap(function _callee28$(_context28) {
|
|
6336
|
+
while (1) switch (_context28.prev = _context28.next) {
|
|
6337
|
+
case 0:
|
|
6338
|
+
LOG_HEADER = 'Meeting:index#addMedia():establishMediaConnection -->';
|
|
6339
|
+
isRetry = this.retriedWithTurnServer;
|
|
6340
|
+
_context28.prev = 2;
|
|
6341
|
+
if (turnServerInfo) {
|
|
6342
|
+
_context28.next = 8;
|
|
6343
|
+
break;
|
|
6344
|
+
}
|
|
6345
|
+
_context28.next = 6;
|
|
6346
|
+
return this.doTurnDiscovery(isRetry, isForced);
|
|
6347
|
+
case 6:
|
|
6348
|
+
_yield$this$doTurnDis = _context28.sent;
|
|
6349
|
+
turnServerInfo = _yield$this$doTurnDis.turnServerInfo;
|
|
6350
|
+
case 8:
|
|
6351
|
+
_context28.next = 10;
|
|
6219
6352
|
return this.createMediaConnection(turnServerInfo, bundlePolicy);
|
|
6220
|
-
case
|
|
6221
|
-
mc =
|
|
6353
|
+
case 10:
|
|
6354
|
+
mc = _context28.sent;
|
|
6222
6355
|
_loggerProxy.default.logger.info("".concat(LOG_HEADER, " media connection created"));
|
|
6223
6356
|
if (!this.isMultistream) {
|
|
6224
|
-
|
|
6357
|
+
_context28.next = 20;
|
|
6225
6358
|
break;
|
|
6226
6359
|
}
|
|
6227
6360
|
this.remoteMediaManager = new _remoteMediaManager.RemoteMediaManager(this.receiveSlotManager, this.mediaRequestManagers, remoteMediaManagerConfig);
|
|
@@ -6229,42 +6362,42 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6229
6362
|
this.forwardEvent(this.remoteMediaManager, _remoteMediaManager.Event.InterpretationAudioCreated, _constants.EVENT_TRIGGERS.REMOTE_MEDIA_INTERPRETATION_AUDIO_CREATED);
|
|
6230
6363
|
this.forwardEvent(this.remoteMediaManager, _remoteMediaManager.Event.ScreenShareAudioCreated, _constants.EVENT_TRIGGERS.REMOTE_MEDIA_SCREEN_SHARE_AUDIO_CREATED);
|
|
6231
6364
|
this.forwardEvent(this.remoteMediaManager, _remoteMediaManager.Event.VideoLayoutChanged, _constants.EVENT_TRIGGERS.REMOTE_MEDIA_VIDEO_LAYOUT_CHANGED);
|
|
6232
|
-
|
|
6365
|
+
_context28.next = 20;
|
|
6233
6366
|
return this.remoteMediaManager.start();
|
|
6234
|
-
case
|
|
6235
|
-
|
|
6367
|
+
case 20:
|
|
6368
|
+
_context28.next = 22;
|
|
6236
6369
|
return mc.initiateOffer();
|
|
6237
|
-
case
|
|
6238
|
-
|
|
6370
|
+
case 22:
|
|
6371
|
+
_context28.next = 24;
|
|
6239
6372
|
return this.waitForRemoteSDPAnswer();
|
|
6240
|
-
case
|
|
6373
|
+
case 24:
|
|
6241
6374
|
this.handleMediaLogging(this.mediaProperties);
|
|
6242
|
-
|
|
6375
|
+
_context28.next = 31;
|
|
6243
6376
|
break;
|
|
6244
|
-
case
|
|
6245
|
-
|
|
6246
|
-
|
|
6247
|
-
_loggerProxy.default.logger.error("".concat(LOG_HEADER, " error establishing media connection, "),
|
|
6248
|
-
throw
|
|
6249
|
-
case
|
|
6250
|
-
|
|
6251
|
-
|
|
6377
|
+
case 27:
|
|
6378
|
+
_context28.prev = 27;
|
|
6379
|
+
_context28.t0 = _context28["catch"](2);
|
|
6380
|
+
_loggerProxy.default.logger.error("".concat(LOG_HEADER, " error establishing media connection, "), _context28.t0);
|
|
6381
|
+
throw _context28.t0;
|
|
6382
|
+
case 31:
|
|
6383
|
+
_context28.prev = 31;
|
|
6384
|
+
_context28.next = 34;
|
|
6252
6385
|
return this.waitForMediaConnectionConnected();
|
|
6253
|
-
case
|
|
6254
|
-
|
|
6386
|
+
case 34:
|
|
6387
|
+
_context28.next = 40;
|
|
6255
6388
|
break;
|
|
6256
|
-
case
|
|
6257
|
-
|
|
6258
|
-
|
|
6259
|
-
|
|
6260
|
-
return this.handleWaitForMediaConnectionConnectedError(
|
|
6261
|
-
case
|
|
6389
|
+
case 36:
|
|
6390
|
+
_context28.prev = 36;
|
|
6391
|
+
_context28.t1 = _context28["catch"](31);
|
|
6392
|
+
_context28.next = 40;
|
|
6393
|
+
return this.handleWaitForMediaConnectionConnectedError(_context28.t1, remoteMediaManagerConfig, bundlePolicy);
|
|
6394
|
+
case 40:
|
|
6262
6395
|
case "end":
|
|
6263
|
-
return
|
|
6396
|
+
return _context28.stop();
|
|
6264
6397
|
}
|
|
6265
|
-
},
|
|
6398
|
+
}, _callee28, this, [[2, 27], [31, 36]]);
|
|
6266
6399
|
}));
|
|
6267
|
-
function establishMediaConnection(
|
|
6400
|
+
function establishMediaConnection(_x28, _x29, _x30, _x31) {
|
|
6268
6401
|
return _establishMediaConnection.apply(this, arguments);
|
|
6269
6402
|
}
|
|
6270
6403
|
return establishMediaConnection;
|
|
@@ -6279,22 +6412,22 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6279
6412
|
}, {
|
|
6280
6413
|
key: "cleanUpOnAddMediaFailure",
|
|
6281
6414
|
value: (function () {
|
|
6282
|
-
var _cleanUpOnAddMediaFailure = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function
|
|
6283
|
-
return _regenerator.default.wrap(function
|
|
6284
|
-
while (1) switch (
|
|
6415
|
+
var _cleanUpOnAddMediaFailure = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee29() {
|
|
6416
|
+
return _regenerator.default.wrap(function _callee29$(_context29) {
|
|
6417
|
+
while (1) switch (_context29.prev = _context29.next) {
|
|
6285
6418
|
case 0:
|
|
6286
6419
|
if (!this.statsAnalyzer) {
|
|
6287
|
-
|
|
6420
|
+
_context29.next = 3;
|
|
6288
6421
|
break;
|
|
6289
6422
|
}
|
|
6290
|
-
|
|
6423
|
+
_context29.next = 3;
|
|
6291
6424
|
return this.statsAnalyzer.stopAnalyzer();
|
|
6292
6425
|
case 3:
|
|
6293
6426
|
this.statsAnalyzer = null;
|
|
6294
6427
|
|
|
6295
6428
|
// when media fails, we want to upload a webrtc dump to see whats going on
|
|
6296
6429
|
// this function is async, but returns once the stats have been gathered
|
|
6297
|
-
|
|
6430
|
+
_context29.next = 6;
|
|
6298
6431
|
return this.forceSendStatsReport({
|
|
6299
6432
|
callFrom: 'addMedia'
|
|
6300
6433
|
});
|
|
@@ -6305,9 +6438,9 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6305
6438
|
}
|
|
6306
6439
|
case 7:
|
|
6307
6440
|
case "end":
|
|
6308
|
-
return
|
|
6441
|
+
return _context29.stop();
|
|
6309
6442
|
}
|
|
6310
|
-
},
|
|
6443
|
+
}, _callee29, this);
|
|
6311
6444
|
}));
|
|
6312
6445
|
function cleanUpOnAddMediaFailure() {
|
|
6313
6446
|
return _cleanUpOnAddMediaFailure.apply(this, arguments);
|
|
@@ -6325,11 +6458,11 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6325
6458
|
}, {
|
|
6326
6459
|
key: "cleanUpBeforeRetryWithTurnServer",
|
|
6327
6460
|
value: (function () {
|
|
6328
|
-
var _cleanUpBeforeRetryWithTurnServer = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function
|
|
6329
|
-
return _regenerator.default.wrap(function
|
|
6330
|
-
while (1) switch (
|
|
6461
|
+
var _cleanUpBeforeRetryWithTurnServer = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee30() {
|
|
6462
|
+
return _regenerator.default.wrap(function _callee30$(_context30) {
|
|
6463
|
+
while (1) switch (_context30.prev = _context30.next) {
|
|
6331
6464
|
case 0:
|
|
6332
|
-
|
|
6465
|
+
_context30.next = 2;
|
|
6333
6466
|
return this.forceSendStatsReport({
|
|
6334
6467
|
callFrom: 'cleanUpBeforeRetryWithTurnServer'
|
|
6335
6468
|
});
|
|
@@ -6349,9 +6482,9 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6349
6482
|
}
|
|
6350
6483
|
case 3:
|
|
6351
6484
|
case "end":
|
|
6352
|
-
return
|
|
6485
|
+
return _context30.stop();
|
|
6353
6486
|
}
|
|
6354
|
-
},
|
|
6487
|
+
}, _callee30, this);
|
|
6355
6488
|
}));
|
|
6356
6489
|
function cleanUpBeforeRetryWithTurnServer() {
|
|
6357
6490
|
return _cleanUpBeforeRetryWithTurnServer.apply(this, arguments);
|
|
@@ -6362,6 +6495,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6362
6495
|
* Creates a media connection to the server. Media connection is required for sending or receiving any audio/video.
|
|
6363
6496
|
*
|
|
6364
6497
|
* @param {AddMediaOptions} options
|
|
6498
|
+
* @param {TurnServerInfo} turnServerInfo - TURN server information (used only internally by the SDK)
|
|
6365
6499
|
* @returns {Promise<void>}
|
|
6366
6500
|
* @public
|
|
6367
6501
|
* @memberof Meeting
|
|
@@ -6370,9 +6504,10 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6370
6504
|
}, {
|
|
6371
6505
|
key: "addMedia",
|
|
6372
6506
|
value: (function () {
|
|
6373
|
-
var _addMedia = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function
|
|
6507
|
+
var _addMedia = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee31() {
|
|
6374
6508
|
var _this$webex$meetings$2, _this$webex$meetings$3;
|
|
6375
6509
|
var options,
|
|
6510
|
+
turnServerInfo,
|
|
6376
6511
|
LOG_HEADER,
|
|
6377
6512
|
localStreams,
|
|
6378
6513
|
_options$audioEnabled,
|
|
@@ -6385,7 +6520,6 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6385
6520
|
shareVideoEnabled,
|
|
6386
6521
|
remoteMediaManagerConfig,
|
|
6387
6522
|
bundlePolicy,
|
|
6388
|
-
allowMediaInLobby,
|
|
6389
6523
|
_this$remoteMediaMana,
|
|
6390
6524
|
connectionType,
|
|
6391
6525
|
reachabilityStats,
|
|
@@ -6411,38 +6545,39 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6411
6545
|
_this$mediaProperties39,
|
|
6412
6546
|
_this$mediaProperties40,
|
|
6413
6547
|
reachabilityMetrics,
|
|
6414
|
-
|
|
6415
|
-
return _regenerator.default.wrap(function
|
|
6416
|
-
while (1) switch (
|
|
6548
|
+
_args31 = arguments;
|
|
6549
|
+
return _regenerator.default.wrap(function _callee31$(_context31) {
|
|
6550
|
+
while (1) switch (_context31.prev = _context31.next) {
|
|
6417
6551
|
case 0:
|
|
6418
|
-
options =
|
|
6552
|
+
options = _args31.length > 0 && _args31[0] !== undefined ? _args31[0] : {};
|
|
6553
|
+
turnServerInfo = _args31.length > 1 && _args31[1] !== undefined ? _args31[1] : undefined;
|
|
6419
6554
|
this.retriedWithTurnServer = false;
|
|
6420
6555
|
this.hasMediaConnectionConnectedAtLeastOnce = false;
|
|
6421
6556
|
LOG_HEADER = 'Meeting:index#addMedia -->';
|
|
6422
|
-
_loggerProxy.default.logger.info("".concat(LOG_HEADER, " called with: ").concat((0, _stringify.default)(options)));
|
|
6557
|
+
_loggerProxy.default.logger.info("".concat(LOG_HEADER, " called with: ").concat((0, _stringify.default)(options), ", ").concat((0, _stringify.default)(turnServerInfo)));
|
|
6423
6558
|
if (!(options.allowMediaInLobby !== true && this.meetingState !== _constants.FULL_STATE.ACTIVE)) {
|
|
6424
|
-
|
|
6559
|
+
_context31.next = 8;
|
|
6425
6560
|
break;
|
|
6426
6561
|
}
|
|
6427
6562
|
throw new _webexErrors.MeetingNotActiveError();
|
|
6428
|
-
case
|
|
6563
|
+
case 8:
|
|
6429
6564
|
if (!_util.default.isUserInLeftState(this.locusInfo)) {
|
|
6430
|
-
|
|
6565
|
+
_context31.next = 10;
|
|
6431
6566
|
break;
|
|
6432
6567
|
}
|
|
6433
6568
|
throw new _webexErrors.UserNotJoinedError();
|
|
6434
|
-
case
|
|
6435
|
-
localStreams = options.localStreams, _options$audioEnabled = options.audioEnabled, audioEnabled = _options$audioEnabled === void 0 ? true : _options$audioEnabled, _options$videoEnabled = options.videoEnabled, videoEnabled = _options$videoEnabled === void 0 ? true : _options$videoEnabled, _options$shareAudioEn = options.shareAudioEnabled, shareAudioEnabled = _options$shareAudioEn === void 0 ? true : _options$shareAudioEn, _options$shareVideoEn = options.shareVideoEnabled, shareVideoEnabled = _options$shareVideoEn === void 0 ? true : _options$shareVideoEn, remoteMediaManagerConfig = options.remoteMediaManagerConfig, bundlePolicy = options.bundlePolicy
|
|
6569
|
+
case 10:
|
|
6570
|
+
localStreams = options.localStreams, _options$audioEnabled = options.audioEnabled, audioEnabled = _options$audioEnabled === void 0 ? true : _options$audioEnabled, _options$videoEnabled = options.videoEnabled, videoEnabled = _options$videoEnabled === void 0 ? true : _options$videoEnabled, _options$shareAudioEn = options.shareAudioEnabled, shareAudioEnabled = _options$shareAudioEn === void 0 ? true : _options$shareAudioEn, _options$shareVideoEn = options.shareVideoEnabled, shareVideoEnabled = _options$shareVideoEn === void 0 ? true : _options$shareVideoEn, remoteMediaManagerConfig = options.remoteMediaManagerConfig, bundlePolicy = options.bundlePolicy;
|
|
6436
6571
|
this.allowMediaInLobby = options === null || options === void 0 ? void 0 : options.allowMediaInLobby;
|
|
6437
6572
|
|
|
6438
6573
|
// If the user is unjoined or guest waiting in lobby dont allow the user to addMedia
|
|
6439
6574
|
// @ts-ignore - isUserUnadmitted coming from SelfUtil
|
|
6440
|
-
if (!(this.isUserUnadmitted && !this.wirelessShare && !allowMediaInLobby)) {
|
|
6441
|
-
|
|
6575
|
+
if (!(this.isUserUnadmitted && !this.wirelessShare && !this.allowMediaInLobby)) {
|
|
6576
|
+
_context31.next = 14;
|
|
6442
6577
|
break;
|
|
6443
6578
|
}
|
|
6444
6579
|
throw new _webexErrors.UserInLobbyError();
|
|
6445
|
-
case
|
|
6580
|
+
case 14:
|
|
6446
6581
|
// @ts-ignore
|
|
6447
6582
|
this.webex.internal.newMetrics.submitClientEvent({
|
|
6448
6583
|
name: 'client.media.capabilities',
|
|
@@ -6497,33 +6632,33 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6497
6632
|
});
|
|
6498
6633
|
this.audio = (0, _muteState.createMuteState)(_constants.AUDIO, this, audioEnabled);
|
|
6499
6634
|
this.video = (0, _muteState.createMuteState)(_constants.VIDEO, this, videoEnabled);
|
|
6500
|
-
|
|
6501
|
-
|
|
6635
|
+
_context31.prev = 19;
|
|
6636
|
+
_context31.next = 22;
|
|
6502
6637
|
return this.setUpLocalStreamReferences(localStreams);
|
|
6503
|
-
case
|
|
6638
|
+
case 22:
|
|
6504
6639
|
this.setMercuryListener();
|
|
6505
6640
|
this.createStatsAnalyzer();
|
|
6506
|
-
|
|
6507
|
-
return this.establishMediaConnection(remoteMediaManagerConfig, bundlePolicy, false);
|
|
6508
|
-
case
|
|
6509
|
-
|
|
6641
|
+
_context31.next = 26;
|
|
6642
|
+
return this.establishMediaConnection(remoteMediaManagerConfig, bundlePolicy, false, turnServerInfo);
|
|
6643
|
+
case 26:
|
|
6644
|
+
_context31.next = 28;
|
|
6510
6645
|
return Meeting.handleDeviceLogging();
|
|
6511
|
-
case
|
|
6646
|
+
case 28:
|
|
6512
6647
|
if (!this.mediaProperties.hasLocalShareStream()) {
|
|
6513
|
-
|
|
6648
|
+
_context31.next = 31;
|
|
6514
6649
|
break;
|
|
6515
6650
|
}
|
|
6516
|
-
|
|
6651
|
+
_context31.next = 31;
|
|
6517
6652
|
return this.enqueueScreenShareFloorRequest();
|
|
6518
|
-
case
|
|
6519
|
-
|
|
6653
|
+
case 31:
|
|
6654
|
+
_context31.next = 33;
|
|
6520
6655
|
return this.mediaProperties.getCurrentConnectionType();
|
|
6521
|
-
case
|
|
6522
|
-
connectionType =
|
|
6523
|
-
|
|
6656
|
+
case 33:
|
|
6657
|
+
connectionType = _context31.sent;
|
|
6658
|
+
_context31.next = 36;
|
|
6524
6659
|
return this.webex.meetings.reachability.getReachabilityMetrics();
|
|
6525
|
-
case
|
|
6526
|
-
reachabilityStats =
|
|
6660
|
+
case 36:
|
|
6661
|
+
reachabilityStats = _context31.sent;
|
|
6527
6662
|
_metrics.default.sendBehavioralMetric(_constants2.default.ADD_MEDIA_SUCCESS, _objectSpread({
|
|
6528
6663
|
correlation_id: this.correlationId,
|
|
6529
6664
|
locus_id: this.locusUrl.split('/').pop(),
|
|
@@ -6542,24 +6677,24 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6542
6677
|
|
|
6543
6678
|
// We can log ReceiveSlot SSRCs only after the SDP exchange, so doing it here:
|
|
6544
6679
|
(_this$remoteMediaMana = this.remoteMediaManager) === null || _this$remoteMediaMana === void 0 ? void 0 : _this$remoteMediaMana.logAllReceiveSlots();
|
|
6545
|
-
|
|
6680
|
+
_context31.next = 55;
|
|
6546
6681
|
break;
|
|
6547
|
-
case
|
|
6548
|
-
|
|
6549
|
-
|
|
6550
|
-
_loggerProxy.default.logger.error("".concat(LOG_HEADER, " failed to establish media connection: "),
|
|
6682
|
+
case 43:
|
|
6683
|
+
_context31.prev = 43;
|
|
6684
|
+
_context31.t0 = _context31["catch"](19);
|
|
6685
|
+
_loggerProxy.default.logger.error("".concat(LOG_HEADER, " failed to establish media connection: "), _context31.t0);
|
|
6551
6686
|
|
|
6552
6687
|
// @ts-ignore
|
|
6553
|
-
|
|
6688
|
+
_context31.next = 48;
|
|
6554
6689
|
return this.webex.meetings.reachability.getReachabilityMetrics();
|
|
6555
|
-
case
|
|
6556
|
-
reachabilityMetrics =
|
|
6690
|
+
case 48:
|
|
6691
|
+
reachabilityMetrics = _context31.sent;
|
|
6557
6692
|
_metrics.default.sendBehavioralMetric(_constants2.default.ADD_MEDIA_FAILURE, _objectSpread({
|
|
6558
6693
|
correlation_id: this.correlationId,
|
|
6559
6694
|
locus_id: this.locusUrl.split('/').pop(),
|
|
6560
|
-
reason:
|
|
6561
|
-
stack:
|
|
6562
|
-
code:
|
|
6695
|
+
reason: _context31.t0.message,
|
|
6696
|
+
stack: _context31.t0.stack,
|
|
6697
|
+
code: _context31.t0.code,
|
|
6563
6698
|
turnDiscoverySkippedReason: this.turnDiscoverySkippedReason,
|
|
6564
6699
|
turnServerUsed: this.turnServerUsed,
|
|
6565
6700
|
retriedWithTurnServer: this.retriedWithTurnServer,
|
|
@@ -6568,25 +6703,25 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6568
6703
|
connectionState: ((_this$mediaProperties27 = this.mediaProperties.webrtcMediaConnection) === null || _this$mediaProperties27 === void 0 ? void 0 : (_this$mediaProperties28 = _this$mediaProperties27.multistreamConnection) === null || _this$mediaProperties28 === void 0 ? void 0 : (_this$mediaProperties29 = _this$mediaProperties28.pc) === null || _this$mediaProperties29 === void 0 ? void 0 : (_this$mediaProperties30 = _this$mediaProperties29.pc) === null || _this$mediaProperties30 === void 0 ? void 0 : _this$mediaProperties30.connectionState) || ((_this$mediaProperties31 = this.mediaProperties.webrtcMediaConnection) === null || _this$mediaProperties31 === void 0 ? void 0 : (_this$mediaProperties32 = _this$mediaProperties31.mediaConnection) === null || _this$mediaProperties32 === void 0 ? void 0 : (_this$mediaProperties33 = _this$mediaProperties32.pc) === null || _this$mediaProperties33 === void 0 ? void 0 : _this$mediaProperties33.connectionState) || 'unknown',
|
|
6569
6704
|
iceConnectionState: ((_this$mediaProperties34 = this.mediaProperties.webrtcMediaConnection) === null || _this$mediaProperties34 === void 0 ? void 0 : (_this$mediaProperties35 = _this$mediaProperties34.multistreamConnection) === null || _this$mediaProperties35 === void 0 ? void 0 : (_this$mediaProperties36 = _this$mediaProperties35.pc) === null || _this$mediaProperties36 === void 0 ? void 0 : (_this$mediaProperties37 = _this$mediaProperties36.pc) === null || _this$mediaProperties37 === void 0 ? void 0 : _this$mediaProperties37.iceConnectionState) || ((_this$mediaProperties38 = this.mediaProperties.webrtcMediaConnection) === null || _this$mediaProperties38 === void 0 ? void 0 : (_this$mediaProperties39 = _this$mediaProperties38.mediaConnection) === null || _this$mediaProperties39 === void 0 ? void 0 : (_this$mediaProperties40 = _this$mediaProperties39.pc) === null || _this$mediaProperties40 === void 0 ? void 0 : _this$mediaProperties40.iceConnectionState) || 'unknown'
|
|
6570
6705
|
}, reachabilityMetrics));
|
|
6571
|
-
|
|
6706
|
+
_context31.next = 52;
|
|
6572
6707
|
return this.cleanUpOnAddMediaFailure();
|
|
6573
|
-
case
|
|
6708
|
+
case 52:
|
|
6574
6709
|
// Upload logs on error while adding media
|
|
6575
6710
|
_triggerProxy.default.trigger(this, {
|
|
6576
6711
|
file: 'meeting/index',
|
|
6577
6712
|
function: 'addMedia'
|
|
6578
6713
|
}, _constants.EVENTS.REQUEST_UPLOAD_LOGS, this);
|
|
6579
|
-
if (
|
|
6714
|
+
if (_context31.t0 instanceof _internalMediaCore.Errors.SdpError) {
|
|
6580
6715
|
this.leave({
|
|
6581
6716
|
reason: _constants.MEETING_REMOVED_REASON.MEETING_CONNECTION_FAILED
|
|
6582
6717
|
});
|
|
6583
6718
|
}
|
|
6584
|
-
throw
|
|
6585
|
-
case
|
|
6719
|
+
throw _context31.t0;
|
|
6720
|
+
case 55:
|
|
6586
6721
|
case "end":
|
|
6587
|
-
return
|
|
6722
|
+
return _context31.stop();
|
|
6588
6723
|
}
|
|
6589
|
-
},
|
|
6724
|
+
}, _callee31, this, [[19, 43]]);
|
|
6590
6725
|
}));
|
|
6591
6726
|
function addMedia() {
|
|
6592
6727
|
return _addMedia.apply(this, arguments);
|
|
@@ -6618,7 +6753,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6618
6753
|
* @memberof Meeting
|
|
6619
6754
|
*/
|
|
6620
6755
|
function enqueueMediaUpdate(mediaUpdateType) {
|
|
6621
|
-
var
|
|
6756
|
+
var _this39 = this;
|
|
6622
6757
|
var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
6623
6758
|
var canUpdateMediaNow = this.canUpdateMedia();
|
|
6624
6759
|
return new _promise.default(function (resolve, reject) {
|
|
@@ -6629,9 +6764,9 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6629
6764
|
options: options
|
|
6630
6765
|
};
|
|
6631
6766
|
_loggerProxy.default.logger.log("Meeting:index#enqueueMediaUpdate --> enqueuing media update type=".concat(mediaUpdateType));
|
|
6632
|
-
|
|
6767
|
+
_this39.queuedMediaUpdates.push(queueItem);
|
|
6633
6768
|
if (canUpdateMediaNow) {
|
|
6634
|
-
|
|
6769
|
+
_this39.processNextQueuedMediaUpdate();
|
|
6635
6770
|
}
|
|
6636
6771
|
});
|
|
6637
6772
|
}
|
|
@@ -6654,35 +6789,35 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6654
6789
|
* @memberof Meeting
|
|
6655
6790
|
*/
|
|
6656
6791
|
function () {
|
|
6657
|
-
var _updateMedia = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function
|
|
6792
|
+
var _updateMedia = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee32(options) {
|
|
6658
6793
|
var audioEnabled, videoEnabled, shareAudioEnabled, shareVideoEnabled;
|
|
6659
|
-
return _regenerator.default.wrap(function
|
|
6660
|
-
while (1) switch (
|
|
6794
|
+
return _regenerator.default.wrap(function _callee32$(_context32) {
|
|
6795
|
+
while (1) switch (_context32.prev = _context32.next) {
|
|
6661
6796
|
case 0:
|
|
6662
6797
|
this.checkMediaConnection();
|
|
6663
6798
|
audioEnabled = options.audioEnabled, videoEnabled = options.videoEnabled, shareAudioEnabled = options.shareAudioEnabled, shareVideoEnabled = options.shareVideoEnabled;
|
|
6664
6799
|
_loggerProxy.default.logger.log("Meeting:index#updateMedia --> called with options=".concat((0, _stringify.default)(options)));
|
|
6665
6800
|
if (this.canUpdateMedia()) {
|
|
6666
|
-
|
|
6801
|
+
_context32.next = 5;
|
|
6667
6802
|
break;
|
|
6668
6803
|
}
|
|
6669
|
-
return
|
|
6804
|
+
return _context32.abrupt("return", this.enqueueMediaUpdate(MEDIA_UPDATE_TYPE.UPDATE_MEDIA, options));
|
|
6670
6805
|
case 5:
|
|
6671
6806
|
if (!this.isMultistream) {
|
|
6672
|
-
|
|
6807
|
+
_context32.next = 10;
|
|
6673
6808
|
break;
|
|
6674
6809
|
}
|
|
6675
6810
|
if (!(shareAudioEnabled !== undefined || shareVideoEnabled !== undefined)) {
|
|
6676
|
-
|
|
6811
|
+
_context32.next = 8;
|
|
6677
6812
|
break;
|
|
6678
6813
|
}
|
|
6679
6814
|
throw new Error('toggling shareAudioEnabled or shareVideoEnabled in a multistream meeting is not supported, to control receiving screen share call meeting.remoteMediaManager.setLayout() with appropriate layout');
|
|
6680
6815
|
case 8:
|
|
6681
|
-
|
|
6816
|
+
_context32.next = 12;
|
|
6682
6817
|
break;
|
|
6683
6818
|
case 10:
|
|
6684
6819
|
if (!(shareAudioEnabled !== undefined)) {
|
|
6685
|
-
|
|
6820
|
+
_context32.next = 12;
|
|
6686
6821
|
break;
|
|
6687
6822
|
}
|
|
6688
6823
|
throw new Error('toggling shareAudioEnabled in a transcoded meeting is not supported as of now');
|
|
@@ -6707,20 +6842,20 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6707
6842
|
this.mediaProperties.mediaDirection.receiveShare = !!(shareAudioEnabled || shareVideoEnabled);
|
|
6708
6843
|
}
|
|
6709
6844
|
if (this.isMultistream) {
|
|
6710
|
-
|
|
6845
|
+
_context32.next = 18;
|
|
6711
6846
|
break;
|
|
6712
6847
|
}
|
|
6713
|
-
|
|
6848
|
+
_context32.next = 18;
|
|
6714
6849
|
return this.updateTranscodedMediaConnection();
|
|
6715
6850
|
case 18:
|
|
6716
|
-
return
|
|
6851
|
+
return _context32.abrupt("return", undefined);
|
|
6717
6852
|
case 19:
|
|
6718
6853
|
case "end":
|
|
6719
|
-
return
|
|
6854
|
+
return _context32.stop();
|
|
6720
6855
|
}
|
|
6721
|
-
},
|
|
6856
|
+
}, _callee32, this);
|
|
6722
6857
|
}));
|
|
6723
|
-
function updateMedia(
|
|
6858
|
+
function updateMedia(_x32) {
|
|
6724
6859
|
return _updateMedia.apply(this, arguments);
|
|
6725
6860
|
}
|
|
6726
6861
|
return updateMedia;
|
|
@@ -6736,7 +6871,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6736
6871
|
}, {
|
|
6737
6872
|
key: "acknowledge",
|
|
6738
6873
|
value: function acknowledge(type) {
|
|
6739
|
-
var
|
|
6874
|
+
var _this40 = this;
|
|
6740
6875
|
if (!type) {
|
|
6741
6876
|
return _promise.default.reject(new _parameter.default('Type must be set to acknowledge the meeting.'));
|
|
6742
6877
|
}
|
|
@@ -6748,12 +6883,12 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6748
6883
|
}).then(function (response) {
|
|
6749
6884
|
return _promise.default.resolve(response);
|
|
6750
6885
|
}).then(function (response) {
|
|
6751
|
-
|
|
6886
|
+
_this40.meetingFiniteStateMachine.ring(type);
|
|
6752
6887
|
// @ts-ignore
|
|
6753
|
-
|
|
6888
|
+
_this40.webex.internal.newMetrics.submitClientEvent({
|
|
6754
6889
|
name: 'client.alert.displayed',
|
|
6755
6890
|
options: {
|
|
6756
|
-
meetingId:
|
|
6891
|
+
meetingId: _this40.id
|
|
6757
6892
|
}
|
|
6758
6893
|
});
|
|
6759
6894
|
return _promise.default.resolve({
|
|
@@ -6778,12 +6913,12 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6778
6913
|
}, {
|
|
6779
6914
|
key: "decline",
|
|
6780
6915
|
value: function decline(reason) {
|
|
6781
|
-
var
|
|
6916
|
+
var _this41 = this;
|
|
6782
6917
|
return _util.default.declineMeeting(this, reason).then(function (decline) {
|
|
6783
|
-
|
|
6918
|
+
_this41.meetingFiniteStateMachine.decline();
|
|
6784
6919
|
return _promise.default.resolve(decline);
|
|
6785
6920
|
}).catch(function (error) {
|
|
6786
|
-
|
|
6921
|
+
_this41.meetingFiniteStateMachine.fail(error);
|
|
6787
6922
|
return _promise.default.reject(error);
|
|
6788
6923
|
});
|
|
6789
6924
|
}
|
|
@@ -6834,7 +6969,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6834
6969
|
}, {
|
|
6835
6970
|
key: "leave",
|
|
6836
6971
|
value: function leave() {
|
|
6837
|
-
var
|
|
6972
|
+
var _this42 = this;
|
|
6838
6973
|
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
6839
6974
|
var leaveReason = options.reason || _constants.MEETING_REMOVED_REASON.CLIENT_LEAVE_REQUEST;
|
|
6840
6975
|
|
|
@@ -6846,7 +6981,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6846
6981
|
var payload = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
6847
6982
|
return (
|
|
6848
6983
|
// @ts-ignore
|
|
6849
|
-
|
|
6984
|
+
_this42.webex.internal.newMetrics.submitClientEvent({
|
|
6850
6985
|
name: 'client.call.leave',
|
|
6851
6986
|
payload: _objectSpread({
|
|
6852
6987
|
trigger: 'user-interaction',
|
|
@@ -6854,7 +6989,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6854
6989
|
leaveReason: options.clientEventLeaveReason
|
|
6855
6990
|
}, payload),
|
|
6856
6991
|
options: {
|
|
6857
|
-
meetingId:
|
|
6992
|
+
meetingId: _this42.id
|
|
6858
6993
|
}
|
|
6859
6994
|
})
|
|
6860
6995
|
);
|
|
@@ -6863,24 +6998,24 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6863
6998
|
return _util.default.leaveMeeting(this, options).then(function (leave) {
|
|
6864
6999
|
// CA team recommends submitting this *after* locus /leave
|
|
6865
7000
|
submitLeaveMetric();
|
|
6866
|
-
|
|
6867
|
-
|
|
7001
|
+
_this42.meetingFiniteStateMachine.leave();
|
|
7002
|
+
_this42.clearMeetingData();
|
|
6868
7003
|
|
|
6869
7004
|
// upload logs on leave irrespective of meeting delete
|
|
6870
|
-
_triggerProxy.default.trigger(
|
|
7005
|
+
_triggerProxy.default.trigger(_this42, {
|
|
6871
7006
|
file: 'meeting/index',
|
|
6872
7007
|
function: 'leave'
|
|
6873
|
-
}, _constants.EVENTS.REQUEST_UPLOAD_LOGS,
|
|
7008
|
+
}, _constants.EVENTS.REQUEST_UPLOAD_LOGS, _this42);
|
|
6874
7009
|
|
|
6875
7010
|
// TODO: more testing before we remove this code, we are not sure the scenarios for destroy here
|
|
6876
|
-
if (
|
|
7011
|
+
if (_this42.wirelessShare || _this42.guest) {
|
|
6877
7012
|
// If screen sharing clean the meeting object
|
|
6878
|
-
_triggerProxy.default.trigger(
|
|
7013
|
+
_triggerProxy.default.trigger(_this42, {
|
|
6879
7014
|
file: 'meeting/index',
|
|
6880
7015
|
function: 'leave'
|
|
6881
7016
|
}, _constants.EVENTS.DESTROY_MEETING, {
|
|
6882
7017
|
reason: options.reason,
|
|
6883
|
-
meetingId:
|
|
7018
|
+
meetingId: _this42.id
|
|
6884
7019
|
});
|
|
6885
7020
|
}
|
|
6886
7021
|
_loggerProxy.default.logger.log('Meeting:index#leave --> LEAVE REASON ', leaveReason);
|
|
@@ -6897,16 +7032,16 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6897
7032
|
shownToUser: false
|
|
6898
7033
|
}]
|
|
6899
7034
|
});
|
|
6900
|
-
|
|
7035
|
+
_this42.meetingFiniteStateMachine.fail(error);
|
|
6901
7036
|
_loggerProxy.default.logger.error('Meeting:index#leave --> Failed to leave ', error);
|
|
6902
7037
|
// upload logs on leave irrespective of meeting delete
|
|
6903
|
-
_triggerProxy.default.trigger(
|
|
7038
|
+
_triggerProxy.default.trigger(_this42, {
|
|
6904
7039
|
file: 'meeting/index',
|
|
6905
7040
|
function: 'leave'
|
|
6906
|
-
}, _constants.EVENTS.REQUEST_UPLOAD_LOGS,
|
|
7041
|
+
}, _constants.EVENTS.REQUEST_UPLOAD_LOGS, _this42);
|
|
6907
7042
|
_metrics.default.sendBehavioralMetric(_constants2.default.MEETING_LEAVE_FAILURE, {
|
|
6908
|
-
correlation_id:
|
|
6909
|
-
locus_id:
|
|
7043
|
+
correlation_id: _this42.correlationId,
|
|
7044
|
+
locus_id: _this42.locusUrl.split('/').pop(),
|
|
6910
7045
|
reason: error.message,
|
|
6911
7046
|
stack: error.stack,
|
|
6912
7047
|
code: error.code
|
|
@@ -6926,7 +7061,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6926
7061
|
}, {
|
|
6927
7062
|
key: "startWhiteboardShare",
|
|
6928
7063
|
value: function startWhiteboardShare(channelUrl, resourceToken) {
|
|
6929
|
-
var
|
|
7064
|
+
var _this43 = this;
|
|
6930
7065
|
var whiteboard = this.locusInfo.mediaShares.find(function (element) {
|
|
6931
7066
|
return element.name === 'whiteboard';
|
|
6932
7067
|
});
|
|
@@ -6955,13 +7090,13 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6955
7090
|
body.resourceToken = resourceToken;
|
|
6956
7091
|
}
|
|
6957
7092
|
return this.meetingRequest.changeMeetingFloor(body).then(function () {
|
|
6958
|
-
|
|
7093
|
+
_this43.screenShareFloorState = ScreenShareFloorStatus.RELEASED;
|
|
6959
7094
|
return _promise.default.resolve();
|
|
6960
7095
|
}).catch(function (error) {
|
|
6961
7096
|
_loggerProxy.default.logger.error('Meeting:index#startWhiteboardShare --> Error ', error);
|
|
6962
7097
|
_metrics.default.sendBehavioralMetric(_constants2.default.MEETING_START_WHITEBOARD_SHARE_FAILURE, {
|
|
6963
|
-
correlation_id:
|
|
6964
|
-
locus_id:
|
|
7098
|
+
correlation_id: _this43.correlationId,
|
|
7099
|
+
locus_id: _this43.locusUrl.split('/').pop(),
|
|
6965
7100
|
reason: error.message,
|
|
6966
7101
|
stack: error.stack,
|
|
6967
7102
|
board: {
|
|
@@ -6984,7 +7119,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
6984
7119
|
}, {
|
|
6985
7120
|
key: "stopWhiteboardShare",
|
|
6986
7121
|
value: function stopWhiteboardShare(channelUrl) {
|
|
6987
|
-
var
|
|
7122
|
+
var _this44 = this;
|
|
6988
7123
|
var whiteboard = this.locusInfo.mediaShares.find(function (element) {
|
|
6989
7124
|
return element.name === 'whiteboard';
|
|
6990
7125
|
});
|
|
@@ -7007,8 +7142,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
7007
7142
|
}).catch(function (error) {
|
|
7008
7143
|
_loggerProxy.default.logger.error('Meeting:index#stopWhiteboardShare --> Error ', error);
|
|
7009
7144
|
_metrics.default.sendBehavioralMetric(_constants2.default.MEETING_STOP_WHITEBOARD_SHARE_FAILURE, {
|
|
7010
|
-
correlation_id:
|
|
7011
|
-
locus_id:
|
|
7145
|
+
correlation_id: _this44.correlationId,
|
|
7146
|
+
locus_id: _this44.locusUrl.split('/').pop(),
|
|
7012
7147
|
reason: error.message,
|
|
7013
7148
|
stack: error.stack,
|
|
7014
7149
|
board: {
|
|
@@ -7030,7 +7165,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
7030
7165
|
}, {
|
|
7031
7166
|
key: "requestScreenShareFloor",
|
|
7032
7167
|
value: function requestScreenShareFloor() {
|
|
7033
|
-
var
|
|
7168
|
+
var _this45 = this;
|
|
7034
7169
|
if (!this.mediaProperties.hasLocalShareStream() || !this.mediaProperties.mediaDirection.sendShare) {
|
|
7035
7170
|
_loggerProxy.default.logger.log("Meeting:index#requestScreenShareFloor --> NOT requesting floor, because we don't have the share stream anymore (shareStream=".concat(this.mediaProperties.shareVideoStream ? 'yes' : 'no', ", sendShare=").concat(this.mediaProperties.mediaDirection.sendShare, ")"));
|
|
7036
7171
|
this.screenShareFloorState = ScreenShareFloorStatus.RELEASED;
|
|
@@ -7061,34 +7196,34 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
7061
7196
|
resourceUrl: this.resourceUrl,
|
|
7062
7197
|
shareInstanceId: this.localShareInstanceId
|
|
7063
7198
|
}).then(function () {
|
|
7064
|
-
|
|
7199
|
+
_this45.screenShareFloorState = ScreenShareFloorStatus.GRANTED;
|
|
7065
7200
|
_metrics.default.sendBehavioralMetric(_constants2.default.MEETING_SHARE_SUCCESS, {
|
|
7066
|
-
correlation_id:
|
|
7067
|
-
locus_id:
|
|
7201
|
+
correlation_id: _this45.correlationId,
|
|
7202
|
+
locus_id: _this45.locusUrl.split('/').pop()
|
|
7068
7203
|
});
|
|
7069
7204
|
return _promise.default.resolve();
|
|
7070
7205
|
}).catch(function (error) {
|
|
7071
7206
|
_loggerProxy.default.logger.error('Meeting:index#share --> Error ', error);
|
|
7072
7207
|
_metrics.default.sendBehavioralMetric(_constants2.default.MEETING_SHARE_FAILURE, {
|
|
7073
|
-
correlation_id:
|
|
7074
|
-
locus_id:
|
|
7208
|
+
correlation_id: _this45.correlationId,
|
|
7209
|
+
locus_id: _this45.locusUrl.split('/').pop(),
|
|
7075
7210
|
reason: error.message,
|
|
7076
7211
|
stack: error.stack
|
|
7077
7212
|
});
|
|
7078
7213
|
|
|
7079
7214
|
// @ts-ignore
|
|
7080
|
-
|
|
7215
|
+
_this45.webex.internal.newMetrics.submitClientEvent({
|
|
7081
7216
|
name: 'client.share.floor-granted.local',
|
|
7082
7217
|
payload: {
|
|
7083
7218
|
mediaType: 'share',
|
|
7084
7219
|
errors: _util.default.getChangeMeetingFloorErrorPayload(error.message),
|
|
7085
|
-
shareInstanceId:
|
|
7220
|
+
shareInstanceId: _this45.localShareInstanceId
|
|
7086
7221
|
},
|
|
7087
7222
|
options: {
|
|
7088
|
-
meetingId:
|
|
7223
|
+
meetingId: _this45.id
|
|
7089
7224
|
}
|
|
7090
7225
|
});
|
|
7091
|
-
|
|
7226
|
+
_this45.screenShareFloorState = ScreenShareFloorStatus.RELEASED;
|
|
7092
7227
|
return _promise.default.reject(error);
|
|
7093
7228
|
});
|
|
7094
7229
|
}
|
|
@@ -7111,10 +7246,10 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
7111
7246
|
}, {
|
|
7112
7247
|
key: "requestScreenShareFloorIfPending",
|
|
7113
7248
|
value: function requestScreenShareFloorIfPending() {
|
|
7114
|
-
var
|
|
7249
|
+
var _this46 = this;
|
|
7115
7250
|
if (this.floorGrantPending && this.state === _constants.MEETING_STATE.STATES.JOINED) {
|
|
7116
7251
|
this.requestScreenShareFloor().then(function () {
|
|
7117
|
-
|
|
7252
|
+
_this46.floorGrantPending = false;
|
|
7118
7253
|
});
|
|
7119
7254
|
}
|
|
7120
7255
|
}
|
|
@@ -7128,7 +7263,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
7128
7263
|
}, {
|
|
7129
7264
|
key: "releaseScreenShareFloor",
|
|
7130
7265
|
value: function releaseScreenShareFloor() {
|
|
7131
|
-
var
|
|
7266
|
+
var _this47 = this;
|
|
7132
7267
|
var content = this.locusInfo.mediaShares.find(function (element) {
|
|
7133
7268
|
return element.name === _constants.CONTENT;
|
|
7134
7269
|
});
|
|
@@ -7163,8 +7298,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
7163
7298
|
}).catch(function (error) {
|
|
7164
7299
|
_loggerProxy.default.logger.error('Meeting:index#releaseScreenShareFloor --> Error ', error);
|
|
7165
7300
|
_metrics.default.sendBehavioralMetric(_constants2.default.STOP_FLOOR_REQUEST_FAILURE, {
|
|
7166
|
-
correlation_id:
|
|
7167
|
-
locus_id:
|
|
7301
|
+
correlation_id: _this47.correlationId,
|
|
7302
|
+
locus_id: _this47.locusUrl.split('/').pop(),
|
|
7168
7303
|
reason: error.message,
|
|
7169
7304
|
stack: error.stack
|
|
7170
7305
|
});
|
|
@@ -7343,7 +7478,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
7343
7478
|
}, {
|
|
7344
7479
|
key: "changeVideoLayout",
|
|
7345
7480
|
value: function changeVideoLayout(layoutType) {
|
|
7346
|
-
var
|
|
7481
|
+
var _this48 = this;
|
|
7347
7482
|
var renderInfo = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
7348
7483
|
var main = renderInfo.main,
|
|
7349
7484
|
content = renderInfo.content;
|
|
@@ -7397,7 +7532,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
7397
7532
|
}
|
|
7398
7533
|
this.lastVideoLayoutInfo = (0, _lodash.cloneDeep)(layoutInfo);
|
|
7399
7534
|
this.locusInfo.once(_constants.LOCUSINFO.EVENTS.CONTROLS_MEETING_LAYOUT_UPDATED, function (envelope) {
|
|
7400
|
-
_triggerProxy.default.trigger(
|
|
7535
|
+
_triggerProxy.default.trigger(_this48, {
|
|
7401
7536
|
file: 'meeting/index',
|
|
7402
7537
|
function: 'changeVideoLayout'
|
|
7403
7538
|
}, _constants.EVENT_TRIGGERS.MEETING_CONTROLS_LAYOUT_UPDATE, {
|
|
@@ -7513,7 +7648,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
7513
7648
|
}, {
|
|
7514
7649
|
key: "endMeetingForAll",
|
|
7515
7650
|
value: function endMeetingForAll() {
|
|
7516
|
-
var
|
|
7651
|
+
var _this49 = this;
|
|
7517
7652
|
// @ts-ignore
|
|
7518
7653
|
this.webex.internal.newMetrics.submitClientEvent({
|
|
7519
7654
|
name: 'client.call.leave',
|
|
@@ -7531,25 +7666,25 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
7531
7666
|
locus_id: this.locusId
|
|
7532
7667
|
});
|
|
7533
7668
|
return _util.default.endMeetingForAll(this).then(function (end) {
|
|
7534
|
-
|
|
7535
|
-
|
|
7669
|
+
_this49.meetingFiniteStateMachine.end();
|
|
7670
|
+
_this49.clearMeetingData();
|
|
7536
7671
|
// upload logs on leave irrespective of meeting delete
|
|
7537
|
-
_triggerProxy.default.trigger(
|
|
7672
|
+
_triggerProxy.default.trigger(_this49, {
|
|
7538
7673
|
file: 'meeting/index',
|
|
7539
7674
|
function: 'endMeetingForAll'
|
|
7540
|
-
}, _constants.EVENTS.REQUEST_UPLOAD_LOGS,
|
|
7675
|
+
}, _constants.EVENTS.REQUEST_UPLOAD_LOGS, _this49);
|
|
7541
7676
|
return end;
|
|
7542
7677
|
}).catch(function (error) {
|
|
7543
|
-
|
|
7678
|
+
_this49.meetingFiniteStateMachine.fail(error);
|
|
7544
7679
|
_loggerProxy.default.logger.error('Meeting:index#endMeetingForAll --> Failed to end meeting ', error);
|
|
7545
7680
|
// upload logs on leave irrespective of meeting delete
|
|
7546
|
-
_triggerProxy.default.trigger(
|
|
7681
|
+
_triggerProxy.default.trigger(_this49, {
|
|
7547
7682
|
file: 'meeting/index',
|
|
7548
7683
|
function: 'endMeetingForAll'
|
|
7549
|
-
}, _constants.EVENTS.REQUEST_UPLOAD_LOGS,
|
|
7684
|
+
}, _constants.EVENTS.REQUEST_UPLOAD_LOGS, _this49);
|
|
7550
7685
|
_metrics.default.sendBehavioralMetric(_constants2.default.MEETING_END_ALL_FAILURE, {
|
|
7551
|
-
correlation_id:
|
|
7552
|
-
locus_id:
|
|
7686
|
+
correlation_id: _this49.correlationId,
|
|
7687
|
+
locus_id: _this49.locusUrl.split('/').pop(),
|
|
7553
7688
|
reason: error.message,
|
|
7554
7689
|
stack: error.stack,
|
|
7555
7690
|
code: error.code
|
|
@@ -7638,39 +7773,39 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
7638
7773
|
}, {
|
|
7639
7774
|
key: "enableMusicMode",
|
|
7640
7775
|
value: (function () {
|
|
7641
|
-
var _enableMusicMode = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function
|
|
7642
|
-
return _regenerator.default.wrap(function
|
|
7643
|
-
while (1) switch (
|
|
7776
|
+
var _enableMusicMode = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee33(shouldEnableMusicMode) {
|
|
7777
|
+
return _regenerator.default.wrap(function _callee33$(_context33) {
|
|
7778
|
+
while (1) switch (_context33.prev = _context33.next) {
|
|
7644
7779
|
case 0:
|
|
7645
7780
|
this.checkMediaConnection();
|
|
7646
7781
|
if (this.isMultistream) {
|
|
7647
|
-
|
|
7782
|
+
_context33.next = 3;
|
|
7648
7783
|
break;
|
|
7649
7784
|
}
|
|
7650
7785
|
throw new Error('enableMusicMode() only supported with multistream');
|
|
7651
7786
|
case 3:
|
|
7652
7787
|
if (!shouldEnableMusicMode) {
|
|
7653
|
-
|
|
7788
|
+
_context33.next = 8;
|
|
7654
7789
|
break;
|
|
7655
7790
|
}
|
|
7656
|
-
|
|
7791
|
+
_context33.next = 6;
|
|
7657
7792
|
return this.sendSlotManager.setCodecParameters(_internalMediaCore.MediaType.AudioMain, {
|
|
7658
7793
|
maxaveragebitrate: '64000',
|
|
7659
7794
|
maxplaybackrate: '48000'
|
|
7660
7795
|
});
|
|
7661
7796
|
case 6:
|
|
7662
|
-
|
|
7797
|
+
_context33.next = 10;
|
|
7663
7798
|
break;
|
|
7664
7799
|
case 8:
|
|
7665
|
-
|
|
7800
|
+
_context33.next = 10;
|
|
7666
7801
|
return this.sendSlotManager.deleteCodecParameters(_internalMediaCore.MediaType.AudioMain, ['maxaveragebitrate', 'maxplaybackrate']);
|
|
7667
7802
|
case 10:
|
|
7668
7803
|
case "end":
|
|
7669
|
-
return
|
|
7804
|
+
return _context33.stop();
|
|
7670
7805
|
}
|
|
7671
|
-
},
|
|
7806
|
+
}, _callee33, this);
|
|
7672
7807
|
}));
|
|
7673
|
-
function enableMusicMode(
|
|
7808
|
+
function enableMusicMode(_x33) {
|
|
7674
7809
|
return _enableMusicMode.apply(this, arguments);
|
|
7675
7810
|
}
|
|
7676
7811
|
return enableMusicMode;
|
|
@@ -7691,7 +7826,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
7691
7826
|
_this$mediaProperties48,
|
|
7692
7827
|
_this$mediaProperties49,
|
|
7693
7828
|
_this$mediaProperties50,
|
|
7694
|
-
|
|
7829
|
+
_this50 = this;
|
|
7695
7830
|
var LOG_HEADER = 'Meeting:index#updateTranscodedMediaConnection -->';
|
|
7696
7831
|
_loggerProxy.default.logger.info("".concat(LOG_HEADER, " starting"));
|
|
7697
7832
|
if (!this.canUpdateMedia()) {
|
|
@@ -7716,8 +7851,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
7716
7851
|
}).catch(function (error) {
|
|
7717
7852
|
_loggerProxy.default.logger.error("".concat(LOG_HEADER, " Error: "), error);
|
|
7718
7853
|
_metrics.default.sendBehavioralMetric(_constants2.default.UPDATE_MEDIA_FAILURE, {
|
|
7719
|
-
correlation_id:
|
|
7720
|
-
locus_id:
|
|
7854
|
+
correlation_id: _this50.correlationId,
|
|
7855
|
+
locus_id: _this50.locusUrl.split('/').pop(),
|
|
7721
7856
|
reason: error.message,
|
|
7722
7857
|
stack: error.stack
|
|
7723
7858
|
});
|
|
@@ -7761,25 +7896,25 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
7761
7896
|
}, {
|
|
7762
7897
|
key: "publishStream",
|
|
7763
7898
|
value: (function () {
|
|
7764
|
-
var _publishStream = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function
|
|
7765
|
-
return _regenerator.default.wrap(function
|
|
7766
|
-
while (1) switch (
|
|
7899
|
+
var _publishStream = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee34(mediaType, stream) {
|
|
7900
|
+
return _regenerator.default.wrap(function _callee34$(_context34) {
|
|
7901
|
+
while (1) switch (_context34.prev = _context34.next) {
|
|
7767
7902
|
case 0:
|
|
7768
7903
|
if (stream) {
|
|
7769
|
-
|
|
7904
|
+
_context34.next = 2;
|
|
7770
7905
|
break;
|
|
7771
7906
|
}
|
|
7772
|
-
return
|
|
7907
|
+
return _context34.abrupt("return");
|
|
7773
7908
|
case 2:
|
|
7774
7909
|
if (!this.mediaProperties.webrtcMediaConnection) {
|
|
7775
|
-
|
|
7910
|
+
_context34.next = 7;
|
|
7776
7911
|
break;
|
|
7777
7912
|
}
|
|
7778
7913
|
if (!(this.isMultistream && this.mediaProperties.webrtcMediaConnection)) {
|
|
7779
|
-
|
|
7914
|
+
_context34.next = 6;
|
|
7780
7915
|
break;
|
|
7781
7916
|
}
|
|
7782
|
-
|
|
7917
|
+
_context34.next = 6;
|
|
7783
7918
|
return this.sendSlotManager.publishStream(mediaType, stream);
|
|
7784
7919
|
case 6:
|
|
7785
7920
|
this.emitPublishStateChangeEvent({
|
|
@@ -7790,11 +7925,11 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
7790
7925
|
});
|
|
7791
7926
|
case 7:
|
|
7792
7927
|
case "end":
|
|
7793
|
-
return
|
|
7928
|
+
return _context34.stop();
|
|
7794
7929
|
}
|
|
7795
|
-
},
|
|
7930
|
+
}, _callee34, this);
|
|
7796
7931
|
}));
|
|
7797
|
-
function publishStream(
|
|
7932
|
+
function publishStream(_x34, _x35) {
|
|
7798
7933
|
return _publishStream.apply(this, arguments);
|
|
7799
7934
|
}
|
|
7800
7935
|
return publishStream;
|
|
@@ -7810,21 +7945,21 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
7810
7945
|
}, {
|
|
7811
7946
|
key: "unpublishStream",
|
|
7812
7947
|
value: (function () {
|
|
7813
|
-
var _unpublishStream = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function
|
|
7814
|
-
return _regenerator.default.wrap(function
|
|
7815
|
-
while (1) switch (
|
|
7948
|
+
var _unpublishStream = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee35(mediaType, stream) {
|
|
7949
|
+
return _regenerator.default.wrap(function _callee35$(_context35) {
|
|
7950
|
+
while (1) switch (_context35.prev = _context35.next) {
|
|
7816
7951
|
case 0:
|
|
7817
7952
|
if (stream) {
|
|
7818
|
-
|
|
7953
|
+
_context35.next = 2;
|
|
7819
7954
|
break;
|
|
7820
7955
|
}
|
|
7821
|
-
return
|
|
7956
|
+
return _context35.abrupt("return");
|
|
7822
7957
|
case 2:
|
|
7823
7958
|
if (!(this.isMultistream && this.mediaProperties.webrtcMediaConnection)) {
|
|
7824
|
-
|
|
7959
|
+
_context35.next = 5;
|
|
7825
7960
|
break;
|
|
7826
7961
|
}
|
|
7827
|
-
|
|
7962
|
+
_context35.next = 5;
|
|
7828
7963
|
return this.sendSlotManager.unpublishStream(mediaType);
|
|
7829
7964
|
case 5:
|
|
7830
7965
|
this.emitPublishStateChangeEvent({
|
|
@@ -7835,11 +7970,11 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
7835
7970
|
});
|
|
7836
7971
|
case 6:
|
|
7837
7972
|
case "end":
|
|
7838
|
-
return
|
|
7973
|
+
return _context35.stop();
|
|
7839
7974
|
}
|
|
7840
|
-
},
|
|
7975
|
+
}, _callee35, this);
|
|
7841
7976
|
}));
|
|
7842
|
-
function unpublishStream(
|
|
7977
|
+
function unpublishStream(_x36, _x37) {
|
|
7843
7978
|
return _unpublishStream.apply(this, arguments);
|
|
7844
7979
|
}
|
|
7845
7980
|
return unpublishStream;
|
|
@@ -7854,61 +7989,67 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
7854
7989
|
}, {
|
|
7855
7990
|
key: "publishStreams",
|
|
7856
7991
|
value: (function () {
|
|
7857
|
-
var _publishStreams = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function
|
|
7858
|
-
var _streams$screenShare, _streams$screenShare2, _streams$screenShare3, _streams$screenShare4;
|
|
7859
|
-
var floorRequestNeeded, _streams$
|
|
7860
|
-
return _regenerator.default.wrap(function
|
|
7861
|
-
while (1) switch (
|
|
7992
|
+
var _publishStreams = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee36(streams) {
|
|
7993
|
+
var _streams$screenShare, _streams$screenShare2, _streams$microphone, _streams$camera, _streams$screenShare3, _streams$screenShare4, _streams$screenShare5, _streams$screenShare6, _streams$screenShare7, _streams$screenShare8;
|
|
7994
|
+
var floorRequestNeeded, _streams$screenShare9;
|
|
7995
|
+
return _regenerator.default.wrap(function _callee36$(_context36) {
|
|
7996
|
+
while (1) switch (_context36.prev = _context36.next) {
|
|
7862
7997
|
case 0:
|
|
7863
7998
|
this.checkMediaConnection();
|
|
7864
7999
|
if (!(!streams.microphone && !streams.camera && !((_streams$screenShare = streams.screenShare) !== null && _streams$screenShare !== void 0 && _streams$screenShare.audio) && !((_streams$screenShare2 = streams.screenShare) !== null && _streams$screenShare2 !== void 0 && _streams$screenShare2.video))) {
|
|
7865
|
-
|
|
8000
|
+
_context36.next = 3;
|
|
7866
8001
|
break;
|
|
7867
8002
|
}
|
|
7868
|
-
return
|
|
8003
|
+
return _context36.abrupt("return");
|
|
7869
8004
|
case 3:
|
|
8005
|
+
if (!((streams === null || streams === void 0 ? void 0 : (_streams$microphone = streams.microphone) === null || _streams$microphone === void 0 ? void 0 : _streams$microphone.readyState) === 'ended' || (streams === null || streams === void 0 ? void 0 : (_streams$camera = streams.camera) === null || _streams$camera === void 0 ? void 0 : _streams$camera.readyState) === 'ended' || (streams === null || streams === void 0 ? void 0 : (_streams$screenShare3 = streams.screenShare) === null || _streams$screenShare3 === void 0 ? void 0 : (_streams$screenShare4 = _streams$screenShare3.audio) === null || _streams$screenShare4 === void 0 ? void 0 : _streams$screenShare4.readyState) === 'ended' || (streams === null || streams === void 0 ? void 0 : (_streams$screenShare5 = streams.screenShare) === null || _streams$screenShare5 === void 0 ? void 0 : (_streams$screenShare6 = _streams$screenShare5.video) === null || _streams$screenShare6 === void 0 ? void 0 : _streams$screenShare6.readyState) === 'ended')) {
|
|
8006
|
+
_context36.next = 5;
|
|
8007
|
+
break;
|
|
8008
|
+
}
|
|
8009
|
+
throw new Error("Attempted to publish stream with ended readyState, correlationId=".concat(this.correlationId));
|
|
8010
|
+
case 5:
|
|
7870
8011
|
floorRequestNeeded = false; // Screenshare Audio is supported only in multi stream. So we check for screenshare audio presence only if it's a multi stream meeting
|
|
7871
|
-
if (!(this.isMultistream && (_streams$
|
|
7872
|
-
|
|
8012
|
+
if (!(this.isMultistream && (_streams$screenShare7 = streams.screenShare) !== null && _streams$screenShare7 !== void 0 && _streams$screenShare7.audio)) {
|
|
8013
|
+
_context36.next = 10;
|
|
7873
8014
|
break;
|
|
7874
8015
|
}
|
|
7875
|
-
|
|
8016
|
+
_context36.next = 9;
|
|
7876
8017
|
return this.setLocalShareAudioStream(streams.screenShare.audio);
|
|
7877
|
-
case
|
|
8018
|
+
case 9:
|
|
7878
8019
|
floorRequestNeeded = this.screenShareFloorState === ScreenShareFloorStatus.RELEASED;
|
|
7879
|
-
case
|
|
7880
|
-
if (!((_streams$
|
|
7881
|
-
|
|
8020
|
+
case 10:
|
|
8021
|
+
if (!((_streams$screenShare8 = streams.screenShare) !== null && _streams$screenShare8 !== void 0 && _streams$screenShare8.video)) {
|
|
8022
|
+
_context36.next = 14;
|
|
7882
8023
|
break;
|
|
7883
8024
|
}
|
|
7884
|
-
|
|
7885
|
-
return this.setLocalShareVideoStream((_streams$
|
|
7886
|
-
case
|
|
8025
|
+
_context36.next = 13;
|
|
8026
|
+
return this.setLocalShareVideoStream((_streams$screenShare9 = streams.screenShare) === null || _streams$screenShare9 === void 0 ? void 0 : _streams$screenShare9.video);
|
|
8027
|
+
case 13:
|
|
7887
8028
|
floorRequestNeeded = this.screenShareFloorState === ScreenShareFloorStatus.RELEASED;
|
|
7888
|
-
case
|
|
8029
|
+
case 14:
|
|
7889
8030
|
if (!streams.microphone) {
|
|
7890
|
-
|
|
8031
|
+
_context36.next = 17;
|
|
7891
8032
|
break;
|
|
7892
8033
|
}
|
|
7893
|
-
|
|
8034
|
+
_context36.next = 17;
|
|
7894
8035
|
return this.setLocalAudioStream(streams.microphone);
|
|
7895
|
-
case
|
|
8036
|
+
case 17:
|
|
7896
8037
|
if (!streams.camera) {
|
|
7897
|
-
|
|
8038
|
+
_context36.next = 20;
|
|
7898
8039
|
break;
|
|
7899
8040
|
}
|
|
7900
|
-
|
|
8041
|
+
_context36.next = 20;
|
|
7901
8042
|
return this.setLocalVideoStream(streams.camera);
|
|
7902
|
-
case
|
|
8043
|
+
case 20:
|
|
7903
8044
|
if (this.isMultistream) {
|
|
7904
|
-
|
|
8045
|
+
_context36.next = 23;
|
|
7905
8046
|
break;
|
|
7906
8047
|
}
|
|
7907
|
-
|
|
8048
|
+
_context36.next = 23;
|
|
7908
8049
|
return this.updateTranscodedMediaConnection();
|
|
7909
|
-
case
|
|
8050
|
+
case 23:
|
|
7910
8051
|
if (!floorRequestNeeded) {
|
|
7911
|
-
|
|
8052
|
+
_context36.next = 29;
|
|
7912
8053
|
break;
|
|
7913
8054
|
}
|
|
7914
8055
|
this.localShareInstanceId = _uuid.default.v4();
|
|
@@ -7932,15 +8073,15 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
7932
8073
|
// we're sending the http request to Locus to request the screen share floor
|
|
7933
8074
|
// only after the SDP update, because that's how it's always been done for transcoded meetings
|
|
7934
8075
|
// and also if sharing from the start, we need confluence to have been created
|
|
7935
|
-
|
|
8076
|
+
_context36.next = 29;
|
|
7936
8077
|
return this.enqueueScreenShareFloorRequest();
|
|
7937
|
-
case
|
|
8078
|
+
case 29:
|
|
7938
8079
|
case "end":
|
|
7939
|
-
return
|
|
8080
|
+
return _context36.stop();
|
|
7940
8081
|
}
|
|
7941
|
-
},
|
|
8082
|
+
}, _callee36, this);
|
|
7942
8083
|
}));
|
|
7943
|
-
function publishStreams(
|
|
8084
|
+
function publishStreams(_x38) {
|
|
7944
8085
|
return _publishStreams.apply(this, arguments);
|
|
7945
8086
|
}
|
|
7946
8087
|
return publishStreams;
|
|
@@ -7955,10 +8096,10 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
7955
8096
|
}, {
|
|
7956
8097
|
key: "unpublishStreams",
|
|
7957
8098
|
value: (function () {
|
|
7958
|
-
var _unpublishStreams = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function
|
|
8099
|
+
var _unpublishStreams = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee37(streams) {
|
|
7959
8100
|
var promises, _iterator, _step, stream;
|
|
7960
|
-
return _regenerator.default.wrap(function
|
|
7961
|
-
while (1) switch (
|
|
8101
|
+
return _regenerator.default.wrap(function _callee37$(_context37) {
|
|
8102
|
+
while (1) switch (_context37.prev = _context37.next) {
|
|
7962
8103
|
case 0:
|
|
7963
8104
|
this.checkMediaConnection();
|
|
7964
8105
|
promises = [];
|
|
@@ -7989,7 +8130,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
7989
8130
|
if (!this.isMultistream) {
|
|
7990
8131
|
promises.push(this.updateTranscodedMediaConnection());
|
|
7991
8132
|
}
|
|
7992
|
-
|
|
8133
|
+
_context37.next = 7;
|
|
7993
8134
|
return _promise.default.all(promises);
|
|
7994
8135
|
case 7:
|
|
7995
8136
|
// we're allowing for the SDK to support just audio share as well
|
|
@@ -8010,11 +8151,11 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
8010
8151
|
}
|
|
8011
8152
|
case 8:
|
|
8012
8153
|
case "end":
|
|
8013
|
-
return
|
|
8154
|
+
return _context37.stop();
|
|
8014
8155
|
}
|
|
8015
|
-
},
|
|
8156
|
+
}, _callee37, this);
|
|
8016
8157
|
}));
|
|
8017
|
-
function unpublishStreams(
|
|
8158
|
+
function unpublishStreams(_x39) {
|
|
8018
8159
|
return _unpublishStreams.apply(this, arguments);
|
|
8019
8160
|
}
|
|
8020
8161
|
return unpublishStreams;
|
|
@@ -8074,27 +8215,27 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
|
|
|
8074
8215
|
}], [{
|
|
8075
8216
|
key: "handleDeviceLogging",
|
|
8076
8217
|
value: (function () {
|
|
8077
|
-
var _handleDeviceLogging = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function
|
|
8218
|
+
var _handleDeviceLogging = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee38() {
|
|
8078
8219
|
var devices;
|
|
8079
|
-
return _regenerator.default.wrap(function
|
|
8080
|
-
while (1) switch (
|
|
8220
|
+
return _regenerator.default.wrap(function _callee38$(_context38) {
|
|
8221
|
+
while (1) switch (_context38.prev = _context38.next) {
|
|
8081
8222
|
case 0:
|
|
8082
|
-
|
|
8083
|
-
|
|
8223
|
+
_context38.prev = 0;
|
|
8224
|
+
_context38.next = 3;
|
|
8084
8225
|
return (0, _mediaHelpers.getDevices)();
|
|
8085
8226
|
case 3:
|
|
8086
|
-
devices =
|
|
8227
|
+
devices = _context38.sent;
|
|
8087
8228
|
_util.default.handleDeviceLogging(devices);
|
|
8088
|
-
|
|
8229
|
+
_context38.next = 9;
|
|
8089
8230
|
break;
|
|
8090
8231
|
case 7:
|
|
8091
|
-
|
|
8092
|
-
|
|
8232
|
+
_context38.prev = 7;
|
|
8233
|
+
_context38.t0 = _context38["catch"](0);
|
|
8093
8234
|
case 9:
|
|
8094
8235
|
case "end":
|
|
8095
|
-
return
|
|
8236
|
+
return _context38.stop();
|
|
8096
8237
|
}
|
|
8097
|
-
},
|
|
8238
|
+
}, _callee38, null, [[0, 7]]);
|
|
8098
8239
|
}));
|
|
8099
8240
|
function handleDeviceLogging() {
|
|
8100
8241
|
return _handleDeviceLogging.apply(this, arguments);
|