Implements plan §13.1 step 1: create shadow index {uid}__reshard_{S_new}
on every node and propagate live index settings via two-phase broadcast
(§13.5).
Key changes:
- Add ShadowCreateResult struct to return creation results
- Add ShadowCreateError enum for failure handling
- Implement shadow_create_phase() function that:
1. Creates shadow index sequentially on all nodes
2. Fetches live index settings
3. Ensures _miroir_shard is in filterableAttributes
4. Runs two-phase settings broadcast
5. Rollback on any failure (shadow not client-addressable yet)
- Add helper functions: create_index_on_node, fetch_index_settings,
ensure_shard_filterable, two_phase_broadcast_settings, rollback_shadow_index
- Add unit tests for shadow create phase
Acceptance criteria:
- Shadow index created on every node with new shard count
- Settings propagated via two-phase broadcast
- Rollback on failure (invisible to clients)
Closes: miroir-uhj.1.1
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
|
||
|---|---|---|
| .. | ||
| miroir-core | ||
| miroir-ctl | ||
| miroir-proxy | ||