server: port to unified ResultCode and 32-bit message header; update HelloAck & tests #1

Closed
justinmoon wants to merge 7 commits from demo/step-1 into master
justinmoon commented 2025-09-22 00:59:15 +12:00 (Migrated from github.com)

This PR updates mosaic-server to the latest mosaic-core protocol module and unifies error/result handling.

Key changes

  • Adopt 32‑bit length header at bytes [4..8] and QueryId at [2..3]; result‑bearing messages use byte[1] for ResultCode.
  • Replace HelloErrorCode with unified ResultCode in HelloAck and related flows.
  • Keep SUPPORTED_MAJOR_VERSION as u8 to match the new API; convert to u16 when stashing in ClientData.
  • Fix tests to expect result_code(); adjust malformed header mutation to byte[4].
  • Examples: client prints result_code() for SubmissionResult.
  • Cargo patch: points CI to justinmoon/mosaic-core#demo/step-1 to ensure compatibility during review.

Companion PR

Build & tests

  • cargo build && cargo test are green.
This PR updates mosaic-server to the latest mosaic-core protocol module and unifies error/result handling. Key changes - Adopt 32‑bit length header at bytes [4..8] and `QueryId` at [2..3]; result‑bearing messages use byte[1] for `ResultCode`. - Replace `HelloErrorCode` with unified `ResultCode` in `HelloAck` and related flows. - Keep `SUPPORTED_MAJOR_VERSION` as `u8` to match the new API; convert to `u16` when stashing in `ClientData`. - Fix tests to expect `result_code()`; adjust malformed header mutation to byte[4]. - Examples: client prints `result_code()` for `SubmissionResult`. - Cargo patch: points CI to `justinmoon/mosaic-core#demo/step-1` to ensure compatibility during review. Companion PR - mosaic-core: https://github.com/justinmoon/mosaic-core/pull/1 Build & tests - `cargo build && cargo test` are green.
justinmoon commented 2025-09-22 05:25:05 +12:00 (Migrated from github.com)

oops i meant to work against my local fork for a while ...

oops i meant to work against my local fork for a while ...

Pull request closed

Sign in to join this conversation.
No description provided.