webex / webex-js-sdk

JavaScript SDK for Webex
https://webex.github.io/webex-js-sdk/
Other
167 stars 334 forks source link

fix: don't send CA events when we do Locus /media API calls for mute/unmute and improve when we send them for Roap messages #3646

Closed marcin-bazyl closed 2 weeks ago

marcin-bazyl commented 2 weeks ago

COMPLETES #SPARK-529334

This pull request addresses

We were sending CA event "client.locus.media.request" and "client.locus.media.response" every time we do Locus /media API call. These calls are made when we want to send Roap messages, but also when we mute/unmute. CA is not interested in the mute/unmute ones and in some meetings users generate a lot of them.

by making the following changes

It's been agreed with CA team that we will only send the "client.locus.media.request" and "client.locus.media.response" events for Roap messages, not for mute/unmute operations.

Also I've noticed that for Roap messages we were sending the "client.locus.media.request" event too early, when it still might be queued inside LocusMediaRequest, so in some extreme edge cases when the LocusMediaRequest is stuck, we might send the CA event and never actually do the Locus reuqest, so I've moved the code for sending the CA events from roap/request.ts to LocusMediaRequest.

Change Type

The following scenarios where tested

unit tests + manual test with the web app - confirmed that CA didn't receive the events and that it still marked the call as success (correlationId=b92f8b1c-cbd1-45dd-9f62-96b716710960)

I certified that


Make sure to have followed the contributing guidelines before submitting.

aws-amplify-us-east-2[bot] commented 2 weeks ago

This pull request is automatically being deployed by Amplify Hosting (learn more).

Access this pull request here: https://pr-3646.d3m3l2kee0btzx.amplifyapp.com