jicofo icon indicating copy to clipboard operation
jicofo copied to clipboard

Jicofo does not like being refused the creation of a room

Open nud opened this issue 4 years ago • 1 comments

When the XMPP server refuses the creation of a room for any reason, jicofo complains about an unexpected exception.

It should probably maybe show a warning or something, but not display such an alarming exception. Also it is not clear what happens exactly (I guess jicofo is crashing?)

Here is an example of such a configuration using the muc_restrict_rooms module in prosody:

Jicofo 2020-04-23 11:21:13.207 INFO: [330] org.jitsi.jicofo.JitsiMeetConferenceImpl.log() Joining the room: [email protected]
Jicofo 2020-04-23 11:21:13.208 WARNING: [289] org.jitsi.impl.protocol.xmpp.ChatRoomImpl.log() Unable to handle packet: <presence to='[email protected]/focus318677892984' from='[email protected]/focus' id='FDRyF-68432' type='error'><error type='cancel'><forbidden xmlns='urn:ietf:params:xml:ns:xmpp-stanzas'/><text xmlns='urn:ietf:params:xml:ns:xmpp-stanzas'>You&apos;re not allowed to enter this room: Room creation is restricted</text></error></presence>
Jicofo 2020-04-23 11:21:13.210 INFO: [330] org.jitsi.jicofo.FocusManager.log() Disposed conference for room: [email protected] conference count: 0
Jicofo 2020-04-23 11:21:13.210 INFO: [330] org.jitsi.jicofo.FocusManager.log() Exception while trying to start the conference
net.java.sip.communicator.service.protocol.OperationFailedException: Failed to join the room
	at org.jitsi.impl.protocol.xmpp.ChatRoomImpl.joinAs(ChatRoomImpl.java:298)
	at org.jitsi.impl.protocol.xmpp.ChatRoomImpl.join(ChatRoomImpl.java:209)
	at org.jitsi.jicofo.JitsiMeetConferenceImpl.joinTheRoom(JitsiMeetConferenceImpl.java:540)
	at org.jitsi.jicofo.JitsiMeetConferenceImpl.start(JitsiMeetConferenceImpl.java:366)
	at org.jitsi.jicofo.FocusManager.conferenceRequest(FocusManager.java:381)
	at org.jitsi.jicofo.FocusManager.conferenceRequest(FocusManager.java:330)
	at org.jitsi.jicofo.xmpp.FocusComponent.handleConferenceIq(FocusComponent.java:421)
	at org.jitsi.jicofo.xmpp.FocusComponent.handleIQSetImpl(FocusComponent.java:259)
	at org.jitsi.xmpp.component.ComponentBase.handleIQSet(ComponentBase.java:362)
	at org.xmpp.component.AbstractComponent.processIQRequest(AbstractComponent.java:515)
	at org.xmpp.component.AbstractComponent.processIQ(AbstractComponent.java:289)
	at org.xmpp.component.AbstractComponent.processQueuedPacket(AbstractComponent.java:239)
	at org.xmpp.component.AbstractComponent.access$100(AbstractComponent.java:81)
	at org.xmpp.component.AbstractComponent$PacketProcessor.run(AbstractComponent.java:1051)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)
Caused by: org.jivesoftware.smack.XMPPException$XMPPErrorException: XMPP error reply received from [email protected]/focus: XMPPError: forbidden - cancel
	at org.jivesoftware.smack.XMPPException$XMPPErrorException.ifHasErrorThenThrow(XMPPException.java:132)
	at org.jivesoftware.smack.StanzaCollector.nextResultOrThrow(StanzaCollector.java:263)
	at org.jivesoftware.smackx.muc.MultiUserChat.enter(MultiUserChat.java:355)
	at org.jivesoftware.smackx.muc.MultiUserChat.createOrJoin(MultiUserChat.java:498)
	at org.jivesoftware.smackx.muc.MultiUserChat.createOrJoin(MultiUserChat.java:444)
	at org.jitsi.impl.protocol.xmpp.ChatRoomImpl.joinAs(ChatRoomImpl.java:240)
	... 16 more
Jicofo 2020-04-23 11:21:13.212 SEVERE: [330] org.jitsi.jicofo.xmpp.FocusComponent.handleIQSetImpl().324 net.java.sip.communicator.service.protocol.OperationFailedException: Failed to join the room
net.java.sip.communicator.service.protocol.OperationFailedException: Failed to join the room
	at org.jitsi.impl.protocol.xmpp.ChatRoomImpl.joinAs(ChatRoomImpl.java:298)
	at org.jitsi.impl.protocol.xmpp.ChatRoomImpl.join(ChatRoomImpl.java:209)
	at org.jitsi.jicofo.JitsiMeetConferenceImpl.joinTheRoom(JitsiMeetConferenceImpl.java:540)
	at org.jitsi.jicofo.JitsiMeetConferenceImpl.start(JitsiMeetConferenceImpl.java:366)
	at org.jitsi.jicofo.FocusManager.conferenceRequest(FocusManager.java:381)
	at org.jitsi.jicofo.FocusManager.conferenceRequest(FocusManager.java:330)
	at org.jitsi.jicofo.xmpp.FocusComponent.handleConferenceIq(FocusComponent.java:421)
	at org.jitsi.jicofo.xmpp.FocusComponent.handleIQSetImpl(FocusComponent.java:259)
	at org.jitsi.xmpp.component.ComponentBase.handleIQSet(ComponentBase.java:362)
	at org.xmpp.component.AbstractComponent.processIQRequest(AbstractComponent.java:515)
	at org.xmpp.component.AbstractComponent.processIQ(AbstractComponent.java:289)
	at org.xmpp.component.AbstractComponent.processQueuedPacket(AbstractComponent.java:239)
	at org.xmpp.component.AbstractComponent.access$100(AbstractComponent.java:81)
	at org.xmpp.component.AbstractComponent$PacketProcessor.run(AbstractComponent.java:1051)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)
Caused by: org.jivesoftware.smack.XMPPException$XMPPErrorException: XMPP error reply received from [email protected]/focus: XMPPError: forbidden - cancel
	at org.jivesoftware.smack.XMPPException$XMPPErrorException.ifHasErrorThenThrow(XMPPException.java:132)
	at org.jivesoftware.smack.StanzaCollector.nextResultOrThrow(StanzaCollector.java:263)
	at org.jivesoftware.smackx.muc.MultiUserChat.enter(MultiUserChat.java:355)
	at org.jivesoftware.smackx.muc.MultiUserChat.createOrJoin(MultiUserChat.java:498)
	at org.jivesoftware.smackx.muc.MultiUserChat.createOrJoin(MultiUserChat.java:444)
	at org.jitsi.impl.protocol.xmpp.ChatRoomImpl.joinAs(ChatRoomImpl.java:240)
	... 16 more
Jicofo 2020-04-23 11:21:13.212 WARNING: [330] org.jitsi.jicofo.xmpp.FocusComponent.processIQ() (serving component 'Jitsi Meet Focus') Unexpected exception while processing IQ stanza: <iq from="[email protected]/mVGoKb5a" id="6b57dc79-71fc-42a7-ba34-f2ef79c6d441:sendIQ" to="focus.meet.jitsi" type="set"><conference xmlns="http://jitsi.org/protocol/focus" room="[email protected]" machine-uid="2dfd712789833b3e69f2d0e73b8910f3" session-id="ed0f0211-70c6-4454-a11f-f15fe470cf66"><property name="channelLastN" value="-1"/><property name="disableRtx" value="false"/><property name="enableLipSync" value="true"/><property name="openSctp" value="true"/></conference></iq>
net.java.sip.communicator.service.protocol.OperationFailedException: Failed to join the room
	at org.jitsi.impl.protocol.xmpp.ChatRoomImpl.joinAs(ChatRoomImpl.java:298)
	at org.jitsi.impl.protocol.xmpp.ChatRoomImpl.join(ChatRoomImpl.java:209)
	at org.jitsi.jicofo.JitsiMeetConferenceImpl.joinTheRoom(JitsiMeetConferenceImpl.java:540)
	at org.jitsi.jicofo.JitsiMeetConferenceImpl.start(JitsiMeetConferenceImpl.java:366)
	at org.jitsi.jicofo.FocusManager.conferenceRequest(FocusManager.java:381)
	at org.jitsi.jicofo.FocusManager.conferenceRequest(FocusManager.java:330)
	at org.jitsi.jicofo.xmpp.FocusComponent.handleConferenceIq(FocusComponent.java:421)
	at org.jitsi.jicofo.xmpp.FocusComponent.handleIQSetImpl(FocusComponent.java:259)
	at org.jitsi.xmpp.component.ComponentBase.handleIQSet(ComponentBase.java:362)
	at org.xmpp.component.AbstractComponent.processIQRequest(AbstractComponent.java:515)
	at org.xmpp.component.AbstractComponent.processIQ(AbstractComponent.java:289)
	at org.xmpp.component.AbstractComponent.processQueuedPacket(AbstractComponent.java:239)
	at org.xmpp.component.AbstractComponent.access$100(AbstractComponent.java:81)
	at org.xmpp.component.AbstractComponent$PacketProcessor.run(AbstractComponent.java:1051)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)
Caused by: org.jivesoftware.smack.XMPPException$XMPPErrorException: XMPP error reply received from [email protected]/focus: XMPPError: forbidden - cancel
	at org.jivesoftware.smack.XMPPException$XMPPErrorException.ifHasErrorThenThrow(XMPPException.java:132)
	at org.jivesoftware.smack.StanzaCollector.nextResultOrThrow(StanzaCollector.java:263)
	at org.jivesoftware.smackx.muc.MultiUserChat.enter(MultiUserChat.java:355)
	at org.jivesoftware.smackx.muc.MultiUserChat.createOrJoin(MultiUserChat.java:498)
	at org.jivesoftware.smackx.muc.MultiUserChat.createOrJoin(MultiUserChat.java:444)
	at org.jitsi.impl.protocol.xmpp.ChatRoomImpl.joinAs(ChatRoomImpl.java:240)
	... 16 more
Jicofo 2020-04-23 11:21:15.315 INFO: [331] org.jitsi.jicofo.xmpp.FocusComponent.handleConferenceIq().401 Focus request for room: [email protected]
Jicofo 2020-04-23 11:21:15.315 INFO: [331] org.jitsi.jicofo.auth.AbstractAuthAuthority.log() Authenticated jid: [email protected]/mVGoKb5a with session: AuthSession[[email protected], [email protected]/mVGoKb5a, SID=ed0f0211-70c6-4454-a11f-f15fe470cf66, MUID=2dfd712789833b3e69f2d0e73b8910f3, LIFE_TM_SEC=2, [email protected]]@7714691
Jicofo 2020-04-23 11:21:15.316 INFO: [331] org.jitsi.jicofo.auth.AbstractAuthAuthority.log() Jid [email protected]/mVGoKb5a authenticated as: [email protected]
Jicofo 2020-04-23 11:21:15.316 INFO: [331] org.jitsi.jicofo.FocusManager.log() Created new focus for [email protected]@auth.meet.jitsi. Conference count 1,options: 
Jicofo 2020-04-23 11:21:15.316 INFO: [331] org.jitsi.jicofo.JitsiMeetConferenceImpl.log() Lip-sync enabled in [email protected]

nud avatar Apr 23 '20 10:04 nud

It is an unhandled exception or some type of stack trace, in both situations, Jicofo still can service. you may want to test it by joining to restricted rooms and unrestricted ones alternatively. I faced the error when the below option was enabled in Jicofo config: org.jitsi.jicofo.health.ENABLE_HEALTH_CHECKS=true change it to true to fix the problem. the reason is the health check room does not exist so it fails.

amirphl avatar Jun 01 '20 20:06 amirphl

In master the exception is handled, but there's not much we can do. Jicofo requires permissions to create rooms.

bgrozev avatar Jan 04 '23 20:01 bgrozev

@bgrozev the bug report was about jicofo crashing when it can't create the room, because the server refuses it, so I suppose it's ok if the room is not created as long as the server is not crashing. :slightly_smiling_face:

thanks.

nud avatar Jan 04 '23 22:01 nud