photon-macros 0.1.1

Proc macros for Photon pub/sub (#[photon::topic], #[photon::subscribe])
Documentation

photon-macros

Proc macros for typed Photon topics and handlers.

Entry points

Macro Purpose
topic Register a typed topic struct; generates publish_on / publish, subscribe_on / subscribe
subscribe Register an async handler for executor dispatch

Prefer handle-first APIs (publish_on(&photon), subscribe_on(&photon, opts)). configure + .publish() / .subscribe() remain optional sugar for a process-wide default.

Requires #[photon::topic] and Photon::start_executor at boot for inventory handlers. Attribute reference: docs.rs photon::config — proc macros. Expansion behavior: docs/macro-expansion.md.

Runnable examples: cargo run -p uf-photon --example embedded_mem --features runtime,mem (set PHOTON_TRANSPORT_KEY; see example comments).

API reference: cargo doc -p photon-macros --open.