@webex/plugin-meetings 3.12.0-next.3 → 3.12.0-next.31
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/AGENTS.md +9 -0
- package/dist/aiEnableRequest/index.js +1 -1
- package/dist/breakouts/breakout.js +1 -1
- package/dist/breakouts/index.js +1 -1
- package/dist/constants.js +3 -1
- package/dist/constants.js.map +1 -1
- package/dist/controls-options-manager/constants.js +11 -1
- package/dist/controls-options-manager/constants.js.map +1 -1
- package/dist/controls-options-manager/index.js +23 -21
- package/dist/controls-options-manager/index.js.map +1 -1
- package/dist/controls-options-manager/util.js +91 -0
- package/dist/controls-options-manager/util.js.map +1 -1
- package/dist/hashTree/constants.js +10 -1
- package/dist/hashTree/constants.js.map +1 -1
- package/dist/hashTree/hashTreeParser.js +550 -346
- package/dist/hashTree/hashTreeParser.js.map +1 -1
- package/dist/hashTree/utils.js +22 -0
- package/dist/hashTree/utils.js.map +1 -1
- package/dist/interceptors/locusRetry.js +23 -8
- package/dist/interceptors/locusRetry.js.map +1 -1
- package/dist/interpretation/index.js +1 -1
- package/dist/interpretation/siLanguage.js +1 -1
- package/dist/locus-info/index.js +222 -61
- package/dist/locus-info/index.js.map +1 -1
- package/dist/meeting/index.js +372 -292
- package/dist/meeting/index.js.map +1 -1
- package/dist/meeting/util.js +1 -0
- package/dist/meeting/util.js.map +1 -1
- package/dist/meetings/index.js +146 -62
- package/dist/meetings/index.js.map +1 -1
- package/dist/meetings/util.js +39 -5
- package/dist/meetings/util.js.map +1 -1
- package/dist/member/index.js +10 -0
- package/dist/member/index.js.map +1 -1
- package/dist/member/types.js.map +1 -1
- package/dist/member/util.js +3 -0
- package/dist/member/util.js.map +1 -1
- package/dist/metrics/constants.js +5 -1
- package/dist/metrics/constants.js.map +1 -1
- package/dist/multistream/sendSlotManager.js +116 -2
- package/dist/multistream/sendSlotManager.js.map +1 -1
- package/dist/types/constants.d.ts +1 -0
- package/dist/types/controls-options-manager/constants.d.ts +6 -1
- package/dist/types/hashTree/constants.d.ts +1 -0
- package/dist/types/hashTree/hashTreeParser.d.ts +53 -15
- package/dist/types/hashTree/utils.d.ts +11 -0
- package/dist/types/interceptors/locusRetry.d.ts +4 -4
- package/dist/types/locus-info/index.d.ts +38 -5
- package/dist/types/meeting/index.d.ts +11 -0
- package/dist/types/member/index.d.ts +1 -0
- package/dist/types/member/types.d.ts +1 -0
- package/dist/types/member/util.d.ts +1 -0
- package/dist/types/metrics/constants.d.ts +4 -0
- package/dist/types/multistream/sendSlotManager.d.ts +23 -1
- package/dist/webinar/index.js +301 -226
- package/dist/webinar/index.js.map +1 -1
- package/package.json +16 -16
- package/src/constants.ts +1 -0
- package/src/controls-options-manager/constants.ts +14 -1
- package/src/controls-options-manager/index.ts +26 -19
- package/src/controls-options-manager/util.ts +81 -1
- package/src/hashTree/constants.ts +9 -0
- package/src/hashTree/hashTreeParser.ts +273 -154
- package/src/hashTree/utils.ts +17 -0
- package/src/interceptors/locusRetry.ts +25 -4
- package/src/locus-info/index.ts +233 -79
- package/src/meeting/index.ts +98 -11
- package/src/meeting/util.ts +1 -0
- package/src/meetings/index.ts +58 -34
- package/src/meetings/util.ts +44 -1
- package/src/member/index.ts +10 -0
- package/src/member/types.ts +1 -0
- package/src/member/util.ts +3 -0
- package/src/metrics/constants.ts +5 -0
- package/src/multistream/sendSlotManager.ts +97 -3
- package/src/webinar/index.ts +75 -1
- package/test/unit/spec/controls-options-manager/index.js +114 -6
- package/test/unit/spec/controls-options-manager/util.js +165 -0
- package/test/unit/spec/hashTree/hashTreeParser.ts +839 -37
- package/test/unit/spec/hashTree/utils.ts +88 -1
- package/test/unit/spec/interceptors/locusRetry.ts +205 -4
- package/test/unit/spec/locus-info/index.js +262 -64
- package/test/unit/spec/meeting/index.js +54 -36
- package/test/unit/spec/meeting/utils.js +4 -0
- package/test/unit/spec/meetings/index.js +190 -8
- package/test/unit/spec/meetings/utils.js +124 -0
- package/test/unit/spec/member/index.js +7 -0
- package/test/unit/spec/member/util.js +24 -0
- package/test/unit/spec/multistream/sendSlotManager.ts +135 -36
- package/test/unit/spec/webinar/index.ts +60 -0
package/dist/meetings/index.js
CHANGED
|
@@ -64,7 +64,7 @@ var _noMeetingInfo = _interopRequireDefault(require("../common/errors/no-meeting
|
|
|
64
64
|
var _joinForbiddenError = _interopRequireDefault(require("../common/errors/join-forbidden-error"));
|
|
65
65
|
var _utils = require("../hashTree/utils");
|
|
66
66
|
var _locusInfo = require("../locus-info");
|
|
67
|
-
function _interopRequireWildcard(e, t) { if ("function" == typeof _WeakMap) var r = new _WeakMap(), n = new _WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var
|
|
67
|
+
function _interopRequireWildcard(e, t) { if ("function" == typeof _WeakMap) var r = new _WeakMap(), n = new _WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t4 in e) "default" !== _t4 && {}.hasOwnProperty.call(e, _t4) && ((i = (o = _Object$defineProperty) && _Object$getOwnPropertyDescriptor(e, _t4)) && (i.get || i.set) ? o(f, _t4, i) : f[_t4] = e[_t4]); return f; })(e, t); }
|
|
68
68
|
function ownKeys(e, r) { var t = _Object$keys2(e); if (_Object$getOwnPropertySymbols) { var o = _Object$getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return _Object$getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
69
69
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors ? _Object$defineProperties(e, _Object$getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { _Object$defineProperty(e, r, _Object$getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
70
70
|
function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? _Reflect$construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); }
|
|
@@ -354,11 +354,11 @@ var Meetings = exports.default = /*#__PURE__*/function (_WebexPlugin) {
|
|
|
354
354
|
return (0, _createClass2.default)(Meetings, [{
|
|
355
355
|
key: "isNeedHandleMainLocus",
|
|
356
356
|
value: function isNeedHandleMainLocus(meeting, newLocus) {
|
|
357
|
-
var _newLocus$controls, _newLocus$controls$br, _newLocus$self,
|
|
357
|
+
var _newLocus$controls, _newLocus$controls$br, _newLocus$self, _breakoutLocus$joined, _newLocus$self2;
|
|
358
358
|
var breakoutUrl = (_newLocus$controls = newLocus.controls) === null || _newLocus$controls === void 0 ? void 0 : (_newLocus$controls$br = _newLocus$controls.breakout) === null || _newLocus$controls$br === void 0 ? void 0 : _newLocus$controls$br.url;
|
|
359
359
|
var breakoutLocus = this.meetingCollection.getActiveBreakoutLocus(breakoutUrl);
|
|
360
360
|
var isSelfJoined = (newLocus === null || newLocus === void 0 ? void 0 : (_newLocus$self = newLocus.self) === null || _newLocus$self === void 0 ? void 0 : _newLocus$self.state) === _constants._JOINED_;
|
|
361
|
-
var isSelfMoved =
|
|
361
|
+
var isSelfMoved = _util2.default.isSelfMovedOrBreakoutEnded(newLocus);
|
|
362
362
|
// @ts-ignore
|
|
363
363
|
var deviceFromNewLocus = _util2.default.getThisDevice(newLocus, this.webex.internal.device.url);
|
|
364
364
|
var isResourceMovedOnThisDevice = (deviceFromNewLocus === null || deviceFromNewLocus === void 0 ? void 0 : deviceFromNewLocus.state) === _constants._LEFT_ && (deviceFromNewLocus === null || deviceFromNewLocus === void 0 ? void 0 : deviceFromNewLocus.reason) === _constants._MOVED_;
|
|
@@ -383,7 +383,7 @@ var Meetings = exports.default = /*#__PURE__*/function (_WebexPlugin) {
|
|
|
383
383
|
_loggerProxy.default.logger.log("Meetings:index#isNeedHandleMainLocus --> there is active breakout session and joined on this device, and don't need to handle main session: ".concat(breakoutUrl));
|
|
384
384
|
return false;
|
|
385
385
|
}
|
|
386
|
-
if (isSelfMoved && (newLocus !== null && newLocus !== void 0 && (_newLocus$
|
|
386
|
+
if (isSelfMoved && (newLocus !== null && newLocus !== void 0 && (_newLocus$self2 = newLocus.self) !== null && _newLocus$self2 !== void 0 && _newLocus$self2.removed || isResourceMovedOnThisDevice)) {
|
|
387
387
|
_loggerProxy.default.logger.log('Meetings:index#isNeedHandleMainLocus --> self moved main locus with self removed status or with device resource moved, not need to handle');
|
|
388
388
|
return false;
|
|
389
389
|
}
|
|
@@ -407,15 +407,15 @@ var Meetings = exports.default = /*#__PURE__*/function (_WebexPlugin) {
|
|
|
407
407
|
key: "isNeedHandleLocusDTO",
|
|
408
408
|
value: function isNeedHandleLocusDTO(meeting, newLocus) {
|
|
409
409
|
if (newLocus) {
|
|
410
|
-
var _newLocus$
|
|
410
|
+
var _newLocus$self3, _newLocus$self3$devic, _newLocus$self3$devic2, _newLocus$self4, _newLocus$self4$devic, _newLocus$self4$devic2;
|
|
411
411
|
var isNewLocusAsBreakout = _util2.default.isBreakoutLocusDTO(newLocus);
|
|
412
|
-
var isSelfMoved =
|
|
413
|
-
var isSelfMovedToLobby = (newLocus === null || newLocus === void 0 ? void 0 : (_newLocus$
|
|
412
|
+
var isSelfMoved = _util2.default.isSelfMovedOrBreakoutEnded(newLocus);
|
|
413
|
+
var isSelfMovedToLobby = (newLocus === null || newLocus === void 0 ? void 0 : (_newLocus$self3 = newLocus.self) === null || _newLocus$self3 === void 0 ? void 0 : (_newLocus$self3$devic = _newLocus$self3.devices[0]) === null || _newLocus$self3$devic === void 0 ? void 0 : (_newLocus$self3$devic2 = _newLocus$self3$devic.intent) === null || _newLocus$self3$devic2 === void 0 ? void 0 : _newLocus$self3$devic2.reason) === _constants._ON_HOLD_LOBBY_ && (newLocus === null || newLocus === void 0 ? void 0 : (_newLocus$self4 = newLocus.self) === null || _newLocus$self4 === void 0 ? void 0 : (_newLocus$self4$devic = _newLocus$self4.devices[0]) === null || _newLocus$self4$devic === void 0 ? void 0 : (_newLocus$self4$devic2 = _newLocus$self4$devic.intent) === null || _newLocus$self4$devic2 === void 0 ? void 0 : _newLocus$self4$devic2.type) === _constants._WAIT_;
|
|
414
414
|
if (!meeting) {
|
|
415
415
|
if (isNewLocusAsBreakout) {
|
|
416
|
-
var _newLocus$fullState, _newLocus$
|
|
416
|
+
var _newLocus$fullState, _newLocus$self5;
|
|
417
417
|
_loggerProxy.default.logger.log("Meetings:index#isNeedHandleLocusDTO --> the first breakout session locusDTO active status: ".concat((_newLocus$fullState = newLocus.fullState) === null || _newLocus$fullState === void 0 ? void 0 : _newLocus$fullState.active));
|
|
418
|
-
return ((_newLocus$
|
|
418
|
+
return ((_newLocus$self5 = newLocus.self) === null || _newLocus$self5 === void 0 ? void 0 : _newLocus$self5.state) === _constants._JOINED_;
|
|
419
419
|
}
|
|
420
420
|
return this.isNeedHandleMainLocus(meeting, newLocus);
|
|
421
421
|
}
|
|
@@ -451,9 +451,7 @@ var Meetings = exports.default = /*#__PURE__*/function (_WebexPlugin) {
|
|
|
451
451
|
}
|
|
452
452
|
if (data.eventType === _constants.LOCUSEVENT.HASH_TREE_DATA_UPDATED) {
|
|
453
453
|
// need to check if maybe this event indicates a move to/from breakout
|
|
454
|
-
var meetingForHashTreeMessage = (0, _locusInfo.findMeetingForHashTreeMessage)(data.stateElementsMessage, this.meetingCollection
|
|
455
|
-
// @ts-ignore
|
|
456
|
-
this.webex.internal.device.url);
|
|
454
|
+
var meetingForHashTreeMessage = (0, _locusInfo.findMeetingForHashTreeMessage)(data === null || data === void 0 ? void 0 : data.stateElementsMessage, this.meetingCollection);
|
|
457
455
|
if (meetingForHashTreeMessage) {
|
|
458
456
|
return meetingForHashTreeMessage;
|
|
459
457
|
}
|
|
@@ -493,7 +491,6 @@ var Meetings = exports.default = /*#__PURE__*/function (_WebexPlugin) {
|
|
|
493
491
|
var _this2 = this;
|
|
494
492
|
var useRandomDelayForInfo = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
|
|
495
493
|
var meeting = this.getCorrespondingMeetingByLocus(data);
|
|
496
|
-
|
|
497
494
|
// @ts-ignore
|
|
498
495
|
if (this.config.experimental.storeLocusHashTreeEventsForDebugging) {
|
|
499
496
|
(0, _meeting.storeEventForDebugging)('mercury', data);
|
|
@@ -1675,7 +1672,11 @@ var Meetings = exports.default = /*#__PURE__*/function (_WebexPlugin) {
|
|
|
1675
1672
|
// For type LOCUS_ID we need to parse the locus object to get the information
|
|
1676
1673
|
// about the caller and callee
|
|
1677
1674
|
// Meeting Added event will be created in `handleLocusEvent`
|
|
1678
|
-
if
|
|
1675
|
+
// Only emit MEETING_ADDED if the meeting still exists in the collection.
|
|
1676
|
+
// If fetchMeetingInfo failed and the meeting was destroyed in the catch block,
|
|
1677
|
+
// skip emitting to prevent orphaned meeting references on the consumer side.
|
|
1678
|
+
// @ts-ignore - getMeetingByType types value as object but accepts strings (same as handleLocusEvent)
|
|
1679
|
+
if (type !== _constants.DESTINATION_TYPE.LOCUS_ID && this.getMeetingByType(_constants._ID_, meeting.id)) {
|
|
1679
1680
|
if (!meeting.sipUri) {
|
|
1680
1681
|
meeting.setSipUri(destination);
|
|
1681
1682
|
}
|
|
@@ -1741,51 +1742,135 @@ var Meetings = exports.default = /*#__PURE__*/function (_WebexPlugin) {
|
|
|
1741
1742
|
*/
|
|
1742
1743
|
}, {
|
|
1743
1744
|
key: "syncMeetings",
|
|
1744
|
-
value: function
|
|
1745
|
-
var
|
|
1746
|
-
|
|
1747
|
-
|
|
1748
|
-
|
|
1749
|
-
|
|
1750
|
-
|
|
1751
|
-
|
|
1752
|
-
|
|
1753
|
-
|
|
1754
|
-
|
|
1755
|
-
|
|
1756
|
-
|
|
1757
|
-
|
|
1758
|
-
|
|
1759
|
-
|
|
1760
|
-
|
|
1761
|
-
|
|
1762
|
-
|
|
1763
|
-
|
|
1764
|
-
|
|
1765
|
-
|
|
1766
|
-
|
|
1767
|
-
|
|
1768
|
-
|
|
1769
|
-
|
|
1770
|
-
|
|
1771
|
-
|
|
1772
|
-
|
|
1773
|
-
|
|
1774
|
-
|
|
1775
|
-
|
|
1776
|
-
|
|
1777
|
-
|
|
1778
|
-
|
|
1779
|
-
|
|
1780
|
-
|
|
1745
|
+
value: (function () {
|
|
1746
|
+
var _syncMeetings = (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee5() {
|
|
1747
|
+
var _this11 = this;
|
|
1748
|
+
var _ref4,
|
|
1749
|
+
_ref4$keepOnlyLocusMe,
|
|
1750
|
+
keepOnlyLocusMeetings,
|
|
1751
|
+
locusArray,
|
|
1752
|
+
activeLocusUrl,
|
|
1753
|
+
lociToUpdate,
|
|
1754
|
+
meetingsCollection,
|
|
1755
|
+
_loop,
|
|
1756
|
+
_i,
|
|
1757
|
+
_Object$values,
|
|
1758
|
+
remainingMeetings,
|
|
1759
|
+
syncPromises,
|
|
1760
|
+
_i2,
|
|
1761
|
+
_arr,
|
|
1762
|
+
meeting,
|
|
1763
|
+
_args6 = arguments,
|
|
1764
|
+
_t3;
|
|
1765
|
+
return _regenerator.default.wrap(function (_context6) {
|
|
1766
|
+
while (1) switch (_context6.prev = _context6.next) {
|
|
1767
|
+
case 0:
|
|
1768
|
+
_ref4 = _args6.length > 0 && _args6[0] !== undefined ? _args6[0] : {}, _ref4$keepOnlyLocusMe = _ref4.keepOnlyLocusMeetings, keepOnlyLocusMeetings = _ref4$keepOnlyLocusMe === void 0 ? true : _ref4$keepOnlyLocusMe;
|
|
1769
|
+
if (!this.webex.credentials.isUnverifiedGuest) {
|
|
1770
|
+
_context6.next = 1;
|
|
1771
|
+
break;
|
|
1772
|
+
}
|
|
1773
|
+
_loggerProxy.default.logger.info('Meetings:index#syncMeetings --> user is unverified guest, skipping calling Locus for meeting sync');
|
|
1774
|
+
_context6.next = 7;
|
|
1775
|
+
break;
|
|
1776
|
+
case 1:
|
|
1777
|
+
_context6.prev = 1;
|
|
1778
|
+
_context6.next = 2;
|
|
1779
|
+
return this.request.getActiveMeetings();
|
|
1780
|
+
case 2:
|
|
1781
|
+
locusArray = _context6.sent;
|
|
1782
|
+
activeLocusUrl = [];
|
|
1783
|
+
if (locusArray !== null && locusArray !== void 0 && locusArray.loci && locusArray.loci.length > 0) {
|
|
1784
|
+
lociToUpdate = this.sortLocusArrayToUpdate(locusArray.loci);
|
|
1785
|
+
lociToUpdate.forEach(function (locus) {
|
|
1786
|
+
activeLocusUrl.push(locus.url);
|
|
1787
|
+
_this11.handleLocusEvent({
|
|
1788
|
+
eventType: _constants.LOCUSEVENT.SDK_LOCUS_FROM_SYNC_MEETINGS,
|
|
1789
|
+
locus: locus,
|
|
1790
|
+
locusUrl: locus.url
|
|
1791
|
+
});
|
|
1792
|
+
});
|
|
1793
|
+
}
|
|
1794
|
+
meetingsCollection = this.meetingCollection.getAll();
|
|
1795
|
+
if (!((0, _keys.default)(meetingsCollection).length > 0)) {
|
|
1796
|
+
_context6.next = 5;
|
|
1797
|
+
break;
|
|
1798
|
+
}
|
|
1799
|
+
_loop = /*#__PURE__*/_regenerator.default.mark(function _loop() {
|
|
1800
|
+
var meeting, locusUrl, locusInfo, _locusInfo$info, _locusArray$loci, globalMeetingId;
|
|
1801
|
+
return _regenerator.default.wrap(function (_context5) {
|
|
1802
|
+
while (1) switch (_context5.prev = _context5.next) {
|
|
1803
|
+
case 0:
|
|
1804
|
+
meeting = _Object$values[_i];
|
|
1805
|
+
// @ts-ignore
|
|
1806
|
+
locusUrl = meeting.locusUrl, locusInfo = meeting.locusInfo;
|
|
1807
|
+
if ((keepOnlyLocusMeetings || locusUrl) && !activeLocusUrl.includes(locusUrl)) {
|
|
1808
|
+
globalMeetingId = locusInfo === null || locusInfo === void 0 ? void 0 : (_locusInfo$info = locusInfo.info) === null || _locusInfo$info === void 0 ? void 0 : _locusInfo$info.globalMeetingId;
|
|
1809
|
+
if (globalMeetingId && locusArray !== null && locusArray !== void 0 && (_locusArray$loci = locusArray.loci) !== null && _locusArray$loci !== void 0 && _locusArray$loci.some(function (locus) {
|
|
1810
|
+
var _locus$info;
|
|
1811
|
+
return ((_locus$info = locus.info) === null || _locus$info === void 0 ? void 0 : _locus$info.globalMeetingId) === globalMeetingId;
|
|
1812
|
+
})) {
|
|
1813
|
+
// don't destroy the meeting as Locus API still returned some Locus that shares
|
|
1814
|
+
// the same globalMeetingId - that happens for example if a webinar user (who hasn't scheduled it)
|
|
1815
|
+
// is in a breakout and gets moved to a different breakout while we were offline
|
|
1816
|
+
} else {
|
|
1817
|
+
// destroy function also uploads logs
|
|
1818
|
+
// @ts-ignore
|
|
1819
|
+
_this11.destroy(meeting, _constants.MEETING_REMOVED_REASON.NO_MEETINGS_TO_SYNC);
|
|
1820
|
+
}
|
|
1821
|
+
}
|
|
1822
|
+
case 1:
|
|
1823
|
+
case "end":
|
|
1824
|
+
return _context5.stop();
|
|
1825
|
+
}
|
|
1826
|
+
}, _loop);
|
|
1827
|
+
});
|
|
1828
|
+
_i = 0, _Object$values = (0, _values.default)(meetingsCollection);
|
|
1829
|
+
case 3:
|
|
1830
|
+
if (!(_i < _Object$values.length)) {
|
|
1831
|
+
_context6.next = 5;
|
|
1832
|
+
break;
|
|
1833
|
+
}
|
|
1834
|
+
return _context6.delegateYield(_loop(), "t0", 4);
|
|
1835
|
+
case 4:
|
|
1836
|
+
_i++;
|
|
1837
|
+
_context6.next = 3;
|
|
1838
|
+
break;
|
|
1839
|
+
case 5:
|
|
1840
|
+
_context6.next = 7;
|
|
1841
|
+
break;
|
|
1842
|
+
case 6:
|
|
1843
|
+
_context6.prev = 6;
|
|
1844
|
+
_t3 = _context6["catch"](1);
|
|
1845
|
+
_loggerProxy.default.logger.error("Meetings:index#syncMeetings --> failed to sync meetings, ".concat(_t3));
|
|
1846
|
+
throw _t3;
|
|
1847
|
+
case 7:
|
|
1848
|
+
// Trigger hash tree syncs for all remaining meetings
|
|
1849
|
+
remainingMeetings = this.meetingCollection.getAll();
|
|
1850
|
+
syncPromises = [];
|
|
1851
|
+
for (_i2 = 0, _arr = (0, _values.default)(remainingMeetings); _i2 < _arr.length; _i2++) {
|
|
1852
|
+
meeting = _arr[_i2];
|
|
1853
|
+
if (meeting.locusInfo) {
|
|
1854
|
+
syncPromises.push(meeting.locusInfo.syncAllHashTreeDatasets());
|
|
1855
|
+
}
|
|
1856
|
+
}
|
|
1857
|
+
if (!(syncPromises.length > 0)) {
|
|
1858
|
+
_context6.next = 8;
|
|
1859
|
+
break;
|
|
1860
|
+
}
|
|
1861
|
+
_context6.next = 8;
|
|
1862
|
+
return _promise.default.all(syncPromises);
|
|
1863
|
+
case 8:
|
|
1864
|
+
case "end":
|
|
1865
|
+
return _context6.stop();
|
|
1781
1866
|
}
|
|
1782
|
-
}
|
|
1783
|
-
})
|
|
1784
|
-
|
|
1785
|
-
|
|
1786
|
-
}
|
|
1787
|
-
|
|
1788
|
-
|
|
1867
|
+
}, _callee5, this, [[1, 6]]);
|
|
1868
|
+
}));
|
|
1869
|
+
function syncMeetings() {
|
|
1870
|
+
return _syncMeetings.apply(this, arguments);
|
|
1871
|
+
}
|
|
1872
|
+
return syncMeetings;
|
|
1873
|
+
}()
|
|
1789
1874
|
/**
|
|
1790
1875
|
* sort out locus array for initial creating
|
|
1791
1876
|
* @param {Array} loci original locus array
|
|
@@ -1793,6 +1878,7 @@ var Meetings = exports.default = /*#__PURE__*/function (_WebexPlugin) {
|
|
|
1793
1878
|
* @public
|
|
1794
1879
|
* @memberof Meetings
|
|
1795
1880
|
*/
|
|
1881
|
+
)
|
|
1796
1882
|
}, {
|
|
1797
1883
|
key: "sortLocusArrayToUpdate",
|
|
1798
1884
|
value: function sortLocusArrayToUpdate(loci) {
|
|
@@ -1807,8 +1893,7 @@ var Meetings = exports.default = /*#__PURE__*/function (_WebexPlugin) {
|
|
|
1807
1893
|
var lociToUpdate = (0, _toConsumableArray2.default)(mainLoci);
|
|
1808
1894
|
breakoutLoci.forEach(function (breakoutLocus) {
|
|
1809
1895
|
var associateMainLocus = mainLoci.find(function (mainLocus) {
|
|
1810
|
-
|
|
1811
|
-
return ((_mainLocus$controls = mainLocus.controls) === null || _mainLocus$controls === void 0 ? void 0 : (_mainLocus$controls$b = _mainLocus$controls.breakout) === null || _mainLocus$controls$b === void 0 ? void 0 : _mainLocus$controls$b.url) === ((_breakoutLocus$contro = breakoutLocus.controls) === null || _breakoutLocus$contro === void 0 ? void 0 : (_breakoutLocus$contro2 = _breakoutLocus$contro.breakout) === null || _breakoutLocus$contro2 === void 0 ? void 0 : _breakoutLocus$contro2.url);
|
|
1896
|
+
return _util2.default.isMainAssociatedWithBreakout(mainLocus, breakoutLocus);
|
|
1812
1897
|
});
|
|
1813
1898
|
var existCorrespondingMeeting = _this12.getCorrespondingMeetingByLocus({
|
|
1814
1899
|
eventType: _constants.LOCUSEVENT.SDK_NO_EVENT,
|
|
@@ -1844,8 +1929,7 @@ var Meetings = exports.default = /*#__PURE__*/function (_WebexPlugin) {
|
|
|
1844
1929
|
return;
|
|
1845
1930
|
}
|
|
1846
1931
|
var existIndex = this.breakoutLocusForHandleLater.findIndex(function (breakoutLocus) {
|
|
1847
|
-
|
|
1848
|
-
return ((_breakoutLocus$contro3 = breakoutLocus.controls) === null || _breakoutLocus$contro3 === void 0 ? void 0 : (_breakoutLocus$contro4 = _breakoutLocus$contro3.breakout) === null || _breakoutLocus$contro4 === void 0 ? void 0 : _breakoutLocus$contro4.url) === ((_newCreatedLocus$cont = newCreatedLocus.controls) === null || _newCreatedLocus$cont === void 0 ? void 0 : (_newCreatedLocus$cont2 = _newCreatedLocus$cont.breakout) === null || _newCreatedLocus$cont2 === void 0 ? void 0 : _newCreatedLocus$cont2.url);
|
|
1932
|
+
return _util2.default.isMainAssociatedWithBreakout(newCreatedLocus, breakoutLocus);
|
|
1849
1933
|
});
|
|
1850
1934
|
if (existIndex < 0) {
|
|
1851
1935
|
return;
|