You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This was brought up on IRC a little while ago, but the discussion died down rapidly and I noticed it wasn't mentioned anywhere here. I'm filing this so it isn't forgotten and mostly summarising the discussion from June.
The current client-batch spec draft states that:
Once a client has opened a batch, it MUST NOT send any messages that are not part of the batch, until it is closed (with BATCH -reference-tag).
What happens if the client receives a PING while sending a batch? The above means that it can't send the PONG until the client batch is done, which might take longer than the ping timeout. The server would have to account for this in some way. One strategy is to treat any message from the client as a PONG equivalent with regards to ping timeouts (Ergo does this). However, this is definitely not universal. Many real-world servers in fact explicitly do not do that, and timing out while sending lots of messages is not unusual. For that reason, non-trivial clients usually have a message queue and bypass the queue for sending PONGs, but that'd break the client-batch requirement above.
The obvious simple solution would be to permit PONG in the middle of client batches. Another approach would be to prescribe that, at least while a client batch is active, the server must behave as described above, i.e. treat the receipt of any client message as a PONG if it is waiting for one. But that seems a lot messier to me.
The text was updated successfully, but these errors were encountered:
This was brought up on IRC a little while ago, but the discussion died down rapidly and I noticed it wasn't mentioned anywhere here. I'm filing this so it isn't forgotten and mostly summarising the discussion from June.
The current client-batch spec draft states that:
What happens if the client receives a
PING
while sending a batch? The above means that it can't send thePONG
until the client batch is done, which might take longer than the ping timeout. The server would have to account for this in some way. One strategy is to treat any message from the client as aPONG
equivalent with regards to ping timeouts (Ergo does this). However, this is definitely not universal. Many real-world servers in fact explicitly do not do that, and timing out while sending lots of messages is not unusual. For that reason, non-trivial clients usually have a message queue and bypass the queue for sendingPONG
s, but that'd break the client-batch requirement above.The obvious simple solution would be to permit
PONG
in the middle of client batches. Another approach would be to prescribe that, at least while a client batch is active, the server must behave as described above, i.e. treat the receipt of any client message as aPONG
if it is waiting for one. But that seems a lot messier to me.The text was updated successfully, but these errors were encountered: