Gatherer

A package fact collector exporting gather(params) -> Value, bound into a playbook variable.

A gatherer is a package-declared fact collector, implemented by a wscript script that exports `gather(params: Value) -> Value. A playbook gather "label" { from = "pkg.gatherer" }` block invokes one and binds its result to the variable named by the label (e.g. os.family).

§ 1Example

rust
use value
use sys

fn gather(params: Value) -> Value {
    Value::Map(#{
        "family": Value::String(sys::family()),
        "name": Value::String(sys::os_name()),
        "cpus": Value::Int(sys::cpu_count())
    })
}

Gatherer invocations all run concurrently and are deduplicated by (gatherer, canonicalized params); any gatherer failure aborts the run before step execution. See Variables for how results enter scope.