Expand description
Event handler — gift wrap receive, unwrap, process, commit pipeline.
Two-phase architecture:
- Phase 1 (
prepare_event): Parallel-safe — dedup, unwrap, process_rumor - Phase 2 (
commit_prepared_event): Sequential — save DB, update STATE, emit
Platform-specific behavior (notifications) handled by InboundEventHandler trait.
Structs§
- NoOp
Event Handler - No-op handler for CLI/tests.
Enums§
- Prepared
Event - Result of Phase 1 (prepare_event) — everything needed for sequential commit.
Traits§
- Inbound
Event Handler - Platform-specific callbacks for inbound event processing.
Functions§
- commit_
prepared_ event - Phase 2: commit a prepared event (sequential — not parallel-safe). Saves to DB, updates STATE, emits to frontend, calls handler hooks. Returns true if a new displayable message was committed.
- prepare_
event - Phase 1: Prepare an event for commit (parallel-safe, no state mutation).
- process_
event - Process a single event through the full pipeline (prepare + commit).