communication-ui-library icon indicating copy to clipboard operation
communication-ui-library copied to clipboard

ChatComposite is missing messages sent when iOS in is background mode

Open ddematheu2 opened this issue 2 years ago • 3 comments

Moving to an issue.

Discussed in https://github.com/Azure/communication-ui-library/discussions/1705

Originally posted by DercilioFontes March 22, 2022 Hi,

I would like to know if you guys have a solution to that problem. Everything is working fine, and thanks for the package.

The only problem I am facing and I couldn't find any help googling is that if the ios side that is chatting goes to background mode it misses the messages sent to it during that time. I know the iOS background mode doesn't allow the communication to happen, but when it is active again it could update with new messages.

I was trying to use some ChatAdapter methods like fetchInitialData and loadPreviousChatMessages but no result.

I'm in an React Ionic project, using: "@azure/communication-chat": "^1.1.2", "@azure/communication-common": "^2.0.0", "@azure/communication-react": "^1.1.0",

ddematheu2 avatar Mar 24 '22 19:03 ddematheu2

Thanks, @ddematheu2.

I think it is an important issue.

So, for someone that can be facing the same issue and as an update, I got a solution adding a listener event to the app state change (when it is active again) and recreating the ChatAdapter and calling the fetchInitialData and loadPreviousChatMessages.

DercilioFontes avatar Mar 25 '22 21:03 DercilioFontes

Hi, Just want to let you know we have created a work item for this issue, will update you once it's done! :) Thanks for your patience!

carocao-msft avatar Nov 03 '22 22:11 carocao-msft

ADO item #2887810

jpeng-ms avatar Apr 17 '23 19:04 jpeng-ms

Hi @DercilioFontes

we had an internal discussion about the solution regarding the issue you raised. We have decided that from a product perspective, we think this is more suited to be resolved by using our native UI library SDKs, which is our iOS UI library in this case. So I will go ahead and close this issue for now.

Please feel free to reopen this issue anytime.

jpeng-ms avatar Jun 24 '24 20:06 jpeng-ms

cc @palatter

jpeng-ms avatar Jun 24 '24 20:06 jpeng-ms