I have used Smack library onto my android XMPP messaging mobile application. We host our own eJabberd server on Amazon EC2. Most of the basic stuff works fine, like logging into our Jabber server, sending and receiving messages.
However, currently hit by an issue of simplifying the hand-shake process of adding roster. The approach is to add the roster directly into our MySQL DB that is supporting the XMPP messaging. Here is our scenario:
User A initiates a roster request to User B (we handle the request manually, without XMPP involved).
User B accepts the request. Once the request is accepted, we insert the data directly into our MySQL DB.
The next time User A login to our Jabber server, User B will be included as his roster.
Issue: Upon accepting the request by User B, if User A is ONLINE, we are not able to inform him that his request has been accepted. He has to logout and re-login, in order to have User B into his roster list.
Appreciate if there is any advice on our scenerio above. Thanks.