Skip to main content

running_process/broker/protocol/
mod.rs

1//! v1 broker protocol module.
2//!
3//! Phase 0 of #228 introduced the prost-generated wire types from
4//! `proto/broker_v1_*.proto`. Phase 1 (#230) adds the framing
5//! read/write helpers used by every connection.
6//!
7//! All three .proto files share the `running_process.broker.v1`
8//! package, so prost-build emits a single Rust module containing
9//! every message and enum (Frame, Hello, HelloReply, Refused,
10//! Negotiated, AdminRequest, AdminReply, CacheManifest, ServiceDefinition,
11//! LifecycleEvent, ...).
12//! The prost-generated types are re-exported at the top of this
13//! module so existing call sites importing them under
14//! `running_process::broker::protocol::*` keep working.
15
16#[allow(missing_docs)]
17mod prost_generated {
18    include!(concat!(env!("OUT_DIR"), "/running_process.broker.v1.rs"));
19}
20
21pub use prost_generated::*;
22
23pub mod framing;
24
25pub use framing::{
26    read_frame, read_frame_with_cap, write_frame, FramingError, ENVELOPE_VERSION, MAX_FRAME_BYTES,
27    MAX_HELLO_BYTES,
28};