igniterealtime/openfire-monitoring-plugin

Stanzas not always stored for one-to-one messages whilst clustered

Closed this issue · 0 comments

Following a previous issue due to stanza reconstruction, itself due to missed stanza storing (see #137 and related commits for more), I've observed that some one-to-one message stanzas are not stored in the ofmessagearchive table which could cause similar issues in the future.

Using a similar construct as before, with a 2 node xmpp cluster (infrastructure here), 3 users connected.

User 1 connected to Node 1 via Smack
User 2 connected to Node 2 via Smack
User 3 connected to Node 2 via Conversations

User 1 sent a message to User 2. User 2 replied.
User 2 sent a message to User 3. User 3 replied.
User 3 sent a message to User 1. User 1 repled.

With 6 messages total, only the messages sent by User 1, on Node 1, were stored.
image
In this instance, Node 1 was the Senior cluster node.

I'm fairly certain that it's caused by this: https://github.com/igniterealtime/openfire-monitoring-plugin/blob/master/src/java/org/jivesoftware/openfire/archive/ConversationEvent.java#L57 - this was an empty string in 2015. The ConversationEvent got a stanza property in 2016.