fix(rivetkit): remove client-side connection request size check#5057
fix(rivetkit): remove client-side connection request size check#5057abcxff wants to merge 1 commit into
Conversation
|
🚅 Deployed to the rivet-pr-5057 environment in rivet-frontend
|
This stack of pull requests is managed by Graphite. Learn more about stacking. |
Code ReviewOverviewThis PR removes the client-side message size enforcement for WebSocket IssuesDead code —
const DEFAULT_MAX_INCOMING_MESSAGE_SIZE = 65_536;The only place that consumed it was the removed check. This constant should be deleted in this PR. Behavioral regression — connection closed vs. action rejected The previous client-side path rejected only the specific in-flight action (calling if message.data.len() > max_incoming_message_size {
message.sender.close(Some(1011), Some("message.incoming_too_long".to_owned()));
return;
}Any other in-flight actions on the same connection will also fail when a single oversized message is sent. If the intent is to match server semantics (connection close), the test should assert that the connection is unusable after the rejection rather than just calling Bandwidth waste for oversized messages Previously the message was serialized and checked but not sent if too large. Now the full serialized payload (~90 KB in the test case) is sent over the wire before the server closes the connection. Consider whether a lightweight client-side pre-flight size check should remain to avoid the unnecessary round trip for clearly oversized messages. Misleading PR title "revert remove client-side connection request size check" is a double-negative and ambiguous — it reads as "undo the removal" (add the check back) but this PR actually removes the check. A clearer title: Nits
SummaryServer-side enforcement is confirmed correct ( |
|
picking up from #5055 |

Description
Please include a summary of the changes and the related issue. Please also include relevant motivation and context.
Type of change
How Has This Been Tested?
Please describe the tests that you ran to verify your changes.
Checklist: