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