Skip to content

only drop text and binary message when pressure, control message such as ping pong and close message should not be drop#1876

Open
gubaojian wants to merge 1 commit intouNetworking:masterfrom
gubaojian:feature_improve_drop
Open

only drop text and binary message when pressure, control message such as ping pong and close message should not be drop#1876
gubaojian wants to merge 1 commit intouNetworking:masterfrom
gubaojian:feature_improve_drop

Conversation

@gubaojian
Copy link
Contributor

code in uwebsockets such send ping or send pong or send close, not check the drop status. which will lead to control message lose when backpressure. the pr will fix this and only drop text or binary message when backpressure

…h as ping pong and close message should not be drop
@uNetworkingAB
Copy link
Contributor

Why would control messages be exempt from backpressure logic? Control messages are not critically important, most of them are simple pings or pongs or close frames.

If you've reached the maxBackpressure, that's it. It will drop.

@gubaojian
Copy link
Contributor Author

gubaojian commented Jul 4, 2025

Why would control messages be exempt from backpressure logic? Control messages are not critically important, most of them are simple pings or pongs or close frames.

If you've reached the maxBackpressure, that's it. It will drop.

some ws client use ping pong to keep alive. client send ping, server return pong.
if client send ping, not receive pong, it will assume connection lost. when server handle lot of message in backpressure, connection is ok, but pong be dropped. client not not receive pong, client will assume connection be dead. connection will be close by client. this behavior is not right.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants