esl / MongooseIM

MongooseIM is Erlang Solutions' robust, scalable and efficient XMPP server, aimed at large installations. Specifically designed for enterprise purposes, it is fault-tolerant and can utilise the resources of multiple clustered machines.
Other
1.67k stars 427 forks source link

MUCLight - How to handle pagination for the MUC Room messages #1068

Closed vickydhas closed 7 years ago

vickydhas commented 7 years ago

MongooseIM version: Beta 2.0.0 Installed from: Github Erlang/OTP version: 18

Describe the issue.

I have a quick question, as defined stanza's in the below reference link. How would the participants get the messages when they are offline.

Scenario Steps: 1) Owner Creates a room and adds participants 2) Participants that are online gets the create, added, affiliations messages (Perfect) 3) Participants that are offline from the initial addition onwards how they get the create group stanzas. 4) If someone removes himself or is kicked from room , the online members can get messages 5) How the participants are notified when they come online who were offline, Do these message stanza's are pushed by server to them like offline messages, As I see it is not received so those offline members how they refresh their data. 6) May be this participant was kicked so he may not have the access to to get anything from group details as he is no longer part of group.

MUCLigh Docs

Any inputs ??

vickydhas commented 7 years ago

Hello Team,

Any update on this please ??.

As per the MongooseIM MUC Light docs section below the TO: ID is mandatory to send as group ID, but what if, if the occupant who was added to the group was offline at that time. He may never get any groupID yet tht he can then send as per below section IQ stanza.

6.2.1 Groupchat message from occupant

FYI I am able to get my message from the IQ response and messages ... if I pass the right group ID.

Any help is much appreciated.

vickydhas commented 7 years ago

I implemented the MUC MAM as given in section [6.2 XEP-0313 Message Archive Management].

But when ever the user gets offline he have to call his IQ which gives the message from 0th index always.

Is there some possibility that he can asked from a particular time stamp. As every time he goes offline and come back he gets from 0th index the messages which he already fetched earlier.

Appreciate if the developers can give a highlight on this.

vickydhas commented 7 years ago

Hey guys, Any update or any direction on this for the MAM messages to be fetched in pagination.

Any guidance would be much appreciated.

vickydhas commented 7 years ago

Hello Team,

After careful understanding and documentation trials I figures that MAM can work in similar way as it works in MUC 0045 operations. After running the query over the MAM_Muc_message table with the IQ using start, after and complete = true methodologies as defined in [XEP-0313] (http://xmpp.org/extensions/xep-0313.html) I was successfully able to handle pagination.

Thanks to the Mongoose MUC Light implementation team to do the inherited way of approach.

Closing this bug as its fixed.