MultiTenantShardChoser
in package
implements
ShardChoser
The MultiTenant Shard choser assumes that the distribution value directly maps to the shard id.
Tags
Interfaces, Classes and Traits
- ShardChoser
- Given a distribution value this shard-choser strategy will pick the shard to connect to for retrieving rows with the distribution value.
Table of Contents
- pickShard() : int
- Picks a shard for the given distribution value.
Methods
pickShard()
Picks a shard for the given distribution value.
public
pickShard(mixed $distributionValue, PoolingShardConnection $conn) : int
Parameters
- $distributionValue : mixed
- $conn : PoolingShardConnection