When a user left the chat room,the user will send a unavailable presence to the chat room and the chat room will send two of the same notice repeatedly to the user. (in version 3.5.2 or 3.6.2)
For example:
User2Room:
Room2User:
Room2User:
View source code: org.jivesoftware.openfire.muc.spi.LocalMUCRoom
public void leaveRoom(MUCRole leaveRole) {
……
// Inform the leaving user that he/she has left the room
leaveRole.send(presence);//The presence should not be sent repeatedly.So this line should be deleted in my opinion
// Inform the rest of the room occupants that the user has left the room
broadcastPresence(presence);//The presence can be sent to all occupants inlucde leaveRole.
……
// Remove occupant from room and destroy room if empty and not persistent
OccupantLeftEvent event = new OccupantLeftEvent(this, leaveRole);
event.setOriginator(true);
event.run();
}
Let me know if my view is not correct.
Fingki Li