pub fn preferred_node_order(
placement: &NamespacePlacement,
) -> Vec<Option<String>>Expand description
The ordered node-filter tiers an UNPINNED row consults for the Prefer{L}
two-tier spill (Control-Plane Phase 2, P2-P3) — the SINGLE source of the
prefer-then-spill sequence consulted by
WorkerOutboxDispatch, which since
#52 R4 selects for BOTH transports — so “prefer labelled worker, spill to
any” cannot mean two things, because only one walk derives it.
The returned sequence is a list of node filters to try IN ORDER, stopping at the first that has a live worker:
Prefer{L}→ each label inL(deterministicBTreeSetorder) asSome(label), then a finalNonespill tier (any live worker). An emptyLcollapses to just theNonespill.Unplaced→ a singleNonetier (any live worker).
Pinned{L} is NOT dispatched through this fn: worker_selection_for routes it
to the NON-spilling WorkerSelection::Required decision (require an L-labelled
worker, WAIT on absence, never spill — P2-I1, #164). The Pinned arm here is only
the internal fall-through of the soft Prefer path and never satisfies a hard pin.
This is consulted ONLY for an unpinned row (row.node == None): an authored
Some(N) pin is authoritative and never enters this path. The result is a
pure worker-SELECTION input; it never mutates the recorded row’s node
(the determinism invariant, CP-Phase-2 §2.4).