I’ve encountered an issue with Openfire 4.1.1. When I join a MUC room, the presence stanza for “myself” does not include a status code of 110, as required by XEP-0045. This is supposed to have been implemented in Openfire 3.9.x, and I did indeed locate the source code responsible for setting that status code element. However, for whatever reason, it’s not actually setting it. At first glance, this issue appears to be the same as https://issues.igniterealtime.org/browse/OF-860, but that was fixed several years ago in 3.10.0. There’s also this topic from over a year ago with no replies: Openfire doesn't return status 110 when joining MUC
I actually noticed this issue when upgrading my client application from Smack 4.1 to 4.3, since the latter waits specifically for a stanza with that status code and ends up timing out. To verify this while removing my own code from the equation, I tested this using the Swift 4.0.2 XMPP client.
The MUC room is a persistent room with the following settings. (personal info redacted)
In this scenario, the MUC room contains one existing user, who is an owner of the room. My client joins afterwards and is a member. The Permissions for the room have been set accordingly and both users are able to join:
Here is what it looks like when I try to join the MUC room in the Swift client. It does correctly show the “Moderator” and “Participant” usernames.
And here are the incoming and outgoing XMPP stanzas from Swift’s debug console:
Note the last presence stanza (not sure why it’s duplicated) which is missing the element required by XEP-0045.
And here is the stack trace from my application using Smack 4.3. The stanzas were the same - I did receive the presence stanza for “myself”, but it did not contain any status code element, so the stanza filter did not pick it up as a response, and it timed out.
org.jivesoftware.smack.SmackException$NoResponseException: No response received within reply timeout. Timeout was 15000ms (~15s). Waited for response using: AndFilter: (StanzaTypeFilter: Presence, OrFilter: (AndFilter: (FromMatchesFilter (ignoreResourcepart): tonytestmuc6@conference.MYXMPPDOMAIN.com, MUCUserStatusCodeFilter: status=110), AndFilter: (FromMatchesFilter (full): tonytestmuc6@conference.MYXMPPDOMAIN.com/USERNAME, StanzaIdFilter: id=V3LAz-51, PresenceTypeFilter: type=error))).
(my application’s stack traces, ultimately called from java.util.concurrent.ScheduledThreadPoolExecutor)