effect-io-ai

Package: effect
Module: HashRing

HashRing.get

Gets the node which should handle the given input. Returns undefined if the hashring has no elements with weight.

When to use

Use to route a single string input key to the current ring member responsible for that key.

See

Signature

declare const get: <A extends PrimaryKey.PrimaryKey>(self: HashRing<A>, input: string) => A | undefined

Source

Since v3.19.0