SyncManager: after initial caching, message collection handler only called with initial messages

Hello,

I’m experiencing an issue with SyncManager on React native where the first time the app is opened, the messages are cached and onSucceededMessageEvent is called with all messages in a channel.

However, after sending a message, closing the app, and re-opening it, onSucceededMessageEvent is still called with the same messages, not including the new one.

Yet, the debug console shows that all messages are fetched from the server, including the new one. If I reset the cache and async storage, then it works and fetches all messages including the new one.

I’m using the following versions:

"react-native": "^0.63.4",
"sendbird": "^3.0.151",
"sendbird-syncmanager": "^1.1.26",

Here is my implementation: Sendbird issue with SyncManager · GitHub

Any ideas?

1 Like

Thanks @patrick.span Reporting internally.

1 Like

Thanks @walter.rodriguez. Any updates and timeframe to resolve if it’s an issue in the SyncManager code?

If it’s more than a week and there’s no workaround, we’ll go to production without SyncManager first.

Hi @patrick.span,

It will likely take some time to investigate and determine a fix, and so it may be best to plan without it for now.

@patrick.span I was trying to build some test code according to your implementation.
Can you please check this code and confirm that it’s the same as you have there? I just did it for anyone to try it… Just need an application ID, user ID and a channel URL to send messages.

Can you please clone it and let me know if this error happens there? Thanks!

Hi walter, i’m trying to reproduce the issue with the code above, note that this issue is occurring in react-native, the code you have provided is for react, not react-native, it is impossible to reproduce the bug because the app behaves differently while setting it to the background and then to foreground on android makes the onSucceededMessageEvent unreachable, please provide a react-native project