How to send XMPP message confirmation (double tick) to user1, if user2 phone's screen off using push?

二次信任 提交于 2019-12-02 08:22:07

问题


I am using react-native Android and IOS app with Mongooseim for chat server. Following is the scenario.

Problem: Suppose there are 2 users - user1 and user2. They can exchange xmpp message stanza (using xmpp.js) from their Android/IOS devices when both are connected to the chat server. Now if user2 phone screen is turned off (or no xmpp connection) then how to send message from user1 to user2 and then in return user1 must receive some sort of message delivered confirmation (similarly like double tick in whatsapp or hike chat messenger).

This problem is more related to how to use FCM in Android/IOS for receving message and then replying with confirmation instead of exchanging xmpp messages. But still any type of help in appreciated

Considering options:

  1. I must use mongooseim push or FCM (with own implementation) to send data FCM from user1 to user2 and then user2 must open the xmpp connection with the server.

  2. or User2 must reply with FCM again and must avoid opening connection with XMPP chat server.

anything else???

来源:https://stackoverflow.com/questions/54630204/how-to-send-xmpp-message-confirmation-double-tick-to-user1-if-user2-phones-s

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!