diff --git a/sidecar/src/main.rs b/sidecar/src/main.rs index 050d5fd..779b18c 100644 --- a/sidecar/src/main.rs +++ b/sidecar/src/main.rs @@ -103,9 +103,24 @@ use tracing_subscriber::EnvFilter; /// rollback as well. `web::CONFIG_RELOAD_WINDOW` is that budget, mirrored from the plugin, and a /// test asserts the pairing rather than trusting it. /// +/// # Protocol 6 — first-party clans +/// +/// One board (`clans`) and five events (`clan.created`, `clan.disbanded`, `clan.member.added`, +/// `clan.member.left`, `clan.member.kicked`), from which the website builds core's Teams (R5). +/// +/// **Nothing in this process changed except this number**, and that is protocol 2's promise +/// kept: the board is filed by `type: "snapshot"` and the events by `type: "event"`, so the +/// sidecar needs no arm for any of them. The bump exists for the other two declaration sites — +/// a website that reads clans must not pair with a plugin that never sends them. +/// +/// One property of this process does bear on the board: [`game::MAX_INBOUND_LINE_BYTES`] +/// discards a line over 1 MiB outright. The plugin bounds the board well inside it and says +/// `truncated` when it had to stop, because a board that never arrived would read as a server +/// with no clans. +/// /// `docs/rust-link/PROTOCOL.md` is the specification — §8 the read path, §9 identity, §10 the -/// mirror, §11 configuration; this constant is one of its four declaration sites. -pub const PROTOCOL_VERSION: u32 = 5; +/// mirror, §11 configuration, §12 clans; this constant is one of its four declaration sites. +pub const PROTOCOL_VERSION: u32 = 6; fn main() -> anyhow::Result<()> { let args = match cli::parse(std::env::args().skip(1)) {