Closed bramley-stride closed 3 years ago
We cannot investigate the issue without logs. Please provide full client logs (debug output from Android Studio or xCode).
Please close once same iOS issue is resolved (https://github.com/ServicePattern/MobileAPI_IOS/issues/31).
Seems the server is fine, but the app uses async event polling and getChatHistory() concurrently and renders the events twice (one from polling and once from getChatHistory response).
Just to clarify. The main way of getting server events is polling. It started by calling ContacCenterCommunicator.startPolling(chatID). The library will poll for event and deliver them to the application via chatSessionEvents callback.
Alternatively, there is a ContactCenterCommunicator.getChatHistory() method which would return the entire history of the current chat session. This history shows all events, including the ones which have been previously delivered via callback. Therefore it is application's responsibility to avoid double rendering of the same event received via callback and via getChatHistory().
Same as iOS issue: https://github.com/ServicePattern/MobileAPI_IOS/issues/31 Sometimes apps are getting duplicate events so duplicated messages in chat window. It's not happening every time.