Macro instant_flow_end

Source
macro_rules! instant_flow_end {
    (
        $category:expr,
        $event_name:expr,
        $flow_name:expr,
        $flow_id:expr
        $(, $key:expr => $val:expr)*
    ) => { ... };
}
Expand description

Convenience macro to emit the end of a flow attached to an instant event.

Flows must be attached to a duration event. This can be awkward when there isn’t an obvious duration event to attach to, or the relevant duration is very small, which makes visualizing difficult. This emits a flow event wrapped in a self contained instant event that is also easy to see in the tracing UI.

Example:

let flow_id = 1234;
instant_flow_end!(c"category", c"event", c"flow", flow_id, "x" => 5, "y" => "boo");