@webex/plugin-meetings 3.8.0-next.62 → 3.8.0-next.64
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/breakouts/breakout.js +1 -1
- package/dist/breakouts/index.js +1 -1
- package/dist/interpretation/index.js +1 -1
- package/dist/interpretation/siLanguage.js +1 -1
- package/dist/meeting/brbState.js +6 -0
- package/dist/meeting/brbState.js.map +1 -1
- package/dist/webinar/index.js +1 -1
- package/package.json +21 -21
- package/src/meeting/brbState.ts +7 -0
- package/test/unit/spec/meeting/brbState.ts +19 -0
package/dist/breakouts/index.js
CHANGED
@@ -1046,7 +1046,7 @@ var Breakouts = _webexCore.WebexPlugin.extend({
|
|
1046
1046
|
this.trigger(_constants.BREAKOUTS.EVENTS.ASK_RETURN_TO_MAIN);
|
1047
1047
|
}
|
1048
1048
|
},
|
1049
|
-
version: "3.8.0-next.
|
1049
|
+
version: "3.8.0-next.64"
|
1050
1050
|
});
|
1051
1051
|
var _default = exports.default = Breakouts;
|
1052
1052
|
//# sourceMappingURL=index.js.map
|
@@ -373,7 +373,7 @@ var SimultaneousInterpretation = _webexCore.WebexPlugin.extend({
|
|
373
373
|
throw error;
|
374
374
|
});
|
375
375
|
},
|
376
|
-
version: "3.8.0-next.
|
376
|
+
version: "3.8.0-next.64"
|
377
377
|
});
|
378
378
|
var _default = exports.default = SimultaneousInterpretation;
|
379
379
|
//# sourceMappingURL=index.js.map
|
@@ -18,7 +18,7 @@ var SILanguage = _webexCore.WebexPlugin.extend({
|
|
18
18
|
languageCode: 'number',
|
19
19
|
languageName: 'string'
|
20
20
|
},
|
21
|
-
version: "3.8.0-next.
|
21
|
+
version: "3.8.0-next.64"
|
22
22
|
});
|
23
23
|
var _default = exports.default = SILanguage;
|
24
24
|
//# sourceMappingURL=siLanguage.js.map
|
package/dist/meeting/brbState.js
CHANGED
@@ -83,6 +83,12 @@ var BrbState = exports.BrbState = /*#__PURE__*/function () {
|
|
83
83
|
this.state.syncToServerInProgress = true;
|
84
84
|
return this.sendLocalBrbStateToServer(sendSlotManager).then(function () {
|
85
85
|
_this.state.syncToServerInProgress = false;
|
86
|
+
|
87
|
+
// This is a workaround for the fact that the server does not send the brb state
|
88
|
+
// in the locus update when a user joins from multiple devices but not all devices are requested brb.
|
89
|
+
// In the future, this could be improved with a new brb locus update handler
|
90
|
+
// https://jira-eng-gpk2.cisco.com/jira/browse/SPARK-655626
|
91
|
+
_this.handleServerBrbUpdate(_this.state.client.enabled);
|
86
92
|
_loggerProxy.default.logger.info("Meeting:brbState#applyClientStateToServer: sync with server completed");
|
87
93
|
|
88
94
|
// need to check if a new sync is required, because this.state.client may have changed while we were doing the current sync
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["_internalMediaCore","require","_loggerProxy","_interopRequireDefault","createBrbState","exports","meeting","enabled","LoggerProxy","logger","info","concat","id","brbState","BrbState","_classCallCheck2","default","_defineProperty2","state","client","server","syncToServerInProgress","_createClass2","key","value","enable","sendSlotManager","applyClientStateToServer","_this","_promise","resolve","remoteBrbRequiresSync","sendLocalBrbStateToServer","then","catch","e","warn","_sendLocalBrbStateToServer","_asyncToGenerator2","_regenerator","mark","_callee","errorMessage","error","_errorMessage","_error","wrap","_callee$","_context","prev","next","isMultistream","Error","abrupt","reject","mediaProperties","webrtcMediaConnection","meetingRequest","setBrb","locusUrl","deviceUrl","selfId","setSourceStateOverride","MediaType","VideoMain","stop","_x","apply","arguments","handleServerBrbUpdate"],"sources":["brbState.ts"],"sourcesContent":["import {MediaType} from '@webex/internal-media-core';\nimport LoggerProxy from '../common/logs/logger-proxy';\nimport type Meeting from '.';\nimport SendSlotManager from '../multistream/sendSlotManager';\n\nexport const createBrbState = (meeting: Meeting, enabled: boolean) => {\n LoggerProxy.logger.info(\n `Meeting:brbState#createBrbState: creating BrbState for meeting id ${meeting?.id}`\n );\n\n const brbState = new BrbState(meeting, enabled);\n\n return brbState;\n};\n\n/** The purpose of this class is to manage the local and remote brb state\n * and make sure that the server state always matches the last requested state by the client.\n */\nexport class BrbState {\n state: {\n client: {\n enabled: boolean;\n };\n server: {\n enabled: boolean;\n };\n syncToServerInProgress: boolean;\n };\n\n meeting: Meeting;\n\n /**\n * Constructor\n *\n * @param {Meeting} meeting - the meeting object\n * @param {boolean} enabled - whether the client audio/video is enabled at all\n */\n constructor(meeting: Meeting, enabled: boolean) {\n this.meeting = meeting;\n this.state = {\n client: {\n enabled,\n },\n server: {\n enabled: false,\n },\n syncToServerInProgress: false,\n };\n }\n\n /**\n * Enables/disables brb\n *\n * @param {boolean} enabled\n * @param {SendSlotManager} sendSlotManager\n * @returns {Promise}\n */\n public enable(enabled: boolean, sendSlotManager: SendSlotManager) {\n this.state.client.enabled = enabled;\n\n return this.applyClientStateToServer(sendSlotManager);\n }\n\n /**\n * Updates the server local and remote brb values so that they match the current client desired state.\n *\n * @param {SendSlotManager} sendSlotManager\n * @returns {Promise}\n */\n private applyClientStateToServer(sendSlotManager: SendSlotManager) {\n if (this.state.syncToServerInProgress) {\n LoggerProxy.logger.info(\n `Meeting:brbState#applyClientStateToServer: request to server in progress, we need to wait for it to complete`\n );\n\n return Promise.resolve();\n }\n\n const remoteBrbRequiresSync = this.state.client.enabled !== this.state.server.enabled;\n\n LoggerProxy.logger.info(\n `Meeting:brbState#applyClientStateToServer: remoteBrbRequiresSync: ${remoteBrbRequiresSync}`\n );\n\n if (!remoteBrbRequiresSync) {\n LoggerProxy.logger.info(\n `Meeting:brbState#applyClientStateToServer: client state already matching server state, nothing to do`\n );\n\n return Promise.resolve();\n }\n\n this.state.syncToServerInProgress = true;\n\n return this.sendLocalBrbStateToServer(sendSlotManager)\n .then(() => {\n this.state.syncToServerInProgress = false;\n LoggerProxy.logger.info(\n `Meeting:brbState#applyClientStateToServer: sync with server completed`\n );\n\n // need to check if a new sync is required, because this.state.client may have changed while we were doing the current sync\n this.applyClientStateToServer(sendSlotManager);\n })\n .catch((e) => {\n this.state.syncToServerInProgress = false;\n LoggerProxy.logger.warn(`Meeting:brbState#applyClientStateToServer: error: ${e}`);\n });\n }\n\n /**\n * Send the local brb state to the server\n *\n * @param {SendSlotManager} sendSlotManager\n * @returns {Promise}\n */\n private async sendLocalBrbStateToServer(sendSlotManager: SendSlotManager) {\n const {enabled} = this.state.client;\n\n if (!this.meeting.isMultistream) {\n const errorMessage = 'Meeting:brbState#sendLocalBrbStateToServer: Not a multistream meeting';\n const error = new Error(errorMessage);\n\n LoggerProxy.logger.error(error);\n\n return Promise.reject(error);\n }\n\n if (!this.meeting.mediaProperties.webrtcMediaConnection) {\n const errorMessage =\n 'Meeting:brbState#sendLocalBrbStateToServer: WebRTC media connection is not defined';\n const error = new Error(errorMessage);\n\n LoggerProxy.logger.error(error);\n\n return Promise.reject(error);\n }\n\n // this logic should be applied only to multistream meetings\n return this.meeting.meetingRequest\n .setBrb({\n enabled,\n locusUrl: this.meeting.locusUrl,\n deviceUrl: this.meeting.deviceUrl,\n selfId: this.meeting.selfId,\n })\n .then(() => {\n sendSlotManager.setSourceStateOverride(MediaType.VideoMain, enabled ? 'away' : null);\n })\n .catch((error) => {\n LoggerProxy.logger.error('Meeting:brbState#sendLocalBrbStateToServer: Error ', error);\n\n return Promise.reject(error);\n });\n }\n\n /**\n * This method should be called whenever the server brb state is changed\n *\n * @param {Boolean} [enabled] true if user has brb enabled, false otherwise\n * @returns {undefined}\n */\n public handleServerBrbUpdate(enabled?: boolean) {\n LoggerProxy.logger.info(\n `Meeting:brbState#handleServerBrbUpdate: updating server brb to (${enabled})`\n );\n this.state.server.enabled = !!enabled;\n }\n}\n"],"mappings":";;;;;;;;;;;;;;AAAA,IAAAA,kBAAA,GAAAC,OAAA;AACA,IAAAC,YAAA,GAAAC,sBAAA,CAAAF,OAAA;AAIO,IAAMG,cAAc,GAAAC,OAAA,CAAAD,cAAA,GAAG,SAAjBA,cAAcA,CAAIE,OAAgB,EAAEC,OAAgB,EAAK;EACpEC,oBAAW,CAACC,MAAM,CAACC,IAAI,sEAAA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oDAAoD,EAAEA,KAAK,CAAC;gBAErF,OAAOd,QAAA,CAAAb,OAAA,CAAQsC,MAAM,CAACX,KAAK,CAAC;cAC9B,CAAC,CAAC;YAAA;YAAA;cAAA,OAAAK,QAAA,CAAAiB,IAAA;UAAA;QAAA,GAAAxB,OAAA;MAAA,CACL;MAAA,SAAAT,0BAAAkC,EAAA;QAAA,OAAA7B,0BAAA,CAAA8B,KAAA,OAAAC,SAAA;MAAA;MAAA,OAAApC,yBAAA;IAAA;IAED;AACF;AACA;AACA;AACA;AACA;IALE;EAAA;IAAAT,GAAA;IAAAC,KAAA,EAMA,SAAA6C,sBAA6B9D,OAAiB,EAAE;MAC9CC,oBAAW,CAACC,MAAM,CAACC,IAAI,oEAAAC,MAAA,CAC8CJ,OAAO,MAC5E,CAAC;MACD,IAAI,CAACW,KAAK,CAACE,MAAM,CAACb,OAAO,GAAG,CAAC,CAACA,OAAO;IACvC;EAAC;EAAA,OAAAO,QAAA;AAAA"}
|
1
|
+
{"version":3,"names":["_internalMediaCore","require","_loggerProxy","_interopRequireDefault","createBrbState","exports","meeting","enabled","LoggerProxy","logger","info","concat","id","brbState","BrbState","_classCallCheck2","default","_defineProperty2","state","client","server","syncToServerInProgress","_createClass2","key","value","enable","sendSlotManager","applyClientStateToServer","_this","_promise","resolve","remoteBrbRequiresSync","sendLocalBrbStateToServer","then","handleServerBrbUpdate","catch","e","warn","_sendLocalBrbStateToServer","_asyncToGenerator2","_regenerator","mark","_callee","errorMessage","error","_errorMessage","_error","wrap","_callee$","_context","prev","next","isMultistream","Error","abrupt","reject","mediaProperties","webrtcMediaConnection","meetingRequest","setBrb","locusUrl","deviceUrl","selfId","setSourceStateOverride","MediaType","VideoMain","stop","_x","apply","arguments"],"sources":["brbState.ts"],"sourcesContent":["import {MediaType} from '@webex/internal-media-core';\nimport LoggerProxy from '../common/logs/logger-proxy';\nimport type Meeting from '.';\nimport SendSlotManager from '../multistream/sendSlotManager';\n\nexport const createBrbState = (meeting: Meeting, enabled: boolean) => {\n LoggerProxy.logger.info(\n `Meeting:brbState#createBrbState: creating BrbState for meeting id ${meeting?.id}`\n );\n\n const brbState = new BrbState(meeting, enabled);\n\n return brbState;\n};\n\n/** The purpose of this class is to manage the local and remote brb state\n * and make sure that the server state always matches the last requested state by the client.\n */\nexport class BrbState {\n state: {\n client: {\n enabled: boolean;\n };\n server: {\n enabled: boolean;\n };\n syncToServerInProgress: boolean;\n };\n\n meeting: Meeting;\n\n /**\n * Constructor\n *\n * @param {Meeting} meeting - the meeting object\n * @param {boolean} enabled - whether the client audio/video is enabled at all\n */\n constructor(meeting: Meeting, enabled: boolean) {\n this.meeting = meeting;\n this.state = {\n client: {\n enabled,\n },\n server: {\n enabled: false,\n },\n syncToServerInProgress: false,\n };\n }\n\n /**\n * Enables/disables brb\n *\n * @param {boolean} enabled\n * @param {SendSlotManager} sendSlotManager\n * @returns {Promise}\n */\n public enable(enabled: boolean, sendSlotManager: SendSlotManager) {\n this.state.client.enabled = enabled;\n\n return this.applyClientStateToServer(sendSlotManager);\n }\n\n /**\n * Updates the server local and remote brb values so that they match the current client desired state.\n *\n * @param {SendSlotManager} sendSlotManager\n * @returns {Promise}\n */\n private applyClientStateToServer(sendSlotManager: SendSlotManager) {\n if (this.state.syncToServerInProgress) {\n LoggerProxy.logger.info(\n `Meeting:brbState#applyClientStateToServer: request to server in progress, we need to wait for it to complete`\n );\n\n return Promise.resolve();\n }\n\n const remoteBrbRequiresSync = this.state.client.enabled !== this.state.server.enabled;\n\n LoggerProxy.logger.info(\n `Meeting:brbState#applyClientStateToServer: remoteBrbRequiresSync: ${remoteBrbRequiresSync}`\n );\n\n if (!remoteBrbRequiresSync) {\n LoggerProxy.logger.info(\n `Meeting:brbState#applyClientStateToServer: client state already matching server state, nothing to do`\n );\n\n return Promise.resolve();\n }\n\n this.state.syncToServerInProgress = true;\n\n return this.sendLocalBrbStateToServer(sendSlotManager)\n .then(() => {\n this.state.syncToServerInProgress = false;\n\n // This is a workaround for the fact that the server does not send the brb state\n // in the locus update when a user joins from multiple devices but not all devices are requested brb.\n // In the future, this could be improved with a new brb locus update handler\n // https://jira-eng-gpk2.cisco.com/jira/browse/SPARK-655626\n this.handleServerBrbUpdate(this.state.client.enabled);\n\n LoggerProxy.logger.info(\n `Meeting:brbState#applyClientStateToServer: sync with server completed`\n );\n\n // need to check if a new sync is required, because this.state.client may have changed while we were doing the current sync\n this.applyClientStateToServer(sendSlotManager);\n })\n .catch((e) => {\n this.state.syncToServerInProgress = false;\n LoggerProxy.logger.warn(`Meeting:brbState#applyClientStateToServer: error: ${e}`);\n });\n }\n\n /**\n * Send the local brb state to the server\n *\n * @param {SendSlotManager} sendSlotManager\n * @returns {Promise}\n */\n private async sendLocalBrbStateToServer(sendSlotManager: SendSlotManager) {\n const {enabled} = this.state.client;\n\n if (!this.meeting.isMultistream) {\n const errorMessage = 'Meeting:brbState#sendLocalBrbStateToServer: Not a multistream meeting';\n const error = new Error(errorMessage);\n\n LoggerProxy.logger.error(error);\n\n return Promise.reject(error);\n }\n\n if (!this.meeting.mediaProperties.webrtcMediaConnection) {\n const errorMessage =\n 'Meeting:brbState#sendLocalBrbStateToServer: WebRTC media connection is not defined';\n const error = new Error(errorMessage);\n\n LoggerProxy.logger.error(error);\n\n return Promise.reject(error);\n }\n\n // this logic should be applied only to multistream meetings\n return this.meeting.meetingRequest\n .setBrb({\n enabled,\n locusUrl: this.meeting.locusUrl,\n deviceUrl: this.meeting.deviceUrl,\n selfId: this.meeting.selfId,\n })\n .then(() => {\n sendSlotManager.setSourceStateOverride(MediaType.VideoMain, enabled ? 'away' : null);\n })\n .catch((error) => {\n LoggerProxy.logger.error('Meeting:brbState#sendLocalBrbStateToServer: Error ', error);\n\n return Promise.reject(error);\n });\n }\n\n /**\n * This method should be called whenever the server brb state is changed\n *\n * @param {Boolean} [enabled] true if user has brb enabled, false otherwise\n * @returns {undefined}\n */\n public handleServerBrbUpdate(enabled?: boolean) {\n LoggerProxy.logger.info(\n `Meeting:brbState#handleServerBrbUpdate: updating server brb to (${enabled})`\n );\n this.state.server.enabled = !!enabled;\n }\n}\n"],"mappings":";;;;;;;;;;;;;;AAAA,IAAAA,kBAAA,GAAAC,OAAA;AACA,IAAAC,YAAA,GAAAC,sBAAA,CAAAF,OAAA;AAIO,IAAMG,cAAc,GAAAC,OAAA,CAAAD,cAAA,GAAG,SAAjBA,cAAcA,CAAIE,OAAgB,EAAEC,OAAgB,EAAK;EACpEC,oBAAW,CAACC,MAAM,CAACC,IAAI,sEAAAC,MAAA,CACgDL,OAAO,aAAPA,OAAO,uBAAPA,OAAO,CAAEM,EAAE,CAClF,CAAC;EAED,IAAMC,QAAQ,GAAG,IAAIC,QAAQ,CAACR,OAAO,EAAEC,OAAO,CAAC;EAE/C,OAAOM,QAAQ;AACjB,CAAC;;AAED;AACA;AACA;AAFA,IAGaC,QAAQ,GAAAT,OAAA,CAAAS,QAAA;EAanB;AACF;AACA;AACA;AACA;AACA;EACE,SAAAA,SAAYR,OAAgB,EAAEC,OAAgB,EAAE;IAAA,IAAAQ,gBAAA,CAAAC,OAAA,QAAAF,QAAA;IAAA,IAAAG,gBAAA,CAAAD,OAAA;IAAA,IAAAC,gBAAA,CAAAD,OAAA;IAC9C,IAAI,CAACV,OAAO,GAAGA,OAAO;IACtB,IAAI,CAACY,KAAK,GAAG;MACXC,MAAM,EAAE;QACNZ,OAAO,EAAPA;MACF,CAAC;MACDa,MAAM,EAAE;QACNb,OAAO,EAAE;MACX,CAAC;MACDc,sBAAsB,EAAE;IAC1B,CAAC;EACH;;EAEA;AACF;AACA;AACA;AACA;AACA;AACA;EANE,IAAAC,aAAA,CAAAN,OAAA,EAAAF,QAAA;IAAAS,GAAA;IAAAC,KAAA,EAOA,SAAAC,OAAclB,OAAgB,EAAEmB,eAAgC,EAAE;MAChE,IAAI,CAACR,KAAK,CAACC,MAAM,CAACZ,OAAO,GAAGA,OAAO;MAEnC,OAAO,IAAI,CAACoB,wBAAwB,CAACD,eAAe,CAAC;IACvD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OAAO,EAAPA,OAAO;gBACPqD,QAAQ,EAAE,IAAI,CAACtD,OAAO,CAACsD,QAAQ;gBAC/BC,SAAS,EAAE,IAAI,CAACvD,OAAO,CAACuD,SAAS;gBACjCC,MAAM,EAAE,IAAI,CAACxD,OAAO,CAACwD;cACvB,CAAC,CAAC,CACD7B,IAAI,CAAC,YAAM;gBACVP,eAAe,CAACqC,sBAAsB,CAACC,4BAAS,CAACC,SAAS,EAAE1D,OAAO,GAAG,MAAM,GAAG,IAAI,CAAC;cACtF,CAAC,CAAC,CACD4B,KAAK,CAAC,UAACS,KAAK,EAAK;gBAChBpC,oBAAW,CAACC,MAAM,CAACmC,KAAK,CAAC,oDAAoD,EAAEA,KAAK,CAAC;gBAErF,OAAOf,QAAA,CAAAb,OAAA,CAAQuC,MAAM,CAACX,KAAK,CAAC;cAC9B,CAAC,CAAC;YAAA;YAAA;cAAA,OAAAK,QAAA,CAAAiB,IAAA;UAAA;QAAA,GAAAxB,OAAA;MAAA,CACL;MAAA,SAAAV,0BAAAmC,EAAA;QAAA,OAAA7B,0BAAA,CAAA8B,KAAA,OAAAC,SAAA;MAAA;MAAA,OAAArC,yBAAA;IAAA;IAED;AACF;AACA;AACA;AACA;AACA;IALE;EAAA;IAAAT,GAAA;IAAAC,KAAA,EAMA,SAAAU,sBAA6B3B,OAAiB,EAAE;MAC9CC,oBAAW,CAACC,MAAM,CAACC,IAAI,oEAAAC,MAAA,CAC8CJ,OAAO,MAC5E,CAAC;MACD,IAAI,CAACW,KAAK,CAACE,MAAM,CAACb,OAAO,GAAG,CAAC,CAACA,OAAO;IACvC;EAAC;EAAA,OAAAO,QAAA;AAAA"}
|
package/dist/webinar/index.js
CHANGED
package/package.json
CHANGED
@@ -43,13 +43,13 @@
|
|
43
43
|
"@webex/eslint-config-legacy": "0.0.0",
|
44
44
|
"@webex/jest-config-legacy": "0.0.0",
|
45
45
|
"@webex/legacy-tools": "0.0.0",
|
46
|
-
"@webex/plugin-meetings": "3.8.0-next.
|
47
|
-
"@webex/plugin-rooms": "3.8.0-next.
|
48
|
-
"@webex/test-helper-chai": "3.8.0-next.
|
49
|
-
"@webex/test-helper-mocha": "3.8.0-next.
|
50
|
-
"@webex/test-helper-mock-webex": "3.8.0-next.
|
51
|
-
"@webex/test-helper-retry": "3.8.0-next.
|
52
|
-
"@webex/test-helper-test-users": "3.8.0-next.
|
46
|
+
"@webex/plugin-meetings": "3.8.0-next.64",
|
47
|
+
"@webex/plugin-rooms": "3.8.0-next.22",
|
48
|
+
"@webex/test-helper-chai": "3.8.0-next.18",
|
49
|
+
"@webex/test-helper-mocha": "3.8.0-next.18",
|
50
|
+
"@webex/test-helper-mock-webex": "3.8.0-next.18",
|
51
|
+
"@webex/test-helper-retry": "3.8.0-next.18",
|
52
|
+
"@webex/test-helper-test-users": "3.8.0-next.18",
|
53
53
|
"chai": "^4.3.4",
|
54
54
|
"chai-as-promised": "^7.1.1",
|
55
55
|
"eslint": "^8.24.0",
|
@@ -61,23 +61,23 @@
|
|
61
61
|
"typescript": "^4.7.4"
|
62
62
|
},
|
63
63
|
"dependencies": {
|
64
|
-
"@webex/common": "3.8.0-next.
|
64
|
+
"@webex/common": "3.8.0-next.18",
|
65
65
|
"@webex/event-dictionary-ts": "^1.0.1753",
|
66
66
|
"@webex/internal-media-core": "2.16.0",
|
67
|
-
"@webex/internal-plugin-conversation": "3.8.0-next.
|
68
|
-
"@webex/internal-plugin-device": "3.8.0-next.
|
69
|
-
"@webex/internal-plugin-llm": "3.8.0-next.
|
70
|
-
"@webex/internal-plugin-mercury": "3.8.0-next.
|
71
|
-
"@webex/internal-plugin-metrics": "3.8.0-next.
|
72
|
-
"@webex/internal-plugin-support": "3.8.0-next.
|
73
|
-
"@webex/internal-plugin-user": "3.8.0-next.
|
74
|
-
"@webex/internal-plugin-voicea": "3.8.0-next.
|
75
|
-
"@webex/media-helpers": "3.8.0-next.
|
76
|
-
"@webex/plugin-people": "3.8.0-next.
|
77
|
-
"@webex/plugin-rooms": "3.8.0-next.
|
67
|
+
"@webex/internal-plugin-conversation": "3.8.0-next.22",
|
68
|
+
"@webex/internal-plugin-device": "3.8.0-next.18",
|
69
|
+
"@webex/internal-plugin-llm": "3.8.0-next.21",
|
70
|
+
"@webex/internal-plugin-mercury": "3.8.0-next.20",
|
71
|
+
"@webex/internal-plugin-metrics": "3.8.0-next.18",
|
72
|
+
"@webex/internal-plugin-support": "3.8.0-next.22",
|
73
|
+
"@webex/internal-plugin-user": "3.8.0-next.18",
|
74
|
+
"@webex/internal-plugin-voicea": "3.8.0-next.64",
|
75
|
+
"@webex/media-helpers": "3.8.0-next.22",
|
76
|
+
"@webex/plugin-people": "3.8.0-next.20",
|
77
|
+
"@webex/plugin-rooms": "3.8.0-next.22",
|
78
78
|
"@webex/ts-sdp": "^1.8.1",
|
79
79
|
"@webex/web-capabilities": "^1.4.0",
|
80
|
-
"@webex/webex-core": "3.8.0-next.
|
80
|
+
"@webex/webex-core": "3.8.0-next.18",
|
81
81
|
"ampersand-collection": "^2.0.2",
|
82
82
|
"bowser": "^2.11.0",
|
83
83
|
"btoa": "^1.2.1",
|
@@ -93,5 +93,5 @@
|
|
93
93
|
"//": [
|
94
94
|
"TODO: upgrade jwt-decode when moving to node 18"
|
95
95
|
],
|
96
|
-
"version": "3.8.0-next.
|
96
|
+
"version": "3.8.0-next.64"
|
97
97
|
}
|
package/src/meeting/brbState.ts
CHANGED
@@ -95,6 +95,13 @@ export class BrbState {
|
|
95
95
|
return this.sendLocalBrbStateToServer(sendSlotManager)
|
96
96
|
.then(() => {
|
97
97
|
this.state.syncToServerInProgress = false;
|
98
|
+
|
99
|
+
// This is a workaround for the fact that the server does not send the brb state
|
100
|
+
// in the locus update when a user joins from multiple devices but not all devices are requested brb.
|
101
|
+
// In the future, this could be improved with a new brb locus update handler
|
102
|
+
// https://jira-eng-gpk2.cisco.com/jira/browse/SPARK-655626
|
103
|
+
this.handleServerBrbUpdate(this.state.client.enabled);
|
104
|
+
|
98
105
|
LoggerProxy.logger.info(
|
99
106
|
`Meeting:brbState#applyClientStateToServer: sync with server completed`
|
100
107
|
);
|
@@ -110,5 +110,24 @@ describe('plugin-meetings', () => {
|
|
110
110
|
|
111
111
|
assert.isTrue(brbState.state.server.enabled);
|
112
112
|
});
|
113
|
+
|
114
|
+
it('invokes handleServerBrbUpdate with correct client state after syncing with server', async () => {
|
115
|
+
const sendLocalBrbStateToServerStub = sinon
|
116
|
+
.stub(brbState, 'sendLocalBrbStateToServer')
|
117
|
+
.resolves();
|
118
|
+
|
119
|
+
const handleServerBrbUpdateSpy = sinon.spy(brbState, 'handleServerBrbUpdate');
|
120
|
+
|
121
|
+
await brbState.enable(true, meeting.sendSlotManager);
|
122
|
+
|
123
|
+
assert.isTrue(sendLocalBrbStateToServerStub.calledOnce);
|
124
|
+
|
125
|
+
assert.isTrue(handleServerBrbUpdateSpy.calledOnceWith(brbState.state.client.enabled));
|
126
|
+
|
127
|
+
assert.isFalse(brbState.state.syncToServerInProgress);
|
128
|
+
|
129
|
+
sendLocalBrbStateToServerStub.restore();
|
130
|
+
handleServerBrbUpdateSpy.restore();
|
131
|
+
});
|
113
132
|
});
|
114
133
|
});
|