Repository navigation
Closed
Description
Parent issue
Problem
The modern UPDATE binder currently falls back when:
- any column covered by an irregular index is updated; or
- the primary key changes on any table carrying an irregular index.
The legacy path performs inline delete+insert maintenance for synchronous FULLTEXT and IVF-FLAT indexes. It rejects PK updates when such a synchronous index exists because hidden rows are keyed by the old source PK (#25617). Async FULLTEXT/IVF-FLAT and always-async HNSW/CAGRA/IVF-PQ instead rely on ISCP CDC.
The migration must preserve this distinction. It must not introduce an SQL-layer list of algorithm names.
Required work
- Use plugin metadata (
SyncDescriptor) plus the index'sasyncparameter to select inline versus CDC maintenance. - Use the existing plugin rewrite contract (
UpdateColumnRewriteHook) for indexed/INCLUDE-column impact, extending an algorithm-agnostic plugin hook only if the modern DML plan needs more information. - For synchronous indexes, delete old hidden entries using the old PK/key identity and insert entries from the final updated row image.
- Skip inline work for unrelated columns.
- Preserve CDC-only behavior for async indexes without double maintenance.
- Keep PK updates on tables with synchronous irregular indexes explicitly rejected before mutation until a proven safe rewrite contract exists.
- Verify async PK-update behavior against CDC identity semantics before removing its current broad fallback.
- Keep base-row and synchronous hidden-table mutations in one atomic statement plan.
Acceptance criteria
- Updating a synchronous FULLTEXT or IVF-FLAT indexed/INCLUDE column uses the modern planner and produces correct old-entry deletion plus final-entry insertion.
- Updating an unrelated column produces no irregular-index rewrite.
- Async FULLTEXT/IVF-FLAT and always-async HNSW/CAGRA/IVF-PQ use CDC only and receive no duplicate inline writes.
- Synchronous-index PK updates fail before locks/mutations with a stable compatibility error unless safe support is implemented and tested.
- Async-index PK updates have an explicit tested disposition based on CDC behavior.
- Classification and rewrite decisions are plugin-driven; no new per-algorithm switch/if chain appears in SQL/catalog layers.
- Real, composite, and fake source PKs are covered.
- Indexed parts and INCLUDE columns are covered through plugin contracts.
- Failure, cancellation, retry, and rollback leave the base and synchronous hidden tables consistent.
- Supported cases no longer route to
buildTableUpdate.
Test matrix
- Synchronous and async FULLTEXT.
- Synchronous and async IVF-FLAT.
- Always-async HNSW controls; CAGRA/IVF-PQ controls under the appropriate GPU build/test coverage.
- Indexed part, INCLUDE column, and unrelated-column updates.
- Real, composite, and fake PKs; PK update accepted/rejected cases.
- Optimistic/pessimistic conflict, retry, cancellation, commit, and rollback.
- CPU-runnable unit coverage for generic plan/plugin decisions; GPU-tagged coverage where an algorithm is GPU-only.
Dependencies
- Parent: [Task]: Retire the legacy UPDATE planner and converge on MULTI_UPDATE #26336
- Uses [Subtask]: Inventory and instrument legacy UPDATE planner fallbacks #26337 telemetry.
- Must follow the index-plugin registry contract and avoid new algorithm-specific dispatch.
Activity
[-][Subtask]: Move synchronous vector/fulltext UPDATE maintenance to the modern planner[/-][+][Subtask]: Move synchronous irregular-index UPDATE maintenance to the modern planner[/+]