pickRendezvous
pickRendezvous<
T>(key,candidates,identityOf):T
Defined in: src/cluster/router/ConsistentHashing.ts:27
Pick the candidate with the highest combined-hash for key.
candidates is iterated in order; ties are broken by first-occurrence
to keep behaviour deterministic given identical inputs.
Throws if candidates is empty — callers should check beforehand.
Type Parameters
Section titled “Type Parameters”T
Parameters
Section titled “Parameters”string
candidates
Section titled “candidates”readonly T[]
identityOf
Section titled “identityOf”(c) => string
Returns
Section titled “Returns”T