Closed Portevent closed 1 month ago
I think that having two packets is useful but not mandatory. The ack pkg is mainly here to ack that c1 has been added to the room. Even if a third client, c3, has access to the room id, it won't be able to use it because it is not referenced in the server. Tho this will really be useful once chat rooms will be implemented
Closing, feel free to open it back again
When client 2 accept the knock, client 1 recieve both a confirmation packet and a room id packet.
https://github.com/eTh3r-network/vapor/blob/1b91769cbcf09f1ae06f69cde860709c98d4bd51/PROTOCOL.md?plain=1#L39 https://github.com/eTh3r-network/vapor/blob/1b91769cbcf09f1ae06f69cde860709c98d4bd51/PROTOCOL.md?plain=1#L42
But we can assume that recieving a room id implies that c2 accepted the knock, thus making the confirmation request redudent when c2 accept. One request can be saved if we only forward c2 response when c2 refuses the knock.