aws / amazon-chime-sdk-js

A JavaScript client library for integrating multi-party communications powered by the Amazon Chime service.
Apache License 2.0
709 stars 477 forks source link

Save the redundant audio worker code during build time so that the worker code stays intact and is able to be loaded #2772

Closed dinmin-amzn closed 12 months ago

dinmin-amzn commented 1 year ago

Issue #: https://github.com/aws/amazon-chime-sdk-js/issues/2771 Description of changes: The redundant audio worker code string may vary based on the build system of different projects. Because of this, certain build systems will cause invalid worker code to be generated and the redundant audio worker will not be able to run. Now, the redundant audio worker code is saved at build time so that all clients can run the redundant audio worker with the same exact code, regardless of the client's build system.

This issue was originally found in https://github.com/aws/amazon-chime-sdk-js/issues/2771.

Testing:

Can these tested using a demo application? Please provide reproducible step-by-step instructions. Reproduction steps for the original issue are mentioned in https://github.com/aws/amazon-chime-sdk-js/issues/2771. Following the same steps with this change should fix the issue.

Checklist:

  1. Have you successfully run npm run build:release locally? y

  2. Do you add, modify, or delete public API definitions? If yes, has that been reviewed and approved? n

  3. Do you change the wire protocol, e.g. the request method? If yes, has that been reviewed and approved? n

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

dinmin-amzn commented 1 year ago

Wondering if we should make these lines INFO rather than DEBUG while we're at it?

[DEBUG] ChimeLogger - [AudioRed] Initializing RedundantAudioEncoder
[DEBUG] ChimeLogger - [AudioRed] Setting up sender RED transform
[DEBUG] ChimeLogger - [AudioRed] Setting up receiver RED transform
[DEBUG] ChimeLogger - [AudioRed] red payload type set to 63
[DEBUG] ChimeLogger - [AudioRed] opus payload type set to 111

Yes, we should make these INFO level