@webex/plugin-meetings 3.0.0-beta.1 → 3.0.0-beta.104
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/UPGRADING.md +9 -9
- package/browsers.js +19 -24
- package/dist/annotation/annotation.types.js +7 -0
- package/dist/annotation/annotation.types.js.map +1 -0
- package/dist/annotation/constants.js +48 -0
- package/dist/annotation/constants.js.map +1 -0
- package/dist/annotation/index.js +357 -0
- package/dist/annotation/index.js.map +1 -0
- package/dist/breakouts/breakout.js +176 -0
- package/dist/breakouts/breakout.js.map +1 -0
- package/dist/breakouts/collection.js +23 -0
- package/dist/breakouts/collection.js.map +1 -0
- package/dist/breakouts/edit-lock-error.js +52 -0
- package/dist/breakouts/edit-lock-error.js.map +1 -0
- package/dist/breakouts/events.js +43 -0
- package/dist/breakouts/events.js.map +1 -0
- package/dist/breakouts/index.js +919 -0
- package/dist/breakouts/index.js.map +1 -0
- package/dist/breakouts/request.js +78 -0
- package/dist/breakouts/request.js.map +1 -0
- package/dist/breakouts/utils.js +67 -0
- package/dist/breakouts/utils.js.map +1 -0
- package/dist/common/browser-detection.js +1 -20
- package/dist/common/browser-detection.js.map +1 -1
- package/dist/common/collection.js +5 -20
- package/dist/common/collection.js.map +1 -1
- package/dist/common/config.js +0 -7
- package/dist/common/config.js.map +1 -1
- package/dist/common/errors/captcha-error.js +10 -24
- package/dist/common/errors/captcha-error.js.map +1 -1
- package/dist/common/errors/intent-to-join.js +11 -24
- package/dist/common/errors/intent-to-join.js.map +1 -1
- package/dist/common/errors/join-meeting.js +12 -25
- package/dist/common/errors/join-meeting.js.map +1 -1
- package/dist/common/errors/media.js +10 -24
- package/dist/common/errors/media.js.map +1 -1
- package/dist/common/errors/parameter.js +5 -33
- package/dist/common/errors/parameter.js.map +1 -1
- package/dist/common/errors/password-error.js +10 -24
- package/dist/common/errors/password-error.js.map +1 -1
- package/dist/common/errors/permission.js +9 -23
- package/dist/common/errors/permission.js.map +1 -1
- package/dist/common/errors/reconnection-in-progress.js +0 -17
- package/dist/common/errors/reconnection-in-progress.js.map +1 -1
- package/dist/common/errors/reconnection.js +10 -24
- package/dist/common/errors/reconnection.js.map +1 -1
- package/dist/common/errors/stats.js +10 -24
- package/dist/common/errors/stats.js.map +1 -1
- package/dist/common/errors/webex-errors.js +10 -69
- package/dist/common/errors/webex-errors.js.map +1 -1
- package/dist/common/errors/webex-meetings-error.js +5 -25
- package/dist/common/errors/webex-meetings-error.js.map +1 -1
- package/dist/common/events/events-scope.js +0 -22
- package/dist/common/events/events-scope.js.map +1 -1
- package/dist/common/events/events.js +0 -23
- package/dist/common/events/events.js.map +1 -1
- package/dist/common/events/trigger-proxy.js +0 -12
- package/dist/common/events/trigger-proxy.js.map +1 -1
- package/dist/common/events/util.js +0 -15
- package/dist/common/events/util.js.map +1 -1
- package/dist/common/logs/logger-config.js +0 -4
- package/dist/common/logs/logger-config.js.map +1 -1
- package/dist/common/logs/logger-proxy.js +1 -8
- package/dist/common/logs/logger-proxy.js.map +1 -1
- package/dist/common/logs/request.js +37 -60
- package/dist/common/logs/request.js.map +1 -1
- package/dist/common/queue.js +4 -14
- package/dist/common/queue.js.map +1 -1
- package/dist/config.js +7 -6
- package/dist/config.js.map +1 -1
- package/dist/constants.js +184 -122
- package/dist/constants.js.map +1 -1
- package/dist/controls-options-manager/constants.js +14 -0
- package/dist/controls-options-manager/constants.js.map +1 -0
- package/dist/controls-options-manager/enums.js +25 -0
- package/dist/controls-options-manager/enums.js.map +1 -0
- package/dist/controls-options-manager/index.js +297 -0
- package/dist/controls-options-manager/index.js.map +1 -0
- package/dist/controls-options-manager/types.js +7 -0
- package/dist/controls-options-manager/types.js.map +1 -0
- package/dist/controls-options-manager/util.js +250 -0
- package/dist/controls-options-manager/util.js.map +1 -0
- package/dist/index.js +72 -17
- package/dist/index.js.map +1 -1
- package/dist/locus-info/controlsUtils.js +56 -29
- package/dist/locus-info/controlsUtils.js.map +1 -1
- package/dist/locus-info/embeddedAppsUtils.js +3 -26
- package/dist/locus-info/embeddedAppsUtils.js.map +1 -1
- package/dist/locus-info/fullState.js +0 -15
- package/dist/locus-info/fullState.js.map +1 -1
- package/dist/locus-info/hostUtils.js +4 -12
- package/dist/locus-info/hostUtils.js.map +1 -1
- package/dist/locus-info/index.js +362 -208
- package/dist/locus-info/index.js.map +1 -1
- package/dist/locus-info/infoUtils.js +3 -37
- package/dist/locus-info/infoUtils.js.map +1 -1
- package/dist/locus-info/mediaSharesUtils.js +12 -38
- package/dist/locus-info/mediaSharesUtils.js.map +1 -1
- package/dist/locus-info/parser.js +92 -118
- package/dist/locus-info/parser.js.map +1 -1
- package/dist/locus-info/selfUtils.js +99 -91
- package/dist/locus-info/selfUtils.js.map +1 -1
- package/dist/media/index.js +113 -337
- package/dist/media/index.js.map +1 -1
- package/dist/media/properties.js +96 -135
- package/dist/media/properties.js.map +1 -1
- package/dist/media/util.js +1 -35
- package/dist/media/util.js.map +1 -1
- package/dist/mediaQualityMetrics/config.js +505 -495
- package/dist/mediaQualityMetrics/config.js.map +1 -1
- package/dist/meeting/in-meeting-actions.js +59 -14
- package/dist/meeting/in-meeting-actions.js.map +1 -1
- package/dist/meeting/index.js +2909 -2398
- package/dist/meeting/index.js.map +1 -1
- package/dist/meeting/muteState.js +257 -112
- package/dist/meeting/muteState.js.map +1 -1
- package/dist/meeting/request.js +330 -264
- package/dist/meeting/request.js.map +1 -1
- package/dist/meeting/request.type.js +7 -0
- package/dist/meeting/request.type.js.map +1 -0
- package/dist/meeting/state.js +21 -31
- package/dist/meeting/state.js.map +1 -1
- package/dist/meeting/util.js +63 -261
- package/dist/meeting/util.js.map +1 -1
- package/dist/meeting-info/collection.js +6 -25
- package/dist/meeting-info/collection.js.map +1 -1
- package/dist/meeting-info/index.js +14 -32
- package/dist/meeting-info/index.js.map +1 -1
- package/dist/meeting-info/meeting-info-v2.js +273 -280
- package/dist/meeting-info/meeting-info-v2.js.map +1 -1
- package/dist/meeting-info/request.js +3 -15
- package/dist/meeting-info/request.js.map +1 -1
- package/dist/meeting-info/util.js +98 -183
- package/dist/meeting-info/util.js.map +1 -1
- package/dist/meeting-info/utilv2.js +155 -232
- package/dist/meeting-info/utilv2.js.map +1 -1
- package/dist/meetings/collection.js +26 -19
- package/dist/meetings/collection.js.map +1 -1
- package/dist/meetings/index.js +741 -548
- package/dist/meetings/index.js.map +1 -1
- package/dist/meetings/request.js +26 -41
- package/dist/meetings/request.js.map +1 -1
- package/dist/meetings/util.js +194 -149
- package/dist/meetings/util.js.map +1 -1
- package/dist/member/index.js +100 -85
- package/dist/member/index.js.map +1 -1
- package/dist/member/types.js +15 -0
- package/dist/member/types.js.map +1 -0
- package/dist/member/util.js +90 -68
- package/dist/member/util.js.map +1 -1
- package/dist/members/collection.js +13 -12
- package/dist/members/collection.js.map +1 -1
- package/dist/members/index.js +227 -188
- package/dist/members/index.js.map +1 -1
- package/dist/members/request.js +54 -39
- package/dist/members/request.js.map +1 -1
- package/dist/members/types.js +15 -0
- package/dist/members/types.js.map +1 -0
- package/dist/members/util.js +107 -44
- package/dist/members/util.js.map +1 -1
- package/dist/metrics/config.js +5 -14
- package/dist/metrics/config.js.map +1 -1
- package/dist/metrics/constants.js +3 -7
- package/dist/metrics/constants.js.map +1 -1
- package/dist/metrics/index.js +67 -159
- package/dist/metrics/index.js.map +1 -1
- package/dist/multistream/mediaRequestManager.js +250 -0
- package/dist/multistream/mediaRequestManager.js.map +1 -0
- package/dist/multistream/receiveSlot.js +202 -0
- package/dist/multistream/receiveSlot.js.map +1 -0
- package/dist/multistream/receiveSlotManager.js +176 -0
- package/dist/multistream/receiveSlotManager.js.map +1 -0
- package/dist/multistream/remoteMedia.js +270 -0
- package/dist/multistream/remoteMedia.js.map +1 -0
- package/dist/multistream/remoteMediaGroup.js +209 -0
- package/dist/multistream/remoteMediaGroup.js.map +1 -0
- package/dist/multistream/remoteMediaManager.js +1137 -0
- package/dist/multistream/remoteMediaManager.js.map +1 -0
- package/dist/networkQualityMonitor/index.js +40 -59
- package/dist/networkQualityMonitor/index.js.map +1 -1
- package/dist/personal-meeting-room/index.js +21 -45
- package/dist/personal-meeting-room/index.js.map +1 -1
- package/dist/personal-meeting-room/request.js +1 -31
- package/dist/personal-meeting-room/request.js.map +1 -1
- package/dist/personal-meeting-room/util.js +0 -13
- package/dist/personal-meeting-room/util.js.map +1 -1
- package/dist/reachability/index.js +192 -191
- package/dist/reachability/index.js.map +1 -1
- package/dist/reachability/request.js +15 -23
- package/dist/reachability/request.js.map +1 -1
- package/dist/reactions/constants.js +13 -0
- package/dist/reactions/constants.js.map +1 -0
- package/dist/reactions/reactions.js +109 -0
- package/dist/reactions/reactions.js.map +1 -0
- package/dist/reactions/reactions.type.js +36 -0
- package/dist/reactions/reactions.type.js.map +1 -0
- package/dist/reconnection-manager/index.js +386 -527
- package/dist/reconnection-manager/index.js.map +1 -1
- package/dist/recording-controller/enums.js +17 -0
- package/dist/recording-controller/enums.js.map +1 -0
- package/dist/recording-controller/index.js +343 -0
- package/dist/recording-controller/index.js.map +1 -0
- package/dist/recording-controller/util.js +63 -0
- package/dist/recording-controller/util.js.map +1 -0
- package/dist/roap/index.js +84 -286
- package/dist/roap/index.js.map +1 -1
- package/dist/roap/request.js +138 -238
- package/dist/roap/request.js.map +1 -1
- package/dist/roap/turnDiscovery.js +164 -102
- package/dist/roap/turnDiscovery.js.map +1 -1
- package/dist/statsAnalyzer/global.js +1 -93
- package/dist/statsAnalyzer/global.js.map +1 -1
- package/dist/statsAnalyzer/index.js +399 -470
- package/dist/statsAnalyzer/index.js.map +1 -1
- package/dist/statsAnalyzer/mqaUtil.js +143 -87
- package/dist/statsAnalyzer/mqaUtil.js.map +1 -1
- package/dist/transcription/index.js +22 -47
- package/dist/transcription/index.js.map +1 -1
- package/dist/types/annotation/annotation.types.d.ts +34 -0
- package/dist/types/annotation/constants.d.ts +31 -0
- package/dist/types/annotation/index.d.ts +124 -0
- package/dist/types/breakouts/breakout.d.ts +8 -0
- package/dist/types/breakouts/collection.d.ts +5 -0
- package/dist/types/breakouts/edit-lock-error.d.ts +15 -0
- package/dist/types/breakouts/events.d.ts +2 -0
- package/dist/types/breakouts/index.d.ts +5 -0
- package/dist/types/breakouts/request.d.ts +22 -0
- package/dist/types/breakouts/utils.d.ts +15 -0
- package/dist/types/common/browser-detection.d.ts +9 -0
- package/dist/types/common/collection.d.ts +48 -0
- package/dist/types/common/config.d.ts +2 -0
- package/dist/types/common/errors/captcha-error.d.ts +15 -0
- package/dist/types/common/errors/intent-to-join.d.ts +16 -0
- package/dist/types/common/errors/join-meeting.d.ts +17 -0
- package/dist/types/common/errors/media.d.ts +15 -0
- package/dist/types/common/errors/parameter.d.ts +15 -0
- package/dist/types/common/errors/password-error.d.ts +15 -0
- package/dist/types/common/errors/permission.d.ts +14 -0
- package/dist/types/common/errors/reconnection-in-progress.d.ts +9 -0
- package/dist/types/common/errors/reconnection.d.ts +15 -0
- package/dist/types/common/errors/stats.d.ts +15 -0
- package/dist/types/common/errors/webex-errors.d.ts +69 -0
- package/dist/types/common/errors/webex-meetings-error.d.ts +20 -0
- package/dist/types/common/events/events-scope.d.ts +17 -0
- package/dist/types/common/events/events.d.ts +12 -0
- package/dist/types/common/events/trigger-proxy.d.ts +2 -0
- package/dist/types/common/events/util.d.ts +2 -0
- package/dist/types/common/logs/logger-config.d.ts +2 -0
- package/dist/types/common/logs/logger-proxy.d.ts +2 -0
- package/dist/types/common/logs/request.d.ts +34 -0
- package/dist/types/common/queue.d.ts +32 -0
- package/dist/types/config.d.ts +78 -0
- package/dist/types/constants.d.ts +968 -0
- package/dist/types/controls-options-manager/constants.d.ts +4 -0
- package/dist/types/controls-options-manager/enums.d.ts +13 -0
- package/dist/types/controls-options-manager/index.d.ts +136 -0
- package/dist/types/controls-options-manager/types.d.ts +37 -0
- package/dist/types/controls-options-manager/util.d.ts +1 -0
- package/dist/types/index.d.ts +7 -0
- package/dist/types/locus-info/controlsUtils.d.ts +2 -0
- package/dist/types/locus-info/embeddedAppsUtils.d.ts +2 -0
- package/dist/types/locus-info/fullState.d.ts +2 -0
- package/dist/types/locus-info/hostUtils.d.ts +2 -0
- package/dist/types/locus-info/index.d.ts +315 -0
- package/dist/types/locus-info/infoUtils.d.ts +2 -0
- package/dist/types/locus-info/mediaSharesUtils.d.ts +2 -0
- package/dist/types/locus-info/parser.d.ts +212 -0
- package/dist/types/locus-info/selfUtils.d.ts +2 -0
- package/dist/types/media/index.d.ts +34 -0
- package/dist/types/media/properties.d.ts +108 -0
- package/dist/types/media/util.d.ts +2 -0
- package/dist/types/mediaQualityMetrics/config.d.ts +365 -0
- package/dist/types/meeting/in-meeting-actions.d.ts +129 -0
- package/dist/types/meeting/index.d.ts +1748 -0
- package/dist/types/meeting/muteState.d.ts +185 -0
- package/dist/types/meeting/request.d.ts +275 -0
- package/dist/types/meeting/request.type.d.ts +11 -0
- package/dist/types/meeting/state.d.ts +9 -0
- package/dist/types/meeting/util.d.ts +2 -0
- package/dist/types/meeting-info/collection.d.ts +20 -0
- package/dist/types/meeting-info/index.d.ts +57 -0
- package/dist/types/meeting-info/meeting-info-v2.d.ts +112 -0
- package/dist/types/meeting-info/request.d.ts +22 -0
- package/dist/types/meeting-info/util.d.ts +2 -0
- package/dist/types/meeting-info/utilv2.d.ts +2 -0
- package/dist/types/meetings/collection.d.ts +31 -0
- package/dist/types/meetings/index.d.ts +345 -0
- package/dist/types/meetings/request.d.ts +27 -0
- package/dist/types/meetings/util.d.ts +18 -0
- package/dist/types/member/index.d.ts +156 -0
- package/dist/types/member/types.d.ts +21 -0
- package/dist/types/member/util.d.ts +2 -0
- package/dist/types/members/collection.d.ts +29 -0
- package/dist/types/members/index.d.ts +353 -0
- package/dist/types/members/request.d.ts +69 -0
- package/dist/types/members/types.d.ts +24 -0
- package/dist/types/members/util.d.ts +2 -0
- package/dist/types/metrics/config.d.ts +172 -0
- package/dist/types/metrics/constants.d.ts +54 -0
- package/dist/types/metrics/index.d.ts +152 -0
- package/dist/types/multistream/mediaRequestManager.d.ts +101 -0
- package/dist/types/multistream/receiveSlot.d.ts +68 -0
- package/dist/types/multistream/receiveSlotManager.d.ts +56 -0
- package/dist/types/multistream/remoteMedia.d.ts +72 -0
- package/dist/types/multistream/remoteMediaGroup.d.ts +47 -0
- package/dist/types/multistream/remoteMediaManager.d.ts +263 -0
- package/dist/types/networkQualityMonitor/index.d.ts +70 -0
- package/dist/types/personal-meeting-room/index.d.ts +47 -0
- package/dist/types/personal-meeting-room/request.d.ts +14 -0
- package/dist/types/personal-meeting-room/util.d.ts +2 -0
- package/dist/types/reachability/index.d.ts +152 -0
- package/dist/types/reachability/request.d.ts +37 -0
- package/dist/types/reactions/constants.d.ts +3 -0
- package/dist/types/reactions/reactions.d.ts +4 -0
- package/dist/types/reactions/reactions.type.d.ts +52 -0
- package/dist/types/reconnection-manager/index.d.ts +126 -0
- package/dist/types/recording-controller/enums.d.ts +7 -0
- package/dist/types/recording-controller/index.d.ts +193 -0
- package/dist/types/recording-controller/util.d.ts +13 -0
- package/dist/types/roap/index.d.ts +77 -0
- package/dist/types/roap/request.d.ts +38 -0
- package/dist/types/roap/turnDiscovery.d.ts +88 -0
- package/dist/types/statsAnalyzer/global.d.ts +36 -0
- package/dist/types/statsAnalyzer/index.d.ts +200 -0
- package/dist/types/statsAnalyzer/mqaUtil.d.ts +24 -0
- package/dist/types/transcription/index.d.ts +64 -0
- package/internal-README.md +7 -6
- package/package.json +29 -21
- package/src/annotation/annotation.types.ts +41 -0
- package/src/annotation/constants.ts +36 -0
- package/src/annotation/index.ts +339 -0
- package/src/breakouts/README.md +219 -0
- package/src/breakouts/breakout.ts +141 -0
- package/src/breakouts/collection.ts +19 -0
- package/src/breakouts/edit-lock-error.ts +25 -0
- package/src/breakouts/events.ts +37 -0
- package/src/breakouts/index.ts +823 -0
- package/src/breakouts/request.ts +55 -0
- package/src/breakouts/utils.ts +57 -0
- package/src/common/{browser-detection.js → browser-detection.ts} +9 -6
- package/src/common/collection.ts +9 -7
- package/src/common/{config.js → config.ts} +1 -1
- package/src/common/errors/{captcha-error.js → captcha-error.ts} +11 -7
- package/src/common/errors/{intent-to-join.js → intent-to-join.ts} +12 -7
- package/src/common/errors/{join-meeting.js → join-meeting.ts} +17 -8
- package/src/common/errors/{media.js → media.ts} +11 -7
- package/src/common/errors/parameter.ts +11 -7
- package/src/common/errors/{password-error.js → password-error.ts} +11 -7
- package/src/common/errors/{permission.js → permission.ts} +10 -6
- package/src/common/errors/{reconnection.js → reconnection.ts} +11 -7
- package/src/common/errors/{stats.js → stats.ts} +11 -7
- package/src/common/errors/{webex-errors.js → webex-errors.ts} +8 -25
- package/src/common/errors/{webex-meetings-error.js → webex-meetings-error.ts} +4 -2
- package/src/common/events/{events-scope.js → events-scope.ts} +6 -2
- package/src/common/events/{events.js → events.ts} +5 -1
- package/src/common/events/{trigger-proxy.js → trigger-proxy.ts} +9 -5
- package/src/common/events/{util.js → util.ts} +2 -3
- package/src/common/logs/{logger-config.js → logger-config.ts} +1 -2
- package/src/common/logs/logger-proxy.ts +44 -0
- package/src/common/logs/{request.js → request.ts} +22 -9
- package/src/common/queue.ts +1 -2
- package/src/{config.js → config.ts} +18 -12
- package/src/constants.ts +256 -183
- package/src/controls-options-manager/constants.ts +5 -0
- package/src/controls-options-manager/enums.ts +16 -0
- package/src/controls-options-manager/index.ts +278 -0
- package/src/controls-options-manager/types.ts +49 -0
- package/src/controls-options-manager/util.ts +229 -0
- package/src/index.ts +33 -0
- package/src/locus-info/controlsUtils.ts +169 -0
- package/src/locus-info/{embeddedAppsUtils.js → embeddedAppsUtils.ts} +5 -6
- package/src/locus-info/{fullState.js → fullState.ts} +16 -12
- package/src/locus-info/{hostUtils.js → hostUtils.ts} +9 -8
- package/src/locus-info/{index.js → index.ts} +331 -80
- package/src/locus-info/{infoUtils.js → infoUtils.ts} +19 -8
- package/src/locus-info/{mediaSharesUtils.js → mediaSharesUtils.ts} +17 -17
- package/src/locus-info/{parser.js → parser.ts} +67 -79
- package/src/locus-info/{selfUtils.js → selfUtils.ts} +196 -67
- package/src/media/index.ts +488 -0
- package/src/media/{properties.js → properties.ts} +67 -54
- package/src/media/util.ts +16 -0
- package/src/mediaQualityMetrics/config.ts +384 -0
- package/src/meeting/in-meeting-actions.ts +123 -3
- package/src/meeting/{index.js → index.ts} +3334 -1775
- package/src/meeting/muteState.ts +526 -0
- package/src/meeting/{request.js → request.ts} +350 -142
- package/src/meeting/request.type.ts +13 -0
- package/src/meeting/{state.js → state.ts} +50 -35
- package/src/meeting/{util.js → util.ts} +126 -159
- package/src/meeting-info/{collection.js → collection.ts} +6 -2
- package/src/meeting-info/{index.js → index.ts} +42 -36
- package/src/meeting-info/meeting-info-v2.ts +345 -0
- package/src/meeting-info/{request.js → request.ts} +14 -4
- package/src/meeting-info/{util.js → util.ts} +60 -51
- package/src/meeting-info/{utilv2.js → utilv2.ts} +76 -60
- package/src/meetings/{collection.js → collection.ts} +26 -3
- package/src/meetings/index.ts +1394 -0
- package/src/meetings/{request.js → request.ts} +34 -25
- package/src/meetings/util.ts +288 -0
- package/src/member/{index.js → index.ts} +124 -56
- package/src/member/types.ts +24 -0
- package/src/member/{util.js → util.ts} +105 -25
- package/src/members/{collection.js → collection.ts} +10 -2
- package/src/members/{index.js → index.ts} +359 -139
- package/src/members/request.ts +215 -0
- package/src/members/types.ts +28 -0
- package/src/members/{util.js → util.ts} +145 -54
- package/src/metrics/{config.js → config.ts} +256 -92
- package/src/metrics/{constants.js → constants.ts} +1 -6
- package/src/metrics/{index.js → index.ts} +116 -97
- package/src/multistream/mediaRequestManager.ts +324 -0
- package/src/multistream/receiveSlot.ts +184 -0
- package/src/multistream/receiveSlotManager.ts +166 -0
- package/src/multistream/remoteMedia.ts +254 -0
- package/src/multistream/remoteMediaGroup.ts +225 -0
- package/src/multistream/remoteMediaManager.ts +1075 -0
- package/src/networkQualityMonitor/{index.js → index.ts} +41 -29
- package/src/personal-meeting-room/{index.js → index.ts} +28 -19
- package/src/personal-meeting-room/{request.js → request.ts} +13 -4
- package/src/personal-meeting-room/{util.js → util.ts} +4 -4
- package/src/reachability/{index.js → index.ts} +157 -94
- package/src/reachability/request.ts +46 -35
- package/src/reactions/constants.ts +4 -0
- package/src/reactions/reactions.ts +104 -0
- package/src/reactions/reactions.type.ts +62 -0
- package/src/reconnection-manager/{index.js → index.ts} +261 -163
- package/src/recording-controller/enums.ts +8 -0
- package/src/recording-controller/index.ts +315 -0
- package/src/recording-controller/util.ts +58 -0
- package/src/roap/index.ts +241 -0
- package/src/roap/request.ts +172 -0
- package/src/roap/turnDiscovery.ts +127 -53
- package/src/statsAnalyzer/global.ts +37 -0
- package/src/statsAnalyzer/index.ts +1273 -0
- package/src/statsAnalyzer/mqaUtil.ts +291 -0
- package/src/transcription/{index.js → index.ts} +46 -39
- package/test/integration/spec/converged-space-meetings.js +177 -0
- package/test/integration/spec/journey.js +666 -464
- package/test/integration/spec/space-meeting.js +321 -206
- package/test/integration/spec/transcription.js +7 -8
- package/test/unit/spec/annotation/index.ts +435 -0
- package/test/unit/spec/breakouts/breakout.ts +184 -0
- package/test/unit/spec/breakouts/collection.ts +15 -0
- package/test/unit/spec/breakouts/edit-lock-error.ts +30 -0
- package/test/unit/spec/breakouts/events.ts +77 -0
- package/test/unit/spec/breakouts/index.ts +1504 -0
- package/test/unit/spec/breakouts/request.ts +104 -0
- package/test/unit/spec/breakouts/utils.js +72 -0
- package/test/unit/spec/common/browser-detection.js +9 -28
- package/test/unit/spec/controls-options-manager/index.js +287 -0
- package/test/unit/spec/controls-options-manager/util.js +403 -0
- package/test/unit/spec/fixture/locus.js +92 -90
- package/test/unit/spec/locus-info/controlsUtils.js +177 -32
- package/test/unit/spec/locus-info/embeddedAppsUtils.js +8 -6
- package/test/unit/spec/locus-info/index.js +493 -3
- package/test/unit/spec/locus-info/infoUtils.js +41 -32
- package/test/unit/spec/locus-info/lib/BasicSeqCmp.json +88 -430
- package/test/unit/spec/locus-info/lib/SeqCmp.json +513 -685
- package/test/unit/spec/locus-info/parser.js +3 -9
- package/test/unit/spec/locus-info/selfConstant.js +110 -103
- package/test/unit/spec/locus-info/selfUtils.js +236 -12
- package/test/unit/spec/media/index.ts +303 -0
- package/test/unit/spec/media/properties.ts +73 -82
- package/test/unit/spec/meeting/in-meeting-actions.ts +58 -3
- package/test/unit/spec/meeting/index.js +3127 -975
- package/test/unit/spec/meeting/muteState.js +375 -70
- package/test/unit/spec/meeting/request.js +217 -43
- package/test/unit/spec/meeting/utils.js +205 -163
- package/test/unit/spec/meeting-info/meetinginfov2.js +268 -74
- package/test/unit/spec/meeting-info/request.js +7 -9
- package/test/unit/spec/meeting-info/util.js +11 -12
- package/test/unit/spec/meeting-info/utilv2.js +131 -74
- package/test/unit/spec/meetings/collection.js +15 -1
- package/test/unit/spec/meetings/index.js +1052 -333
- package/test/unit/spec/meetings/utils.js +163 -14
- package/test/unit/spec/member/index.js +24 -1
- package/test/unit/spec/member/util.js +359 -32
- package/test/unit/spec/members/index.js +547 -37
- package/test/unit/spec/members/request.js +76 -20
- package/test/unit/spec/members/utils.js +191 -4
- package/test/unit/spec/metrics/index.js +46 -20
- package/test/unit/spec/multistream/mediaRequestManager.ts +1060 -0
- package/test/unit/spec/multistream/receiveSlot.ts +163 -0
- package/test/unit/spec/multistream/receiveSlotManager.ts +203 -0
- package/test/unit/spec/multistream/remoteMedia.ts +255 -0
- package/test/unit/spec/multistream/remoteMediaGroup.ts +396 -0
- package/test/unit/spec/multistream/remoteMediaManager.ts +1793 -0
- package/test/unit/spec/networkQualityMonitor/index.js +24 -18
- package/test/unit/spec/personal-meeting-room/personal-meeting-room.js +2 -7
- package/test/unit/spec/reachability/index.ts +176 -27
- package/test/unit/spec/reachability/request.js +66 -0
- package/test/unit/spec/reconnection-manager/index.js +106 -9
- package/test/unit/spec/recording-controller/index.js +231 -0
- package/test/unit/spec/recording-controller/util.js +102 -0
- package/test/unit/spec/roap/index.ts +78 -45
- package/test/unit/spec/roap/request.ts +217 -0
- package/test/unit/spec/roap/turnDiscovery.ts +93 -49
- package/test/unit/spec/stats-analyzer/index.js +118 -65
- package/test/utils/cmr.js +44 -42
- package/test/utils/constants.js +9 -0
- package/test/utils/integrationTestUtils.js +64 -0
- package/test/utils/testUtils.js +63 -99
- package/test/utils/webex-config.js +22 -18
- package/test/utils/webex-test-users.js +57 -50
- package/tsconfig.json +6 -0
- package/dist/meeting/effectsState.js +0 -327
- package/dist/meeting/effectsState.js.map +0 -1
- package/dist/peer-connection-manager/index.js +0 -794
- package/dist/peer-connection-manager/index.js.map +0 -1
- package/dist/peer-connection-manager/util.js +0 -124
- package/dist/peer-connection-manager/util.js.map +0 -1
- package/dist/roap/collection.js +0 -73
- package/dist/roap/collection.js.map +0 -1
- package/dist/roap/handler.js +0 -337
- package/dist/roap/handler.js.map +0 -1
- package/dist/roap/state.js +0 -164
- package/dist/roap/state.js.map +0 -1
- package/dist/roap/util.js +0 -102
- package/dist/roap/util.js.map +0 -1
- package/src/common/logs/logger-proxy.js +0 -33
- package/src/index.js +0 -15
- package/src/locus-info/controlsUtils.js +0 -102
- package/src/media/index.js +0 -593
- package/src/media/util.js +0 -38
- package/src/mediaQualityMetrics/config.js +0 -382
- package/src/meeting/effectsState.js +0 -205
- package/src/meeting/muteState.js +0 -318
- package/src/meeting-info/meeting-info-v2.js +0 -255
- package/src/meetings/index.js +0 -986
- package/src/meetings/util.js +0 -176
- package/src/members/request.js +0 -131
- package/src/peer-connection-manager/index.js +0 -723
- package/src/peer-connection-manager/util.ts +0 -117
- package/src/roap/collection.js +0 -63
- package/src/roap/handler.js +0 -252
- package/src/roap/index.js +0 -380
- package/src/roap/request.js +0 -198
- package/src/roap/state.js +0 -149
- package/src/roap/util.js +0 -93
- package/src/statsAnalyzer/global.js +0 -131
- package/src/statsAnalyzer/index.js +0 -1020
- package/src/statsAnalyzer/mqaUtil.js +0 -173
- package/test/unit/spec/meeting/effectsState.js +0 -293
- package/test/unit/spec/peerconnection-manager/index.js +0 -188
- package/test/unit/spec/peerconnection-manager/utils.js +0 -48
- package/test/unit/spec/peerconnection-manager/utils.test-fixtures.ts +0 -389
- package/test/unit/spec/roap/util.js +0 -30
- /package/src/common/errors/{reconnection-in-progress.js → reconnection-in-progress.ts} +0 -0
|
@@ -1,61 +1,34 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
var _Reflect$construct = require("@babel/runtime-corejs2/core-js/reflect/construct");
|
|
4
|
-
|
|
5
4
|
var _Object$defineProperty = require("@babel/runtime-corejs2/core-js/object/define-property");
|
|
6
|
-
|
|
7
5
|
var _interopRequireDefault = require("@babel/runtime-corejs2/helpers/interopRequireDefault");
|
|
8
|
-
|
|
9
6
|
_Object$defineProperty(exports, "__esModule", {
|
|
10
7
|
value: true
|
|
11
8
|
});
|
|
12
|
-
|
|
13
9
|
exports.default = void 0;
|
|
14
|
-
|
|
15
10
|
var _regenerator = _interopRequireDefault(require("@babel/runtime-corejs2/regenerator"));
|
|
16
|
-
|
|
17
11
|
var _promise = _interopRequireDefault(require("@babel/runtime-corejs2/core-js/promise"));
|
|
18
|
-
|
|
12
|
+
var _values = _interopRequireDefault(require("@babel/runtime-corejs2/core-js/object/values"));
|
|
19
13
|
var _asyncToGenerator2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/asyncToGenerator"));
|
|
20
|
-
|
|
14
|
+
var _assertThisInitialized2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/assertThisInitialized"));
|
|
15
|
+
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/defineProperty"));
|
|
21
16
|
var _createClass2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/createClass"));
|
|
22
|
-
|
|
23
17
|
var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/classCallCheck"));
|
|
24
|
-
|
|
25
18
|
var _inherits2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/inherits"));
|
|
26
|
-
|
|
27
19
|
var _possibleConstructorReturn2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/possibleConstructorReturn"));
|
|
28
|
-
|
|
29
20
|
var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/getPrototypeOf"));
|
|
30
|
-
|
|
31
21
|
var _wrapNativeSuper2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/wrapNativeSuper"));
|
|
32
|
-
|
|
33
22
|
var _loggerProxy = _interopRequireDefault(require("../common/logs/logger-proxy"));
|
|
34
|
-
|
|
35
23
|
var _triggerProxy = _interopRequireDefault(require("../common/events/trigger-proxy"));
|
|
36
|
-
|
|
37
24
|
var _constants = require("../constants");
|
|
38
|
-
|
|
39
25
|
var _constants2 = _interopRequireDefault(require("../metrics/constants"));
|
|
40
|
-
|
|
41
26
|
var _reconnection = _interopRequireDefault(require("../common/errors/reconnection"));
|
|
42
|
-
|
|
43
27
|
var _reconnectionInProgress = _interopRequireDefault(require("../common/errors/reconnection-in-progress"));
|
|
44
|
-
|
|
45
|
-
var _peerConnectionManager = _interopRequireDefault(require("../peer-connection-manager"));
|
|
46
|
-
|
|
47
28
|
var _config = require("../metrics/config");
|
|
48
|
-
|
|
49
|
-
var _media = _interopRequireDefault(require("../media"));
|
|
50
|
-
|
|
51
29
|
var _metrics = _interopRequireDefault(require("../metrics"));
|
|
52
|
-
|
|
53
|
-
var _collection = _interopRequireDefault(require("../roap/collection"));
|
|
54
|
-
|
|
55
30
|
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); }; }
|
|
56
|
-
|
|
57
31
|
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; } }
|
|
58
|
-
|
|
59
32
|
/**
|
|
60
33
|
* Used to indicate that the reconnect logic needs to be retried.
|
|
61
34
|
*
|
|
@@ -64,14 +37,11 @@ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !_R
|
|
|
64
37
|
*/
|
|
65
38
|
var NeedsRetryError = /*#__PURE__*/function (_Error) {
|
|
66
39
|
(0, _inherits2.default)(NeedsRetryError, _Error);
|
|
67
|
-
|
|
68
40
|
var _super = _createSuper(NeedsRetryError);
|
|
69
|
-
|
|
70
41
|
function NeedsRetryError() {
|
|
71
42
|
(0, _classCallCheck2.default)(this, NeedsRetryError);
|
|
72
43
|
return _super.apply(this, arguments);
|
|
73
44
|
}
|
|
74
|
-
|
|
75
45
|
return (0, _createClass2.default)(NeedsRetryError);
|
|
76
46
|
}( /*#__PURE__*/(0, _wrapNativeSuper2.default)(Error));
|
|
77
47
|
/**
|
|
@@ -80,13 +50,9 @@ var NeedsRetryError = /*#__PURE__*/function (_Error) {
|
|
|
80
50
|
* @class NeedsRejoinError
|
|
81
51
|
* @extends {Error}
|
|
82
52
|
*/
|
|
83
|
-
|
|
84
|
-
|
|
85
53
|
var NeedsRejoinError = /*#__PURE__*/function (_Error2) {
|
|
86
54
|
(0, _inherits2.default)(NeedsRejoinError, _Error2);
|
|
87
|
-
|
|
88
55
|
var _super2 = _createSuper(NeedsRejoinError);
|
|
89
|
-
|
|
90
56
|
/**
|
|
91
57
|
* Creates an instance of NeedsRejoinError.
|
|
92
58
|
* @param {Object} params
|
|
@@ -96,31 +62,37 @@ var NeedsRejoinError = /*#__PURE__*/function (_Error2) {
|
|
|
96
62
|
*/
|
|
97
63
|
function NeedsRejoinError(_ref) {
|
|
98
64
|
var _this;
|
|
99
|
-
|
|
100
65
|
var wasSharing = _ref.wasSharing,
|
|
101
|
-
|
|
102
|
-
|
|
66
|
+
_ref$error = _ref.error,
|
|
67
|
+
error = _ref$error === void 0 ? new Error('Meeting needs to be rejoined') : _ref$error;
|
|
103
68
|
(0, _classCallCheck2.default)(this, NeedsRejoinError);
|
|
69
|
+
// @ts-ignore
|
|
104
70
|
_this = _super2.call(this, error);
|
|
71
|
+
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "wasSharing", void 0);
|
|
105
72
|
_this.wasSharing = wasSharing;
|
|
106
73
|
return _this;
|
|
107
74
|
}
|
|
108
|
-
|
|
109
75
|
return (0, _createClass2.default)(NeedsRejoinError);
|
|
110
76
|
}( /*#__PURE__*/(0, _wrapNativeSuper2.default)(Error));
|
|
111
77
|
/**
|
|
112
78
|
* @export
|
|
113
79
|
* @class ReconnectionManager
|
|
114
|
-
*/
|
|
115
|
-
|
|
116
|
-
|
|
80
|
+
*/
|
|
117
81
|
var ReconnectionManager = /*#__PURE__*/function () {
|
|
118
82
|
/**
|
|
119
83
|
* @param {Meeting} meeting
|
|
120
84
|
*/
|
|
121
85
|
function ReconnectionManager(meeting) {
|
|
122
86
|
(0, _classCallCheck2.default)(this, ReconnectionManager);
|
|
123
|
-
|
|
87
|
+
(0, _defineProperty2.default)(this, "autoRejoinEnabled", void 0);
|
|
88
|
+
(0, _defineProperty2.default)(this, "iceState", void 0);
|
|
89
|
+
(0, _defineProperty2.default)(this, "maxRejoinAttempts", void 0);
|
|
90
|
+
(0, _defineProperty2.default)(this, "meeting", void 0);
|
|
91
|
+
(0, _defineProperty2.default)(this, "rejoinAttempts", void 0);
|
|
92
|
+
(0, _defineProperty2.default)(this, "shareStatus", void 0);
|
|
93
|
+
(0, _defineProperty2.default)(this, "status", void 0);
|
|
94
|
+
(0, _defineProperty2.default)(this, "tryCount", void 0);
|
|
95
|
+
(0, _defineProperty2.default)(this, "webex", void 0);
|
|
124
96
|
/**
|
|
125
97
|
* Stores ICE reconnection state data.
|
|
126
98
|
*
|
|
@@ -133,33 +105,33 @@ var ReconnectionManager = /*#__PURE__*/function () {
|
|
|
133
105
|
disconnected: false,
|
|
134
106
|
resolve: function resolve() {},
|
|
135
107
|
timer: undefined,
|
|
108
|
+
// @ts-ignore
|
|
136
109
|
timeoutDuration: meeting.config.reconnection.iceReconnectionTimeout
|
|
137
110
|
};
|
|
111
|
+
|
|
138
112
|
/**
|
|
139
113
|
* @instance
|
|
140
114
|
* @type {String}
|
|
141
115
|
* @private
|
|
142
116
|
* @memberof ReconnectionManager
|
|
143
|
-
|
|
144
|
-
|
|
117
|
+
*/
|
|
145
118
|
this.status = _constants.RECONNECTION.STATE.DEFAULT_STATUS;
|
|
146
119
|
/**
|
|
147
120
|
* @instance
|
|
148
121
|
* @type {Number}
|
|
149
122
|
* @private
|
|
150
123
|
* @memberof ReconnectionManager
|
|
151
|
-
|
|
152
|
-
|
|
124
|
+
*/
|
|
153
125
|
this.tryCount = _constants.RECONNECTION.STATE.DEFAULT_TRY_COUNT;
|
|
154
126
|
/**
|
|
155
127
|
* @instance
|
|
156
128
|
* @type {Object}
|
|
157
129
|
* @private
|
|
158
130
|
* @memberof ReconnectionManager
|
|
159
|
-
|
|
131
|
+
*/
|
|
160
132
|
// TODO : change this logic to not save the meeting instance
|
|
161
133
|
// It gets complicated when meeting ends on remote side , We have a old meeting instance which is not up to date
|
|
162
|
-
|
|
134
|
+
// @ts-ignore
|
|
163
135
|
this.webex = meeting.webex;
|
|
164
136
|
/**
|
|
165
137
|
* @instance
|
|
@@ -169,42 +141,52 @@ var ReconnectionManager = /*#__PURE__*/function () {
|
|
|
169
141
|
*/
|
|
170
142
|
// TODO: try removing the circular dependency for meeting and reconnection manager
|
|
171
143
|
// try moving this to meetings collection
|
|
172
|
-
|
|
173
144
|
this.meeting = meeting;
|
|
145
|
+
|
|
146
|
+
// @ts-ignore
|
|
174
147
|
this.maxRejoinAttempts = meeting.config.reconnection.maxRejoinAttempts;
|
|
175
148
|
this.rejoinAttempts = _constants.RECONNECTION.STATE.DEFAULT_TRY_COUNT;
|
|
176
|
-
|
|
149
|
+
// @ts-ignore
|
|
150
|
+
this.autoRejoinEnabled = meeting.config.reconnection.autoRejoin;
|
|
177
151
|
|
|
152
|
+
// Make sure reconnection state is in default
|
|
178
153
|
this.reset();
|
|
179
154
|
}
|
|
155
|
+
|
|
180
156
|
/**
|
|
181
|
-
* Sets the iceState to connected and clears any disconnect timeouts and
|
|
182
|
-
* related timeout data within the iceState.
|
|
183
|
-
*
|
|
184
|
-
* @returns {undefined}
|
|
185
157
|
* @public
|
|
186
158
|
* @memberof ReconnectionManager
|
|
159
|
+
* @returns {void}
|
|
187
160
|
*/
|
|
188
|
-
|
|
189
|
-
|
|
190
161
|
(0, _createClass2.default)(ReconnectionManager, [{
|
|
162
|
+
key: "resetReconnectionTimer",
|
|
163
|
+
value: function resetReconnectionTimer() {
|
|
164
|
+
this.iceState.resolve();
|
|
165
|
+
this.iceState.resolve = function () {};
|
|
166
|
+
if (this.iceState.timer) {
|
|
167
|
+
clearTimeout(this.iceState.timer);
|
|
168
|
+
delete this.iceState.timer;
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
/**
|
|
173
|
+
* Sets the iceState to connected and clears any disconnect timeouts and
|
|
174
|
+
* related timeout data within the iceState.
|
|
175
|
+
*
|
|
176
|
+
* @returns {undefined}
|
|
177
|
+
* @public
|
|
178
|
+
* @memberof ReconnectionManager
|
|
179
|
+
*/
|
|
180
|
+
}, {
|
|
191
181
|
key: "iceReconnected",
|
|
192
182
|
value: function iceReconnected() {
|
|
193
183
|
if (this.iceState.disconnected) {
|
|
194
184
|
_loggerProxy.default.logger.log('ReconnectionManager:index#iceReconnected --> ice has reconnected');
|
|
195
|
-
|
|
196
|
-
this.iceState.resolve();
|
|
197
|
-
|
|
198
|
-
this.iceState.resolve = function () {};
|
|
199
|
-
|
|
200
|
-
if (this.iceState.timer) {
|
|
201
|
-
clearTimeout(this.iceState.timer);
|
|
202
|
-
delete this.iceState.timer;
|
|
203
|
-
}
|
|
204
|
-
|
|
185
|
+
this.resetReconnectionTimer();
|
|
205
186
|
this.iceState.disconnected = false;
|
|
206
187
|
}
|
|
207
188
|
}
|
|
189
|
+
|
|
208
190
|
/**
|
|
209
191
|
* Set the iceState to disconnected and generates a timeout that waits for the
|
|
210
192
|
* iceState to reconnect and then resolves. If the ice state is already
|
|
@@ -215,15 +197,12 @@ var ReconnectionManager = /*#__PURE__*/function () {
|
|
|
215
197
|
* @public
|
|
216
198
|
* @memberof ReconnectionManager
|
|
217
199
|
*/
|
|
218
|
-
|
|
219
200
|
}, {
|
|
220
201
|
key: "waitForIceReconnect",
|
|
221
202
|
value: function waitForIceReconnect() {
|
|
222
203
|
var _this2 = this;
|
|
223
|
-
|
|
224
204
|
if (!this.iceState.disconnected) {
|
|
225
205
|
_loggerProxy.default.logger.log('ReconnectionManager:index#waitForIceReconnect --> waiting for ice reconnect');
|
|
226
|
-
|
|
227
206
|
this.iceState.disconnected = true;
|
|
228
207
|
return new _promise.default(function (resolve, reject) {
|
|
229
208
|
_this2.iceState.timer = setTimeout(function () {
|
|
@@ -236,17 +215,17 @@ var ReconnectionManager = /*#__PURE__*/function () {
|
|
|
236
215
|
}, _this2.iceState.timeoutDuration);
|
|
237
216
|
_this2.iceState.resolve = resolve;
|
|
238
217
|
});
|
|
239
|
-
}
|
|
240
|
-
|
|
218
|
+
}
|
|
241
219
|
|
|
220
|
+
// return a resolved promise to prevent multiple catch executions of reconnect
|
|
242
221
|
return _promise.default.resolve();
|
|
243
222
|
}
|
|
223
|
+
|
|
244
224
|
/**
|
|
245
225
|
* @returns {undefined}
|
|
246
226
|
* @public
|
|
247
227
|
* @memberof ReconnectionManager
|
|
248
228
|
*/
|
|
249
|
-
|
|
250
229
|
}, {
|
|
251
230
|
key: "reset",
|
|
252
231
|
value: function reset() {
|
|
@@ -254,25 +233,61 @@ var ReconnectionManager = /*#__PURE__*/function () {
|
|
|
254
233
|
this.tryCount = _constants.RECONNECTION.STATE.DEFAULT_TRY_COUNT;
|
|
255
234
|
this.rejoinAttempts = _constants.RECONNECTION.STATE.DEFAULT_TRY_COUNT;
|
|
256
235
|
}
|
|
236
|
+
|
|
257
237
|
/**
|
|
258
238
|
* @returns {undefined}
|
|
259
239
|
* @public
|
|
260
240
|
* @memberof ReconnectionManager
|
|
261
241
|
*/
|
|
262
|
-
|
|
263
242
|
}, {
|
|
264
243
|
key: "cleanUp",
|
|
265
244
|
value: function cleanUp() {
|
|
266
245
|
this.reset();
|
|
267
246
|
this.meeting = null;
|
|
268
247
|
}
|
|
248
|
+
|
|
249
|
+
/**
|
|
250
|
+
* Stop the local share track.
|
|
251
|
+
*
|
|
252
|
+
* @param {string} reason a {@link SHARE_STOPPED_REASON}
|
|
253
|
+
* @returns {undefined}
|
|
254
|
+
* @private
|
|
255
|
+
* @memberof ReconnectionManager
|
|
256
|
+
*/
|
|
257
|
+
}, {
|
|
258
|
+
key: "stopLocalShareTrack",
|
|
259
|
+
value: function stopLocalShareTrack(reason) {
|
|
260
|
+
this.meeting.setLocalShareTrack(null);
|
|
261
|
+
this.meeting.isSharing = false;
|
|
262
|
+
if (this.shareStatus === _constants.SHARE_STATUS.LOCAL_SHARE_ACTIVE) {
|
|
263
|
+
this.meeting.shareStatus = _constants.SHARE_STATUS.NO_SHARE;
|
|
264
|
+
}
|
|
265
|
+
this.meeting.mediaProperties.mediaDirection.sendShare = false;
|
|
266
|
+
_triggerProxy.default.trigger(this.meeting, {
|
|
267
|
+
file: 'reconnection-manager/index',
|
|
268
|
+
function: 'stopLocalShareTrack'
|
|
269
|
+
}, _constants.EVENT_TRIGGERS.MEETING_STOPPED_SHARING_LOCAL, {
|
|
270
|
+
reason: reason
|
|
271
|
+
});
|
|
272
|
+
}
|
|
273
|
+
|
|
274
|
+
/**
|
|
275
|
+
* @public
|
|
276
|
+
* @memberof ReconnectionManager
|
|
277
|
+
* @returns {Boolean} true if reconnection operation is in progress
|
|
278
|
+
*/
|
|
279
|
+
}, {
|
|
280
|
+
key: "isReconnectInProgress",
|
|
281
|
+
value: function isReconnectInProgress() {
|
|
282
|
+
return this.status === _constants.RECONNECTION.STATE.IN_PROGRESS;
|
|
283
|
+
}
|
|
284
|
+
|
|
269
285
|
/**
|
|
270
286
|
* @returns {Boolean}
|
|
271
287
|
* @throws {ReconnectionError}
|
|
272
288
|
* @private
|
|
273
289
|
* @memberof ReconnectionManager
|
|
274
290
|
*/
|
|
275
|
-
|
|
276
291
|
}, {
|
|
277
292
|
key: "validate",
|
|
278
293
|
value: function validate() {
|
|
@@ -280,16 +295,13 @@ var ReconnectionManager = /*#__PURE__*/function () {
|
|
|
280
295
|
if (this.status === _constants.RECONNECTION.STATE.DEFAULT_STATUS || this.status === _constants.RECONNECTION.STATE.COMPLETE) {
|
|
281
296
|
return true;
|
|
282
297
|
}
|
|
283
|
-
|
|
284
298
|
_loggerProxy.default.logger.info('ReconnectionManager:index#validate --> Reconnection already in progress.');
|
|
285
|
-
|
|
286
299
|
throw new _reconnectionInProgress.default('Reconnection already in progress.');
|
|
287
300
|
}
|
|
288
|
-
|
|
289
301
|
_loggerProxy.default.logger.info('ReconnectionManager:index#validate --> Reconnection is not enabled.');
|
|
290
|
-
|
|
291
302
|
throw new _reconnection.default('Reconnection is not enabled.');
|
|
292
303
|
}
|
|
304
|
+
|
|
293
305
|
/**
|
|
294
306
|
* Initiates a media reconnect for the active meeting
|
|
295
307
|
* @param {Object} reconnectOptions
|
|
@@ -299,123 +311,101 @@ var ReconnectionManager = /*#__PURE__*/function () {
|
|
|
299
311
|
* @public
|
|
300
312
|
* @memberof ReconnectionManager
|
|
301
313
|
*/
|
|
302
|
-
|
|
303
314
|
}, {
|
|
304
315
|
key: "reconnect",
|
|
305
316
|
value: function () {
|
|
306
317
|
var _reconnect = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee() {
|
|
307
318
|
var _this3 = this;
|
|
308
|
-
|
|
309
319
|
var _ref2,
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
320
|
+
_ref2$networkDisconne,
|
|
321
|
+
networkDisconnect,
|
|
322
|
+
_ref2$networkRetry,
|
|
323
|
+
networkRetry,
|
|
324
|
+
_args = arguments;
|
|
316
325
|
return _regenerator.default.wrap(function _callee$(_context) {
|
|
317
|
-
while (1) {
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
_loggerProxy.default.logger.info('ReconnectionManager:index#reconnect -->
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
326
|
+
while (1) switch (_context.prev = _context.next) {
|
|
327
|
+
case 0:
|
|
328
|
+
_ref2 = _args.length > 0 && _args[0] !== undefined ? _args[0] : {}, _ref2$networkDisconne = _ref2.networkDisconnect, networkDisconnect = _ref2$networkDisconne === void 0 ? false : _ref2$networkDisconne, _ref2$networkRetry = _ref2.networkRetry, networkRetry = _ref2$networkRetry === void 0 ? false : _ref2$networkRetry;
|
|
329
|
+
_loggerProxy.default.logger.info("ReconnectionManager:index#reconnect --> Reconnection start for meeting ".concat(this.meeting.id, "."));
|
|
330
|
+
// First, validate that we can reconnect, if not, it will throw an error
|
|
331
|
+
_context.prev = 2;
|
|
332
|
+
this.validate();
|
|
333
|
+
_context.next = 10;
|
|
334
|
+
break;
|
|
335
|
+
case 6:
|
|
336
|
+
_context.prev = 6;
|
|
337
|
+
_context.t0 = _context["catch"](2);
|
|
338
|
+
_loggerProxy.default.logger.info('ReconnectionManager:index#reconnect --> Reconnection unable to begin.', _context.t0);
|
|
339
|
+
throw _context.t0;
|
|
340
|
+
case 10:
|
|
341
|
+
if (!networkRetry) {
|
|
342
|
+
// Only log START metrics on the initial reconnect
|
|
343
|
+
_loggerProxy.default.logger.info('ReconnectionManager:index#reconnect --> Sending reconnect start metric.');
|
|
344
|
+
_metrics.default.postEvent({
|
|
345
|
+
event: _config.eventType.MEDIA_RECONNECTING,
|
|
346
|
+
meeting: this.meeting
|
|
347
|
+
});
|
|
348
|
+
}
|
|
349
|
+
return _context.abrupt("return", this.executeReconnection({
|
|
350
|
+
networkDisconnect: networkDisconnect
|
|
351
|
+
}).then(function () {
|
|
352
|
+
_loggerProxy.default.logger.info('ReconnectionManager:index#reconnect --> Reconnection successful.');
|
|
353
|
+
_loggerProxy.default.logger.info('ReconnectionManager:index#reconnect --> Sending reconnect success metric.');
|
|
354
|
+
_metrics.default.postEvent({
|
|
355
|
+
event: _config.eventType.MEDIA_RECOVERED,
|
|
356
|
+
meeting: _this3.meeting,
|
|
357
|
+
data: {
|
|
358
|
+
recoveredBy: _config.reconnection.RECOVERED_BY_NEW
|
|
359
|
+
}
|
|
360
|
+
});
|
|
361
|
+
}).catch(function (reconnectError) {
|
|
362
|
+
if (reconnectError instanceof NeedsRetryError) {
|
|
363
|
+
_loggerProxy.default.logger.info('ReconnectionManager:index#reconnect --> Reconnection not successful, retrying.');
|
|
364
|
+
// Reset our reconnect status since we are looping back to the beginning
|
|
365
|
+
_this3.status = _constants.RECONNECTION.STATE.DEFAULT_STATUS;
|
|
366
|
+
|
|
367
|
+
// This is a network retry, so we should not log START metrics again
|
|
368
|
+
return _this3.reconnect({
|
|
369
|
+
networkDisconnect: true,
|
|
370
|
+
networkRetry: true
|
|
346
371
|
});
|
|
347
372
|
}
|
|
348
373
|
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
}).catch(function (reconnectError) {
|
|
364
|
-
if (reconnectError instanceof NeedsRetryError) {
|
|
365
|
-
_loggerProxy.default.logger.info('ReconnectionManager:index#reconnect --> Reconnection not successful, retrying.'); // Reset our reconnect status since we are looping back to the beginning
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
_this3.status = _constants.RECONNECTION.STATE.DEFAULT_STATUS; // This is a network retry, so we should not log START metrics again
|
|
369
|
-
|
|
370
|
-
return _this3.reconnect({
|
|
371
|
-
networkDisconnect: true,
|
|
372
|
-
networkRetry: true
|
|
373
|
-
});
|
|
374
|
-
} // Reconnect has failed
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
_loggerProxy.default.logger.error('ReconnectionManager:index#reconnect --> Reconnection failed.', reconnectError.message);
|
|
378
|
-
|
|
379
|
-
_loggerProxy.default.logger.info('ReconnectionManager:index#reconnect --> Sending reconnect abort metric.');
|
|
380
|
-
|
|
381
|
-
var reconnectMetric = {
|
|
382
|
-
event: _config.eventType.CALL_ABORTED,
|
|
383
|
-
meeting: _this3.meeting,
|
|
384
|
-
data: {
|
|
385
|
-
errors: [{
|
|
386
|
-
category: _config.errorObjects.category.expected,
|
|
387
|
-
errorCode: 2008,
|
|
388
|
-
fatal: true,
|
|
389
|
-
name: _config.errorObjects.name.mediaEngine,
|
|
390
|
-
shownToUser: false
|
|
391
|
-
}]
|
|
392
|
-
}
|
|
393
|
-
};
|
|
394
|
-
|
|
395
|
-
_metrics.default.postEvent(reconnectMetric);
|
|
396
|
-
|
|
397
|
-
if (reconnectError instanceof NeedsRejoinError) {
|
|
398
|
-
// send call aborded event with catogery as expected as we are trying to rejoin
|
|
399
|
-
if (_this3.autoRejoinEnabled) {
|
|
400
|
-
return _this3.rejoinMeeting(reconnectError.wasSharing);
|
|
401
|
-
}
|
|
374
|
+
// Reconnect has failed
|
|
375
|
+
_loggerProxy.default.logger.error('ReconnectionManager:index#reconnect --> Reconnection failed.', reconnectError.message);
|
|
376
|
+
_loggerProxy.default.logger.info('ReconnectionManager:index#reconnect --> Sending reconnect abort metric.');
|
|
377
|
+
var reconnectMetric = {
|
|
378
|
+
event: _config.eventType.CALL_ABORTED,
|
|
379
|
+
meeting: _this3.meeting,
|
|
380
|
+
data: {
|
|
381
|
+
errors: [{
|
|
382
|
+
category: _config.errorObjects.category.expected,
|
|
383
|
+
errorCode: 2008,
|
|
384
|
+
fatal: true,
|
|
385
|
+
name: _config.errorObjects.name.mediaEngine,
|
|
386
|
+
shownToUser: false
|
|
387
|
+
}]
|
|
402
388
|
}
|
|
389
|
+
};
|
|
390
|
+
_metrics.default.postEvent(reconnectMetric);
|
|
391
|
+
if (reconnectError instanceof NeedsRejoinError) {
|
|
392
|
+
// send call aborded event with catogery as expected as we are trying to rejoin
|
|
403
393
|
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
394
|
+
if (_this3.autoRejoinEnabled) {
|
|
395
|
+
return _this3.rejoinMeeting(reconnectError.wasSharing);
|
|
396
|
+
}
|
|
397
|
+
}
|
|
398
|
+
throw reconnectError;
|
|
399
|
+
}));
|
|
400
|
+
case 12:
|
|
401
|
+
case "end":
|
|
402
|
+
return _context.stop();
|
|
411
403
|
}
|
|
412
404
|
}, _callee, this, [[2, 6]]);
|
|
413
405
|
}));
|
|
414
|
-
|
|
415
406
|
function reconnect() {
|
|
416
407
|
return _reconnect.apply(this, arguments);
|
|
417
408
|
}
|
|
418
|
-
|
|
419
409
|
return reconnect;
|
|
420
410
|
}()
|
|
421
411
|
/**
|
|
@@ -426,132 +416,99 @@ var ReconnectionManager = /*#__PURE__*/function () {
|
|
|
426
416
|
* @private
|
|
427
417
|
* @memberof ReconnectionManager
|
|
428
418
|
*/
|
|
429
|
-
|
|
430
419
|
}, {
|
|
431
420
|
key: "executeReconnection",
|
|
432
421
|
value: function () {
|
|
433
422
|
var _executeReconnection = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee2(_ref3) {
|
|
434
423
|
var _ref3$networkDisconne, networkDisconnect, wasSharing, media;
|
|
435
|
-
|
|
436
424
|
return _regenerator.default.wrap(function _callee2$(_context2) {
|
|
437
|
-
while (1) {
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
}
|
|
449
|
-
|
|
450
|
-
_context2.prev = 4;
|
|
451
|
-
_context2.next = 7;
|
|
452
|
-
return this.reconnectMercuryWebSocket();
|
|
453
|
-
|
|
454
|
-
case 7:
|
|
455
|
-
_loggerProxy.default.logger.error('ReconnectionManager:index#executeReconnection --> Websocket reconnected.', this.webex.internal.device.url);
|
|
456
|
-
|
|
457
|
-
_context2.next = 15;
|
|
425
|
+
while (1) switch (_context2.prev = _context2.next) {
|
|
426
|
+
case 0:
|
|
427
|
+
_ref3$networkDisconne = _ref3.networkDisconnect, networkDisconnect = _ref3$networkDisconne === void 0 ? false : _ref3$networkDisconne;
|
|
428
|
+
this.status = _constants.RECONNECTION.STATE.IN_PROGRESS;
|
|
429
|
+
_loggerProxy.default.logger.info('ReconnectionManager:index#executeReconnection --> Attempting to reconnect to meeting.');
|
|
430
|
+
wasSharing = this.meeting.shareStatus === _constants.SHARE_STATUS.LOCAL_SHARE_ACTIVE;
|
|
431
|
+
if (wasSharing) {
|
|
432
|
+
this.stopLocalShareTrack(_constants.SHARE_STOPPED_REASON.MEDIA_RECONNECTION);
|
|
433
|
+
}
|
|
434
|
+
if (!networkDisconnect) {
|
|
435
|
+
_context2.next = 17;
|
|
458
436
|
break;
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
437
|
+
}
|
|
438
|
+
_context2.prev = 6;
|
|
439
|
+
_context2.next = 9;
|
|
440
|
+
return this.reconnectMercuryWebSocket();
|
|
441
|
+
case 9:
|
|
442
|
+
_loggerProxy.default.logger.error('ReconnectionManager:index#executeReconnection --> Websocket reconnected.', this.webex.internal.device.url);
|
|
443
|
+
_context2.next = 17;
|
|
444
|
+
break;
|
|
445
|
+
case 12:
|
|
446
|
+
_context2.prev = 12;
|
|
447
|
+
_context2.t0 = _context2["catch"](6);
|
|
448
|
+
_loggerProxy.default.logger.error('ReconnectionManager:index#executeReconnection --> Unable to reconnect to websocket, giving up.');
|
|
449
|
+
this.status = _constants.RECONNECTION.STATE.FAILURE;
|
|
450
|
+
throw _context2.t0;
|
|
451
|
+
case 17:
|
|
452
|
+
_context2.prev = 17;
|
|
453
|
+
_loggerProxy.default.logger.info('ReconnectionManager:index#executeReconnection --> Updating meeting data from server.');
|
|
454
|
+
_context2.next = 21;
|
|
455
|
+
return this.webex.meetings.syncMeetings();
|
|
456
|
+
case 21:
|
|
457
|
+
_context2.next = 27;
|
|
458
|
+
break;
|
|
459
|
+
case 23:
|
|
460
|
+
_context2.prev = 23;
|
|
461
|
+
_context2.t1 = _context2["catch"](17);
|
|
462
|
+
_loggerProxy.default.logger.info('ReconnectionManager:index#executeReconnection --> Unable to sync meetings, reconnecting.', _context2.t1);
|
|
463
|
+
throw new NeedsRetryError(_context2.t1);
|
|
464
|
+
case 27:
|
|
465
|
+
if (!(!this.meeting || !this.webex.meetings.getMeetingByType(_constants._ID_, this.meeting.id))) {
|
|
466
|
+
_context2.next = 30;
|
|
480
467
|
break;
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
});
|
|
520
|
-
|
|
521
|
-
case 34:
|
|
522
|
-
_context2.prev = 34;
|
|
523
|
-
_context2.next = 37;
|
|
524
|
-
return this.reconnectMedia();
|
|
525
|
-
|
|
526
|
-
case 37:
|
|
527
|
-
media = _context2.sent;
|
|
528
|
-
|
|
529
|
-
_loggerProxy.default.logger.log('ReconnectionManager:index#executeReconnection --> Media reestablished');
|
|
530
|
-
|
|
531
|
-
this.status = _constants.RECONNECTION.STATE.COMPLETE;
|
|
532
|
-
return _context2.abrupt("return", media);
|
|
533
|
-
|
|
534
|
-
case 43:
|
|
535
|
-
_context2.prev = 43;
|
|
536
|
-
_context2.t2 = _context2["catch"](34);
|
|
537
|
-
|
|
538
|
-
_loggerProxy.default.logger.error('ReconnectionManager:index#executeReconnection --> Media reestablishment failed');
|
|
539
|
-
|
|
540
|
-
this.status = _constants.RECONNECTION.STATE.FAILURE;
|
|
541
|
-
throw _context2.t2;
|
|
542
|
-
|
|
543
|
-
case 48:
|
|
544
|
-
case "end":
|
|
545
|
-
return _context2.stop();
|
|
546
|
-
}
|
|
468
|
+
}
|
|
469
|
+
_loggerProxy.default.logger.info('ReconnectionManager:index#executeReconnection --> Meeting got deleted due to inactivity or ended remotely.');
|
|
470
|
+
throw new Error('Unable to rejoin a meeting already ended or inactive.');
|
|
471
|
+
case 30:
|
|
472
|
+
_loggerProxy.default.logger.info("ReconnectionManager:index#executeReconnection --> Current state of meeting is ".concat(this.meeting.state));
|
|
473
|
+
|
|
474
|
+
// If the meeting state was left, no longer reconnect media
|
|
475
|
+
if (!(this.meeting.state === _constants._LEFT_)) {
|
|
476
|
+
_context2.next = 35;
|
|
477
|
+
break;
|
|
478
|
+
}
|
|
479
|
+
if (!(this.meeting.type === _constants._CALL_)) {
|
|
480
|
+
_context2.next = 34;
|
|
481
|
+
break;
|
|
482
|
+
}
|
|
483
|
+
throw new Error('Unable to rejoin a call in LEFT state.');
|
|
484
|
+
case 34:
|
|
485
|
+
throw new NeedsRejoinError({
|
|
486
|
+
wasSharing: wasSharing
|
|
487
|
+
});
|
|
488
|
+
case 35:
|
|
489
|
+
_context2.prev = 35;
|
|
490
|
+
_context2.next = 38;
|
|
491
|
+
return this.reconnectMedia();
|
|
492
|
+
case 38:
|
|
493
|
+
media = _context2.sent;
|
|
494
|
+
_loggerProxy.default.logger.log('ReconnectionManager:index#executeReconnection --> Media reestablished');
|
|
495
|
+
this.status = _constants.RECONNECTION.STATE.COMPLETE;
|
|
496
|
+
return _context2.abrupt("return", media);
|
|
497
|
+
case 44:
|
|
498
|
+
_context2.prev = 44;
|
|
499
|
+
_context2.t2 = _context2["catch"](35);
|
|
500
|
+
_loggerProxy.default.logger.error('ReconnectionManager:index#executeReconnection --> Media reestablishment failed');
|
|
501
|
+
this.status = _constants.RECONNECTION.STATE.FAILURE;
|
|
502
|
+
throw _context2.t2;
|
|
503
|
+
case 49:
|
|
504
|
+
case "end":
|
|
505
|
+
return _context2.stop();
|
|
547
506
|
}
|
|
548
|
-
}, _callee2, this, [[
|
|
507
|
+
}, _callee2, this, [[6, 12], [17, 23], [35, 44]]);
|
|
549
508
|
}));
|
|
550
|
-
|
|
551
509
|
function executeReconnection(_x) {
|
|
552
510
|
return _executeReconnection.apply(this, arguments);
|
|
553
511
|
}
|
|
554
|
-
|
|
555
512
|
return executeReconnection;
|
|
556
513
|
}()
|
|
557
514
|
/**
|
|
@@ -561,114 +518,71 @@ var ReconnectionManager = /*#__PURE__*/function () {
|
|
|
561
518
|
* @param {boolean} wasSharing
|
|
562
519
|
* @returns {Promise}
|
|
563
520
|
*/
|
|
564
|
-
|
|
565
521
|
}, {
|
|
566
522
|
key: "rejoinMeeting",
|
|
567
523
|
value: function () {
|
|
568
524
|
var _rejoinMeeting = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee3() {
|
|
569
525
|
var wasSharing,
|
|
570
|
-
|
|
571
|
-
_args3 = arguments;
|
|
526
|
+
_args3 = arguments;
|
|
572
527
|
return _regenerator.default.wrap(function _callee3$(_context3) {
|
|
573
|
-
while (1) {
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
this.meeting.isSharing = false;
|
|
597
|
-
|
|
598
|
-
if (this.shareStatus === _constants.SHARE_STATUS.LOCAL_SHARE_ACTIVE) {
|
|
599
|
-
this.meeting.shareStatus = _constants.SHARE_STATUS.NO_SHARE;
|
|
600
|
-
}
|
|
601
|
-
|
|
602
|
-
this.meeting.mediaProperties.mediaDirection.sendShare = false;
|
|
603
|
-
|
|
604
|
-
_triggerProxy.default.trigger(this.meeting, {
|
|
605
|
-
file: 'reconnection-manager/index',
|
|
606
|
-
function: 'rejoinMeeting'
|
|
607
|
-
}, _constants.EVENT_TRIGGERS.MEETING_STOPPED_SHARING_LOCAL, {
|
|
608
|
-
reason: _constants.SHARE_STOPPED_REASON.MEETING_REJOIN
|
|
609
|
-
});
|
|
610
|
-
}
|
|
611
|
-
|
|
612
|
-
_context3.next = 23;
|
|
528
|
+
while (1) switch (_context3.prev = _context3.next) {
|
|
529
|
+
case 0:
|
|
530
|
+
wasSharing = _args3.length > 0 && _args3[0] !== undefined ? _args3[0] : false;
|
|
531
|
+
_context3.prev = 1;
|
|
532
|
+
_loggerProxy.default.logger.info('ReconnectionManager:index#rejoinMeeting --> attemping meeting rejoin');
|
|
533
|
+
_context3.next = 5;
|
|
534
|
+
return this.meeting.join({
|
|
535
|
+
rejoin: true
|
|
536
|
+
});
|
|
537
|
+
case 5:
|
|
538
|
+
_loggerProxy.default.logger.info('ReconnectionManager:index#rejoinMeeting --> meeting rejoined');
|
|
539
|
+
if (wasSharing) {
|
|
540
|
+
this.stopLocalShareTrack(_constants.SHARE_STOPPED_REASON.MEETING_REJOIN);
|
|
541
|
+
}
|
|
542
|
+
_context3.next = 21;
|
|
543
|
+
break;
|
|
544
|
+
case 9:
|
|
545
|
+
_context3.prev = 9;
|
|
546
|
+
_context3.t0 = _context3["catch"](1);
|
|
547
|
+
this.rejoinAttempts += 1;
|
|
548
|
+
if (!(this.rejoinAttempts <= this.maxRejoinAttempts)) {
|
|
549
|
+
_context3.next = 17;
|
|
613
550
|
break;
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
case 23:
|
|
644
|
-
_context3.prev = 23;
|
|
645
|
-
_context3.next = 26;
|
|
646
|
-
return this.reconnectMedia();
|
|
647
|
-
|
|
648
|
-
case 26:
|
|
649
|
-
_context3.next = 32;
|
|
650
|
-
break;
|
|
651
|
-
|
|
652
|
-
case 28:
|
|
653
|
-
_context3.prev = 28;
|
|
654
|
-
_context3.t1 = _context3["catch"](23);
|
|
655
|
-
|
|
656
|
-
_loggerProxy.default.logger.error('ReconnectionManager:index#rejoinMeeting --> Unable to reestablish media after rejoining.', _context3.t1);
|
|
657
|
-
|
|
658
|
-
throw _context3.t1;
|
|
659
|
-
|
|
660
|
-
case 32:
|
|
661
|
-
case "end":
|
|
662
|
-
return _context3.stop();
|
|
663
|
-
}
|
|
551
|
+
}
|
|
552
|
+
_loggerProxy.default.logger.info("ReconnectionManager:index#rejoinMeeting --> Unable to rejoin meeting, attempt #".concat(this.rejoinAttempts, ", retrying."), _context3.t0);
|
|
553
|
+
this.rejoinMeeting();
|
|
554
|
+
_context3.next = 21;
|
|
555
|
+
break;
|
|
556
|
+
case 17:
|
|
557
|
+
_loggerProxy.default.logger.error('ReconnectionManager:index#rejoinMeeting --> Unable to rejoin meeting after max attempts.', _context3.t0);
|
|
558
|
+
_metrics.default.sendBehavioralMetric(_constants2.default.MEETING_MAX_REJOIN_FAILURE, {
|
|
559
|
+
locus_id: this.meeting.locusUrl.split('/').pop(),
|
|
560
|
+
reason: _context3.t0.message,
|
|
561
|
+
stack: _context3.t0.stack
|
|
562
|
+
});
|
|
563
|
+
this.status = _constants.RECONNECTION.STATE.FAILURE;
|
|
564
|
+
throw _context3.t0;
|
|
565
|
+
case 21:
|
|
566
|
+
_context3.prev = 21;
|
|
567
|
+
_context3.next = 24;
|
|
568
|
+
return this.reconnectMedia();
|
|
569
|
+
case 24:
|
|
570
|
+
_context3.next = 30;
|
|
571
|
+
break;
|
|
572
|
+
case 26:
|
|
573
|
+
_context3.prev = 26;
|
|
574
|
+
_context3.t1 = _context3["catch"](21);
|
|
575
|
+
_loggerProxy.default.logger.error('ReconnectionManager:index#rejoinMeeting --> Unable to reestablish media after rejoining.', _context3.t1);
|
|
576
|
+
throw _context3.t1;
|
|
577
|
+
case 30:
|
|
578
|
+
case "end":
|
|
579
|
+
return _context3.stop();
|
|
664
580
|
}
|
|
665
|
-
}, _callee3, this, [[1,
|
|
581
|
+
}, _callee3, this, [[1, 9], [21, 26]]);
|
|
666
582
|
}));
|
|
667
|
-
|
|
668
583
|
function rejoinMeeting() {
|
|
669
584
|
return _rejoinMeeting.apply(this, arguments);
|
|
670
585
|
}
|
|
671
|
-
|
|
672
586
|
return rejoinMeeting;
|
|
673
587
|
}()
|
|
674
588
|
/**
|
|
@@ -676,165 +590,110 @@ var ReconnectionManager = /*#__PURE__*/function () {
|
|
|
676
590
|
* @private
|
|
677
591
|
* @memberof ReconnectionManager
|
|
678
592
|
*/
|
|
679
|
-
|
|
680
593
|
}, {
|
|
681
594
|
key: "reconnectMedia",
|
|
682
|
-
value: function
|
|
683
|
-
var
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
595
|
+
value: function () {
|
|
596
|
+
var _reconnectMedia = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee4() {
|
|
597
|
+
var turnServerResult, iceServers;
|
|
598
|
+
return _regenerator.default.wrap(function _callee4$(_context4) {
|
|
599
|
+
while (1) switch (_context4.prev = _context4.next) {
|
|
600
|
+
case 0:
|
|
601
|
+
_loggerProxy.default.logger.log('ReconnectionManager:index#reconnectMedia --> Begin reestablishment of media');
|
|
602
|
+
|
|
603
|
+
// do the TURN server discovery again since the TURN server might change
|
|
604
|
+
_context4.next = 3;
|
|
605
|
+
return this.meeting.roap.doTurnDiscovery(this.meeting, true);
|
|
606
|
+
case 3:
|
|
607
|
+
turnServerResult = _context4.sent;
|
|
608
|
+
iceServers = [];
|
|
609
|
+
if (turnServerResult.turnServerInfo) {
|
|
610
|
+
iceServers.push({
|
|
611
|
+
urls: turnServerResult.turnServerInfo.url,
|
|
612
|
+
username: turnServerResult.turnServerInfo.username || '',
|
|
613
|
+
credential: turnServerResult.turnServerInfo.password || ''
|
|
614
|
+
});
|
|
615
|
+
}
|
|
616
|
+
_context4.next = 8;
|
|
617
|
+
return this.meeting.mediaProperties.webrtcMediaConnection.reconnect(iceServers);
|
|
618
|
+
case 8:
|
|
619
|
+
// resend media requests
|
|
620
|
+
if (this.meeting.isMultistream) {
|
|
621
|
+
(0, _values.default)(this.meeting.mediaRequestManagers).forEach(function (mediaRequestManager) {
|
|
622
|
+
mediaRequestManager.clearPreviousRequests();
|
|
623
|
+
mediaRequestManager.commit();
|
|
624
|
+
});
|
|
625
|
+
}
|
|
626
|
+
case 9:
|
|
627
|
+
case "end":
|
|
628
|
+
return _context4.stop();
|
|
629
|
+
}
|
|
630
|
+
}, _callee4, this);
|
|
631
|
+
}));
|
|
632
|
+
function reconnectMedia() {
|
|
633
|
+
return _reconnectMedia.apply(this, arguments);
|
|
634
|
+
}
|
|
635
|
+
return reconnectMedia;
|
|
636
|
+
}()
|
|
707
637
|
/**
|
|
708
638
|
* Attempt to Reconnect Mercury Websocket
|
|
709
639
|
* @returns {Promise}
|
|
710
640
|
* @private
|
|
711
641
|
* @memberof ReconnectionManager
|
|
712
642
|
*/
|
|
713
|
-
|
|
714
643
|
}, {
|
|
715
644
|
key: "reconnectMercuryWebSocket",
|
|
716
645
|
value: function () {
|
|
717
|
-
var _reconnectMercuryWebSocket = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function
|
|
718
|
-
return _regenerator.default.wrap(function
|
|
719
|
-
while (1) {
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
if (!this.webex.internal.mercury.connected) {
|
|
726
|
-
_context4.next = 13;
|
|
727
|
-
break;
|
|
728
|
-
}
|
|
729
|
-
|
|
730
|
-
_loggerProxy.default.logger.info('ReconnectionManager:index#reconnectMercuryWebSocket --> Disconnecting existing websocket.');
|
|
731
|
-
|
|
732
|
-
_context4.prev = 3;
|
|
733
|
-
_context4.next = 6;
|
|
734
|
-
return this.webex.internal.mercury.disconnect();
|
|
735
|
-
|
|
736
|
-
case 6:
|
|
737
|
-
_loggerProxy.default.logger.info('ReconnectionManager:index#reconnectMercuryWebSocket --> Websocket disconnected successfully.');
|
|
738
|
-
|
|
739
|
-
_context4.next = 13;
|
|
740
|
-
break;
|
|
741
|
-
|
|
742
|
-
case 9:
|
|
743
|
-
_context4.prev = 9;
|
|
744
|
-
_context4.t0 = _context4["catch"](3);
|
|
745
|
-
|
|
746
|
-
// If we can't disconnect, the sdk is in such a bad state that reconnecting is not going to happen.
|
|
747
|
-
_loggerProxy.default.logger.error('ReconnectionManager:index#reconnectMercuryWebSocket --> Unable to disconnect from websocket, giving up.', _context4.t0);
|
|
748
|
-
|
|
749
|
-
throw _context4.t0;
|
|
750
|
-
|
|
751
|
-
case 13:
|
|
752
|
-
_context4.prev = 13;
|
|
753
|
-
|
|
754
|
-
_loggerProxy.default.logger.info('ReconnectionManager:index#reconnectMercuryWebSocket --> Connecting websocket.');
|
|
755
|
-
|
|
756
|
-
_context4.next = 17;
|
|
757
|
-
return this.webex.internal.mercury.connect();
|
|
758
|
-
|
|
759
|
-
case 17:
|
|
760
|
-
_loggerProxy.default.logger.info('ReconnectionManager:index#reconnectMercuryWebSocket --> Websocket connected successfully.');
|
|
761
|
-
|
|
762
|
-
_context4.next = 24;
|
|
646
|
+
var _reconnectMercuryWebSocket = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee5() {
|
|
647
|
+
return _regenerator.default.wrap(function _callee5$(_context5) {
|
|
648
|
+
while (1) switch (_context5.prev = _context5.next) {
|
|
649
|
+
case 0:
|
|
650
|
+
_loggerProxy.default.logger.info('ReconnectionManager:index#reconnectMercuryWebSocket --> Reconnecting websocket.');
|
|
651
|
+
// First, attempt to disconnect if we think we are already connected.
|
|
652
|
+
if (!this.webex.internal.mercury.connected) {
|
|
653
|
+
_context5.next = 13;
|
|
763
654
|
break;
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
655
|
+
}
|
|
656
|
+
_loggerProxy.default.logger.info('ReconnectionManager:index#reconnectMercuryWebSocket --> Disconnecting existing websocket.');
|
|
657
|
+
_context5.prev = 3;
|
|
658
|
+
_context5.next = 6;
|
|
659
|
+
return this.webex.internal.mercury.disconnect();
|
|
660
|
+
case 6:
|
|
661
|
+
_loggerProxy.default.logger.info('ReconnectionManager:index#reconnectMercuryWebSocket --> Websocket disconnected successfully.');
|
|
662
|
+
_context5.next = 13;
|
|
663
|
+
break;
|
|
664
|
+
case 9:
|
|
665
|
+
_context5.prev = 9;
|
|
666
|
+
_context5.t0 = _context5["catch"](3);
|
|
667
|
+
// If we can't disconnect, the sdk is in such a bad state that reconnecting is not going to happen.
|
|
668
|
+
_loggerProxy.default.logger.error('ReconnectionManager:index#reconnectMercuryWebSocket --> Unable to disconnect from websocket, giving up.', _context5.t0);
|
|
669
|
+
throw _context5.t0;
|
|
670
|
+
case 13:
|
|
671
|
+
_context5.prev = 13;
|
|
672
|
+
_loggerProxy.default.logger.info('ReconnectionManager:index#reconnectMercuryWebSocket --> Connecting websocket.');
|
|
673
|
+
_context5.next = 17;
|
|
674
|
+
return this.webex.internal.mercury.connect();
|
|
675
|
+
case 17:
|
|
676
|
+
_loggerProxy.default.logger.info('ReconnectionManager:index#reconnectMercuryWebSocket --> Websocket connected successfully.');
|
|
677
|
+
_context5.next = 24;
|
|
678
|
+
break;
|
|
679
|
+
case 20:
|
|
680
|
+
_context5.prev = 20;
|
|
681
|
+
_context5.t1 = _context5["catch"](13);
|
|
682
|
+
_loggerProxy.default.logger.error('ReconnectionManager:index#reconnectMercuryWebSocket --> Unable to connect to websocket, giving up.', _context5.t1);
|
|
683
|
+
throw _context5.t1;
|
|
684
|
+
case 24:
|
|
685
|
+
case "end":
|
|
686
|
+
return _context5.stop();
|
|
777
687
|
}
|
|
778
|
-
},
|
|
688
|
+
}, _callee5, this, [[3, 9], [13, 20]]);
|
|
779
689
|
}));
|
|
780
|
-
|
|
781
690
|
function reconnectMercuryWebSocket() {
|
|
782
691
|
return _reconnectMercuryWebSocket.apply(this, arguments);
|
|
783
692
|
}
|
|
784
|
-
|
|
785
693
|
return reconnectMercuryWebSocket;
|
|
786
694
|
}()
|
|
787
|
-
/**
|
|
788
|
-
* @param {Meeting} meeting
|
|
789
|
-
* @returns {undefined}
|
|
790
|
-
* @private
|
|
791
|
-
* @memberof ReconnectionManager
|
|
792
|
-
*/
|
|
793
|
-
|
|
794
|
-
}], [{
|
|
795
|
-
key: "setupPeerConnection",
|
|
796
|
-
value: function () {
|
|
797
|
-
var _setupPeerConnection = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee5(meeting) {
|
|
798
|
-
var turnInfo;
|
|
799
|
-
return _regenerator.default.wrap(function _callee5$(_context5) {
|
|
800
|
-
while (1) {
|
|
801
|
-
switch (_context5.prev = _context5.next) {
|
|
802
|
-
case 0:
|
|
803
|
-
_loggerProxy.default.logger.log('ReconnectionManager:index#setupPeerConnection --> Begin resetting peer connection'); // close pcs, unset to null and create a new one with out closing any streams
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
_peerConnectionManager.default.close(meeting.mediaProperties.peerConnection);
|
|
807
|
-
|
|
808
|
-
meeting.mediaProperties.unsetPeerConnection();
|
|
809
|
-
_context5.next = 5;
|
|
810
|
-
return meeting.roap.doTurnDiscovery(meeting, true);
|
|
811
|
-
|
|
812
|
-
case 5:
|
|
813
|
-
turnInfo = _context5.sent;
|
|
814
|
-
meeting.mediaProperties.reInitiatePeerconnection(turnInfo);
|
|
815
|
-
|
|
816
|
-
_peerConnectionManager.default.setPeerConnectionEvents(meeting); // update the peerconnection in the stats manager when ever we reconnect
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
meeting.statsAnalyzer.updatePeerconnection(meeting.mediaProperties.peerConnection);
|
|
820
|
-
|
|
821
|
-
case 9:
|
|
822
|
-
case "end":
|
|
823
|
-
return _context5.stop();
|
|
824
|
-
}
|
|
825
|
-
}
|
|
826
|
-
}, _callee5);
|
|
827
|
-
}));
|
|
828
|
-
|
|
829
|
-
function setupPeerConnection(_x2) {
|
|
830
|
-
return _setupPeerConnection.apply(this, arguments);
|
|
831
|
-
}
|
|
832
|
-
|
|
833
|
-
return setupPeerConnection;
|
|
834
|
-
}()
|
|
835
695
|
}]);
|
|
836
696
|
return ReconnectionManager;
|
|
837
697
|
}();
|
|
838
|
-
|
|
839
698
|
exports.default = ReconnectionManager;
|
|
840
699
|
//# sourceMappingURL=index.js.map
|