I see there is currently a todo comment there
|
// if this user is entirely disconnected, notify their roommates. |
|
// todo: is it better if this is instead when their publisher disconnects? |
|
if !switchboard.is_connected(&joined.user_id) { |
|
let response = json!({ "event": "leave", "user_id": &joined.user_id, "room_id": &joined.room_id }); |
|
let occupants = switchboard.publishers_occupying(&joined.room_id); |
|
notify_except(&response, &joined.user_id, occupants); |
|
} |
I had an issue with naf-janus-adapter master (see issue networked-aframe/naf-janus-adapter#21) where the js code can now triggers duplicate avatar on reconnect because of this part of the code I think because the users could possibly never receive the leave event. This is my hypothesis, I don't have proof that the leave event was not send when the issue occurred.
I currently don' plan to investigate this further, just wanted to document it. I currently reverted back to naf-janus-adapter 3.0.x in production.
I see there is currently a todo comment there
janus-plugin-sfu/src/lib.rs
Lines 336 to 342 in ef815ec
I had an issue with naf-janus-adapter master (see issue networked-aframe/naf-janus-adapter#21) where the js code can now triggers duplicate avatar on reconnect because of this part of the code I think because the users could possibly never receive the
leaveevent. This is my hypothesis, I don't have proof that theleaveevent was not send when the issue occurred.I currently don' plan to investigate this further, just wanted to document it. I currently reverted back to naf-janus-adapter 3.0.x in production.