-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Race condition may cause JitsiConference.prototype._doReplaceTrack to hang forever #2370
Comments
This sounds about right! |
athouary
pushed a commit
to athouary/lib-jitsi-meet
that referenced
this issue
Oct 11, 2023
…itsi#2370) This ensures that promises relying on the task callback will settle.
athouary
pushed a commit
to athouary/lib-jitsi-meet
that referenced
this issue
Oct 11, 2023
This ensures that promises relying on the task callback will settle.
athouary
pushed a commit
to athouary/lib-jitsi-meet
that referenced
this issue
Oct 12, 2023
athouary
pushed a commit
to athouary/lib-jitsi-meet
that referenced
this issue
Oct 16, 2023
athouary
pushed a commit
to athouary/lib-jitsi-meet
that referenced
this issue
Oct 16, 2023
athouary
added a commit
to athouary/lib-jitsi-meet
that referenced
this issue
Dec 5, 2023
athouary
added a commit
to athouary/lib-jitsi-meet
that referenced
this issue
Dec 6, 2023
athouary
added a commit
to athouary/lib-jitsi-meet
that referenced
this issue
Dec 6, 2023
saghul
pushed a commit
that referenced
this issue
Dec 14, 2023
subhamcyara
pushed a commit
to subhamcyara/lib-jitsi-meet
that referenced
this issue
Jul 19, 2024
subhamcyara
pushed a commit
to subhamcyara/lib-jitsi-meet
that referenced
this issue
Jul 19, 2024
subhamcyara
pushed a commit
to subhamcyara/lib-jitsi-meet
that referenced
this issue
Jul 19, 2024
subhamcyara
pushed a commit
to subhamcyara/lib-jitsi-meet
that referenced
this issue
Jul 19, 2024
subhamcyara
pushed a commit
to subhamcyara/lib-jitsi-meet
that referenced
this issue
Jul 19, 2024
subhamcyara
pushed a commit
to subhamcyara/lib-jitsi-meet
that referenced
this issue
Jul 19, 2024
subhamcyara
pushed a commit
to subhamcyara/lib-jitsi-meet
that referenced
this issue
Jul 19, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Description
I consume
lib-jitsi-meet
in a custom user interface to connect and use a self-hosteddocker-jitsi-meet
. I've encountered some cases where the promise returned byJitsiConference.addTrack
is pending forever, and after long researches, I've finally understood why.The
JitsiConference.prototype._doReplaceTrack
promise resolves once thereplaceTrack
on all the existing Jingle Session (P2P and/or JVB) resolve.JingleSessionPC
relies onAsyncQueue
and pushes thereplaceTrack
call into it. In some rare case, when a 3rd user joins the conference and it goes from P2P to JVB, then the P2P JingleSession closes and the AsyncQueue is killed. This results in thereplaceTrack
to be pending forever.Current behavior
A call to
JitsiConference.addTrack
orJitsiConference.replaceTrack
may hang forever if the conference goes from P2P to JVB in the mean time.Expected Behavior
The promises returned by those functions should either be resolved or rejected. Actually, it should most probably resolve and ignore the P2P session since it's not relevant anymore.
Possible Solution
We should probably call the all the pending task callbacks when killing an AsyncQueue, with a specific error that
replaceTrack
would catch. It would then resolve its promise (it seems ok not to manage to replace a track on a non-existing peer connection).A more simple but dirtier solution would be to reject the promise after a timeout.
Steps to reproduce
Environment details
Reproduced on (non-exhaustive):
lib-jitsi-meet
v1699.0.0+683dc0fb
docker-jitsi-meet
stable-8960
The text was updated successfully, but these errors were encountered: