pub type CallHandler = Arc<dyn Fn(Value) -> BoxFuture<'static, Result<Value, String>> + Send + Sync>;Expand description
Answers one inbound CALL. Ok(payload) sends a RESULT; Err(reason)
sends an ERROR (BOLT#4 unknown_error, detail = reason); a panic
inside the handler (caught via tokio::spawn, the same “one
transient task per call” shape macula_station_link.erl uses one
process per call for) is sent as ERROR temporary_relay_failure —
matching that module’s own safe_invoke_handler/4 mapping exactly
(including sending no detail on a crash, since the reference
doesn’t either — it only logs locally).
Aliased Type§
pub struct CallHandler { /* private fields */ }