interface ShardChoser (View source)

Given a distribution value this shard-choser strategy will pick the shard to connect to for retrieving rows with the distribution value.

Methods

string|int
pickShard(string|int $distributionValue, PoolingShardConnection $conn)

Picks a shard for the given distribution value.

Details

string|int pickShard(string|int $distributionValue, PoolingShardConnection $conn)

Picks a shard for the given distribution value.

Parameters

string|int $distributionValue
PoolingShardConnection $conn

Return Value

string|int