pub fn extract_routing_field(
payload: &[u8],
field_name: &str,
) -> PreRouteExtractionAvailable on crate feature
worker-batch and (crate features worker-batch or worker-pool or worker) only.Expand description
Extract a routing field from raw JSON bytes using SIMD.
Uses sonic_rs::get_from_slice for zero-copy extraction. The error path
(distinguishing a missing field from invalid JSON) requires a full
validity check and is intentionally cold.
§Behaviour
Ok(lazy_value)and value is a string →Found(string)Ok(lazy_value)and value is not a string →Found(raw_str)(raw JSON)Errwithis_not_found()→MissingErrother →ParseError