aws-samples / amazon-chime-react-native-demo

A React Native demo application for Android and iOS using the Amazon Chime SDK.
MIT No Attribution
102 stars 24 forks source link

Audio is off in iOS when app goes into background/sleep. #82

Closed prashanthacharyam closed 3 years ago

prashanthacharyam commented 3 years ago

Describe the bug Audio is off in iOS when app goes into background/sleep. On returning back to app it works. No such issue on Android

Expected behavior Audio to not go off when app is in background and meeting in progress.

Test environment Info (please complete the following information):

ziyiz-amzn commented 3 years ago

Thank you for reporting @prashanthacharyam .

I will take a look and update.

zhinang-amazon commented 3 years ago

Hi @prashanthacharyam

Please take a look at this issue in our iOS SDK repo: https://github.com/aws/amazon-chime-sdk-ios/issues/308 Integrating the application with CallKit will resolve this issue. Without CallKit, our SDK will lose access to the AVAudioSession when the application goes into background or if there is interruption such as phone call.

You can follow this blogpost on how to integrate CallKit. I will resolve this issue for now. Feel free to reopen if this is still an issue afterwards.

prashanthacharyam commented 3 years ago

Is there an example which uses objective c since the react native examples are in objective c.

zhinang-amazon commented 3 years ago

Hi @prashanthacharyam,

Sorry that we do not have an objective c example at this point.

prashanthacharyam commented 3 years ago

I ended up enabling background audio for the app which solves my issue. Callkit integration was not needed.

zhinang-amazon commented 3 years ago

Hi @prashanthacharyam, I'm glad that worked for you. Background audio is necessary indeed. However also keep in mind that without CallKit integration, your audio/video call can be terminated when there is a phone call or other CallKit enabled call from another application

prashanthacharyam commented 3 years ago

Hi, ok. It should be fine for us now.

On Tue, Jun 22, 2021 at 9:42 PM Zhinan Guan @.***> wrote:

Hi @prashanthacharyam https://github.com/prashanthacharyam, I'm glad that worked for you. Background audio is necessary indeed. However also keep in mind that without CallKit integration, your audio/video call can be terminated when there is a phone call or other CallKit enabled call from another application

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/aws-samples/amazon-chime-react-native-demo/issues/82#issuecomment-866125355, or unsubscribe https://github.com/notifications/unsubscribe-auth/AMQQUE4GVS4WSO3B5CSMBOTTUCY6HANCNFSM46JUE4AQ .