1 realtime bootstrap wire sections and compression
forgejo-actions edited this page 2026-07-13 19:45:35 +00:00

Realtime Bootstrap Wire Sections And Compression

Realtime bootstrap wire sections describe how initial session state is split into ordered, typed, optionally compressed envelopes before the client reducers consume it.

Contract Families

Bootstrap section descriptors own section kind, message kind, sequence, presence rule, reducer, and default priority. The assembler builds section envelopes from server state, and the wire codec decides whether a section travels inline or as a compressed envelope.

Required sections must be present for a valid bootstrap. Optional sections such as combat or farming appear only when the zone and player state need them.

Version Fields And Defaults

Section kinds and reducer expectations are wire contracts. Unknown future section kinds or compression modes must fail clearly. Default priority affects delivery order and should be changed only when client reducer dependencies also change.

Compatibility Rules

Do not change a section message id or reducer meaning in place. Add a new section descriptor or compatibility path. Compression negotiation must be honored before sending compressed envelopes. Missing required envelopes, wrong section message ids, and unsupported compression modes are protocol failures.

Adding Fields Safely

Add fields to the section payload with serde/protobuf compatibility in mind, then update the descriptor, assembler, decoder, reducer coverage, generated docs, and bootstrap tests. If a new section is optional, define when it is absent and how the client should default.

Test Checklist

Cover section ordering, required/optional presence, compressed envelopes, unsupported compression modes, reducer decode coverage, and server snapshot assembly.