Shard
Deterministic partitioning of state
Mechanism
The fundamental primitive of distribution. It deterministically partitions a Resource, State, or Vector into disjoint subsets (Shards) based on a Key (e.g., ID, Hash, Time). Unlike Decompose, which splits complexity, Shard splits volume and load.
Invariants
- Conservation: Sum(Shards) == Total.
- Disjointness: Intersection(Shard_A, Shard_B) == Empty.
- Determinism: Key K always routes to Shard S.
Parameters
- key_function: type=Enum, range={Hash, Range, Directory}, description=Partitioning strategy for distributing data across shards
- partitions: type=Integer, range=[2, 256], description=Number of partitions to divide state into
Failure modes
- Hot shard: skewed keys concentrate load on one partition — a consequence of Determinism.
- Rebinding on resize: changing the partition count invalidates every routing decision taken under the old count.
- Cross-shard operation: spanning shards requires coordination, because Disjointness guarantees no shard holds another's data.
Where this came from
—
Builds on
- Conservation references
- Vector references
- Resource references
- State references
- Decompose references
Used by
- ExperienceSharding references
- FabricSharding references
Identity
- Ref:
Shard#4d41 - Hash: sema:Shard#mh:SHA-256:4d41232416e3d414c714e0892e8559c2180899b4c21c25af29984372220f8704
- Library: bootstrap 0.11.0, root a6a3d1ff0f98
- License: Not stated; check the repository