avstack / gst-meet

Connect GStreamer pipelines to Jitsi Meet conferences
Apache License 2.0
70 stars 25 forks source link

cannot join conferences and play audio in meet.jit.si #52

Closed chunsan closed 2 years ago

chunsan commented 2 years ago

hello I'm confused by this question for a long time, need your help, thanks a lot. I'm using the official jitsi website to run a gst-meet demo, but it did not work very well. I build a conference in website , use gst-meet to join the meet, but can't see any participant joined. Meanwhile, gst-meet log shows i have already joined the meet and become the moderator of the meet, and there is some warning messages.

Here is my gst-meet commands: gst-meet --verbose=GST_DEBUG=3 --web-socket-url=wss://meet.jit.si/xmpp-websocket --room-name=bsdhd357 --send-pipeline="filesrc location=empty.opus ! queue ! oggdemux name=audio"

This is gst-meet logs, i bolded the suspicious lines:

2022-08-24T02:22:15.979275Z  INFO Connecting XMPP WebSocket to wss://meet.jit.si/xmpp-websocket
2022-08-24T02:22:15.986573Z DEBUG No cached session for DnsName(DnsName(DnsName("meet.jit.si")))    
2022-08-24T02:22:15.987042Z DEBUG Not resuming any session    
2022-08-24T02:22:15.992200Z DEBUG Using ciphersuite TLS13_AES_256_GCM_SHA384    
2022-08-24T02:22:15.992605Z DEBUG Not resuming    
2022-08-24T02:22:15.993411Z DEBUG TLS1.3 encrypted extensions: [ServerNameAck]    
2022-08-24T02:22:15.993695Z DEBUG ALPN protocol is None    
2022-08-24T02:22:16.018759Z DEBUG Ticket saved    
2022-08-24T02:22:16.019111Z DEBUG Ticket saved    
2022-08-24T02:22:16.019401Z DEBUG Client handshake done.    
2022-08-24T02:22:16.019821Z DEBUG XMPP    >>> <open xmlns='urn:ietf:params:xml:ns:xmpp-framing' to="meet.jit.si" version="1.0"/>
2022-08-24T02:22:16.024040Z DEBUG XMPP    <<< <open xml:lang='en' id='01bc33a1-5baf-44fb-bb4e-a87a9c3c1f15' version='1.0' from='meet.jit.si' xmlns='urn:ietf:params:xml:ns:xmpp-framing'/>
2022-08-24T02:22:16.024410Z  INFO Connected XMPP WebSocket
2022-08-24T02:22:16.024619Z DEBUG XMPP    <<< <stream:features xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams'><mechanisms xmlns='urn:ietf:params:xml:ns:xmpp-sasl'><mechanism>ANONYMOUS</mechanism></mechanisms></stream:features>
2022-08-24T02:22:16.024924Z DEBUG XMPP    >>> <auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism="ANONYMOUS"></auth>
2022-08-24T02:22:16.028142Z DEBUG XMPP    <<< <success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>
2022-08-24T02:22:16.028469Z DEBUG XMPP    >>> <open xmlns='urn:ietf:params:xml:ns:xmpp-framing' to="meet.jit.si" version="1.0"/>
2022-08-24T02:22:16.032010Z DEBUG XMPP    <<< <open xml:lang='en' id='4945201e-19af-4e9b-8e9a-c44072b23152' version='1.0' from='meet.jit.si' xmlns='urn:ietf:params:xml:ns:xmpp-framing'/>
2022-08-24T02:22:16.032342Z  INFO Logged in anonymously
2022-08-24T02:22:16.032536Z DEBUG XMPP    <<< <stream:features xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams'><bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'><required/></bind><session xmlns='urn:ietf:params:xml:ns:xmpp-session'><optional/></session><c ver='fkxeQFzLze3b2GXuumaL5rwHBIU=' node='http://prosody.im' xmlns='http://jabber.org/protocol/caps' hash='sha-1'/><sub xmlns='urn:xmpp:features:pre-approval'/><ver xmlns='urn:xmpp:features:rosterver'/><sm xmlns='urn:xmpp:sm:2'><optional/></sm><sm xmlns='urn:xmpp:sm:3'><optional/></sm></stream:features>
2022-08-24T02:22:16.032880Z DEBUG XMPP    >>> <iq xmlns='jabber:client' id="dace5f80-e267-433f-b4b2-b4cf6d38578f" type="set"><bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'/></iq>
2022-08-24T02:22:16.039989Z DEBUG XMPP    <<< <message xmlns='jabber:client' to='f61dd71f-63a5-4edf-a978-333bd9455482@meet.jit.si/MnFI49k3GZkC' from='meet.jit.si'><query xmlns='http://jabber.org/protocol/disco#info'><identity name='lobby.meet.jit.si' category='component' type='lobbyrooms'/><identity name='conferenceduration.meet.jit.si' category='component' type='conference_duration'/><identity name='Prosody' category='server' type='im'/><identity name='avmoderation.meet.jit.si' category='component' type='av_moderation'/><identity name='breakout.meet.jit.si' category='component' type='breakout_rooms'/><identity name='meet-jit-si-eu-frankfurt-1-s25' category='server' type='shard'/><identity name='eu-central-1' category='server' type='region'/><identity name='3201' category='server' type='release'/><identity name='speakerstats.meet.jit.si' category='component' type='speakerstats'/></query><services xmlns='urn:xmpp:extdisco:2'><service host='meet-jit-si-turnrelay.jitsi.net' port='443' type='stun'/><service type='turn' restricted='1' host='meet-jit-si-turnrelay.jitsi.net' port='443' password='UWQjp4nF799O8P/CyYHfhTiy+aQ=' transport='udp' username='1661394136' expires='2022-08-25T02:22:16Z'/><service type='turns' restricted='1' host='meet-jit-si-turnrelay.jitsi.net' port='443' password='UWQjp4nF799O8P/CyYHfhTiy+aQ=' transport='tcp' username='1661394136' expires='2022-08-25T02:22:16Z'/></services></message>
2022-08-24T02:22:16.040457Z DEBUG received unexpected element while waiting for bind response: parse error: This is not a iq element.
2022-08-24T02:22:16.040688Z DEBUG XMPP    <<< <iq id='dace5f80-e267-433f-b4b2-b4cf6d38578f' xmlns='jabber:client' type='result'><bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'><jid>f61dd71f-63a5-4edf-a978-333bd9455482@meet.jit.si/MnFI49k3GZkC</jid></bind></iq>
2022-08-24T02:22:16.040947Z  INFO My JID: f61dd71f-63a5-4edf-a978-333bd9455482@meet.jit.si/MnFI49k3GZkC
2022-08-24T02:22:16.041213Z DEBUG XMPP    >>> <iq xmlns='jabber:client' from="f61dd71f-63a5-4edf-a978-333bd9455482@meet.jit.si/MnFI49k3GZkC" id="cdc728ba-42b0-4134-87fb-408602609ec2" to="meet.jit.si" type="get"><query xmlns='http://jabber.org/protocol/disco#info'/></iq>
2022-08-24T02:22:16.042604Z DEBUG XMPP    >>> <iq xmlns='jabber:client' id="0b5d7e68-ce18-4fcf-ac92-2f09a7cef42a" type="get"><ping xmlns='urn:xmpp:ping'/></iq>
2022-08-24T02:22:16.044838Z DEBUG XMPP    <<< <iq id='cdc728ba-42b0-4134-87fb-408602609ec2' xmlns='jabber:client' to='f61dd71f-63a5-4edf-a978-333bd9455482@meet.jit.si/MnFI49k3GZkC' from='meet.jit.si' type='result'><query xmlns='http://jabber.org/protocol/disco#info'><identity name='lobby.meet.jit.si' category='component' type='lobbyrooms'/><identity name='conferenceduration.meet.jit.si' category='component' type='conference_duration'/><identity name='Prosody' category='server' type='im'/><identity name='avmoderation.meet.jit.si' category='component' type='av_moderation'/><identity name='breakout.meet.jit.si' category='component' type='breakout_rooms'/><identity name='meet-jit-si-eu-frankfurt-1-s25' category='server' type='shard'/><identity name='eu-central-1' category='server' type='region'/><identity name='3201' category='server' type='release'/><identity name='speakerstats.meet.jit.si' category='component' type='speakerstats'/><feature var='urn:xmpp:extdisco:1'/><feature var='http://jabber.org/protocol/disco#info'/><feature var='http://jabber.org/protocol/disco#items'/><feature var='jabber:iq:roster'/><feature var='urn:xmpp:extdisco:2'/><feature var='urn:xmpp:ping'/><feature var='jabber:iq:version'/><feature var='http://jabber.org/protocol/commands'/></query></iq>
2022-08-24T02:22:16.045421Z DEBUG XMPP    >>> <iq xmlns='jabber:client' from="f61dd71f-63a5-4edf-a978-333bd9455482@meet.jit.si/MnFI49k3GZkC" id="e26e87d0-684b-4c34-b7a9-56ce9302e8fe" to="meet.jit.si" type="get"><services xmlns='urn:xmpp:extdisco:2'/></iq>
2022-08-24T02:22:16.048927Z DEBUG XMPP    <<< <iq xmlns='jabber:client' id='0b5d7e68-ce18-4fcf-ac92-2f09a7cef42a' to='f61dd71f-63a5-4edf-a978-333bd9455482@meet.jit.si/MnFI49k3GZkC' type='result'/>
2022-08-24T02:22:16.049246Z  WARN discovering external services failed: STUN/TURN will not work
2022-08-24T02:22:16.049785Z DEBUG XMPP    >>> <iq xmlns='jabber:client' id="94906c95-ab7c-4272-bcc2-fd47b68726d9" to="focus@auth.meet.jit.si/focus" type="set"><conference xmlns='http://jitsi.org/protocol/focus' machine-uid="8e5de365-aa1c-4714-9509-1fc3042b8554" room="bsdhd357@conference.meet.jit.si"><property name="stereo" value="false"/><property name="startBitrate" value="800"/></conference></iq>
2022-08-24T02:22:16.052554Z DEBUG XMPP    <<< <iq id='e26e87d0-684b-4c34-b7a9-56ce9302e8fe' xmlns='jabber:client' to='f61dd71f-63a5-4edf-a978-333bd9455482@meet.jit.si/MnFI49k3GZkC' from='meet.jit.si' type='result'><services xmlns='urn:xmpp:extdisco:2'><service host='meet-jit-si-turnrelay.jitsi.net' port='443' type='stun'/><service type='turn' restricted='1' host='meet-jit-si-turnrelay.jitsi.net' port='443' password='UWQjp4nF799O8P/CyYHfhTiy+aQ=' transport='udp' username='1661394136' expires='2022-08-25T02:22:16Z'/><service type='turns' restricted='1' host='meet-jit-si-turnrelay.jitsi.net' port='443' password='UWQjp4nF799O8P/CyYHfhTiy+aQ=' transport='tcp' username='1661394136' expires='2022-08-25T02:22:16Z'/></services></iq>
2022-08-24T02:22:16.069190Z DEBUG XMPP    <<< <iq xml:lang='en-US' id='94906c95-ab7c-4272-bcc2-fd47b68726d9' xmlns='jabber:client' to='f61dd71f-63a5-4edf-a978-333bd9455482@meet.jit.si/MnFI49k3GZkC' from='focus@auth.meet.jit.si/focus' type='result'><conference ready='true' room='bsdhd357@conference.meet.jit.si' xmlns='http://jitsi.org/protocol/focus' focusjid='focus@auth.meet.jit.si'><property value='false' name='authentication'/></conference></iq>
2022-08-24T02:22:16.069875Z DEBUG send_presence{self=JitsiConference { jid: FullJID(f61dd71f-63a5-4edf-a978-333bd9455482@meet.jit.si/MnFI49k3GZkC), config: JitsiConferenceConfig { muc: BareJID(bsdhd357@conference.meet.jit.si), focus: Full(FullJID(focus@auth.meet.jit.si/focus)), nick: "gst-meet", region: None, video_codec: "vp9", extra_muc_features: [], start_bitrate: 800, stereo: false, recv_video_scale_width: 1280, recv_video_scale_height: 720, buffer_size: 200 }, inner: Mutex { data: <locked> } } payloads=[Element { name: "x", namespace: "http://jabber.org/protocol/muc", prefixes: Prefixes(), attributes: {}, children: [] }, Element { name: "c", namespace: "http://jabber.org/protocol/caps", prefixes: Prefixes(), attributes: {"hash": "sha-1", "node": "https://github.com/avstack/gst-meet", "ver": "swMAgANtyBNi66ghGYklxmQQoAQ="}, children: [] }, Element { name: "c", namespace: "urn:xmpp:caps", prefixes: Prefixes(), attributes: {}, children: [Element(Element { name: "hash", namespace: "urn:xmpp:hashes:2", prefixes: Prefixes(), attributes: {"algo": "sha-256"}, children: [Text("G/kN7Lvb58mV9M0f+E0V9ctHF3+2rT5irZCuqldbjGU=")] })] }, Element { name: "stats-id", namespace: "jabber:client", prefixes: Prefixes(), attributes: {}, children: [Text("gst-meet")] }, Element { name: "jitsi_participant_codecType", namespace: "jabber:client", prefixes: Prefixes(), attributes: {}, children: [Text("vp9")] }, Element { name: "audiomuted", namespace: "jabber:client", prefixes: Prefixes(), attributes: {}, children: [Text("false")] }, Element { name: "videomuted", namespace: "jabber:client", prefixes: Prefixes(), attributes: {}, children: [Text("false")] }, Element { name: "nick", namespace: "http://jabber.org/protocol/nick", prefixes: Prefixes(), attributes: {}, children: [Text("gst-meet")] }]}: close time.busy=30.3µs time.idle=7.61µs
2022-08-24T02:22:16.070322Z DEBUG XMPP    >>> <presence xmlns='jabber:client' to="bsdhd357@conference.meet.jit.si/f61dd71f"><x xmlns='http://jabber.org/protocol/muc'/><c xmlns='http://jabber.org/protocol/caps' hash="sha-1" node="https://github.com/avstack/gst-meet" ver="swMAgANtyBNi66ghGYklxmQQoAQ="/><c xmlns='urn:xmpp:caps'><hash xmlns='urn:xmpp:hashes:2' algo="sha-256">G/kN7Lvb58mV9M0f+E0V9ctHF3+2rT5irZCuqldbjGU=</hash></c><stats-id>gst-meet</stats-id><jitsi_participant_codecType>vp9</jitsi_participant_codecType><audiomuted>false</audiomuted><videomuted>false</videomuted><nick xmlns='http://jabber.org/protocol/nick'>gst-meet</nick></presence>
2022-08-24T02:22:16.077095Z DEBUG XMPP    <<< <presence xmlns='jabber:client' xml:lang='en-US' to='f61dd71f-63a5-4edf-a978-333bd9455482@meet.jit.si/MnFI49k3GZkC' from='bsdhd357@conference.meet.jit.si/focus'><priority>0</priority><etherpad xmlns='http://jitsi.org/jitmeet/etherpad'>bsdhd357</etherpad><versions xmlns='http://jitsi.org/jitmeet'><component name='focus'>1.0.911</component></versions><conference-properties xmlns='http://jitsi.org/protocol/focus'><property value='true' key='support-terminate-restart'/></conference-properties><c ver='Lg0vhCNhxjoeKJi2/hukdsizNWA=' node='http://jitsi.org/jicofo' xmlns='http://jabber.org/protocol/caps' hash='sha-1'/><occupant-id xmlns='urn:xmpp:occupant-id:0' id='dHPo/7vOI5L1GrWBDUYAGwYs4HEW/9JXKgUx6Nfyjqk='/><x xmlns='http://jabber.org/protocol/muc#user'><item jid='focus@auth.meet.jit.si/focus' role='moderator' affiliation='owner'/></x></presence>
2022-08-24T02:22:16.077608Z DEBUG XMPP    <<< <presence xmlns='jabber:client' xml:lang='en' to='f61dd71f-63a5-4edf-a978-333bd9455482@meet.jit.si/MnFI49k3GZkC' from='bsdhd357@conference.meet.jit.si/f61dd71f'><c ver='swMAgANtyBNi66ghGYklxmQQoAQ=' node='https://github.com/avstack/gst-meet' xmlns='http://jabber.org/protocol/caps' hash='sha-1'/><c xmlns='urn:xmpp:caps'><hash algo='sha-256' xmlns='urn:xmpp:hashes:2'>G/kN7Lvb58mV9M0f+E0V9ctHF3+2rT5irZCuqldbjGU=</hash></c><stats-id>gst-meet</stats-id><jitsi_participant_codecType>vp9</jitsi_participant_codecType><audiomuted>false</audiomuted><videomuted>false</videomuted><nick xmlns='http://jabber.org/protocol/nick'>gst-meet</nick><occupant-id xmlns='urn:xmpp:occupant-id:0' id='TyqmYDsK4e7tghGa0ICmOm/2o5B25Iy3zuNoX/CvbuE='/><x xmlns='http://jabber.org/protocol/muc#user'><item jid='f61dd71f-63a5-4edf-a978-333bd9455482@meet.jit.si/MnFI49k3GZkC' role='moderator' affiliation='owner'/><status code='110'/></x></presence>
2022-08-24T02:22:16.078065Z DEBUG Joined MUC: bsdhd357@conference.meet.jit.si
2022-08-24T02:22:16.078346Z DEBUG XMPP    <<< <message xmlns='jabber:client' to='f61dd71f-63a5-4edf-a978-333bd9455482@meet.jit.si/MnFI49k3GZkC' from='conferenceduration.meet.jit.si'><json-message xmlns='http://jitsi.org/jitmeet'>{&quot;created_timestamp&quot;:1661307736000,&quot;type&quot;:&quot;conference_duration&quot;}</json-message></message>
2022-08-24T02:22:16.078646Z DEBUG XMPP    <<< <message xmlns='jabber:client' to='f61dd71f-63a5-4edf-a978-333bd9455482@meet.jit.si/MnFI49k3GZkC' from='bsdhd357@conference.meet.jit.si' type='groupchat'><subject/></message>
jbg commented 2 years ago

Please edit your post to paste your logs again surrounded by code tags (```) because otherwise a lot of the XMPP elements get parsed as formatting and so get removed.

The bolded lines are not too much of a problem. The first one is jiconop trying to give us some info earlier than the standard XMPP flow, which we just ignore and request later. The second one means TURN won't work, but you should still be able to at least see the participant join the conference, worst case you would just have no media.

chunsan commented 2 years ago

Please edit your post to paste your logs again surrounded by code tags (```) because otherwise a lot of the XMPP elements get parsed as formatting and so get removed.

The bolded lines are not too much of a problem. The first one is jiconop trying to give us some info earlier than the standard XMPP flow, which we just ignore and request later. The second one means TURN won't work, but you should still be able to at least see the participant join the conference, worst case you would just have no media.

Thanks, I have changed the code style, please check if there is any problems

jbg commented 2 years ago

gst-meet and your own participant might be hitting different shards. I'm not sure precisely what method meet.jit.si uses to select shards, but you can try adding ?room=bsdhd357 to the websocket URL.