Patch Changes
-
Recover persisted on-demand Electric and Query collections after cache claim loss by rotating their SQLite cache and reloading active subsets. Fence retired provider work and expired claims, preserve warm runs on their claimed cache generation, and forward claim lifetime options through SQLite host factories. Require explicit eager or claim-bound managed targets for SQLite adapter data operations, and forward them through Electron IPC protocol v6. Bare collection IDs no longer work at this lower-level adapter boundary. (#2069)
-
Prevent direct writes from automatically refetching active Query subsets. On-demand writes patch changed keys already present in active raw arrays or directly selected response arrays, except when the Query is shared with another Collection. Eager writes patch representable rows in a shared Query cache, so Collections using the same Query project those edits. In both modes, cache patches preserve Query error, invalidation, and freshness state; an idle eager cache seed moves from pending to success without advancing its freshness timestamp. Direct writes no longer clear a prior fetch error or mark stale data fresh. Older in-flight or queued results cannot undo an accepted write, and derived cache responses are not replayed over it on resubscribe. A later-started successful subset fetch controls a shared row's value over an older request that settles afterward. Callers choose when to request current server rows; a complete matching on-demand result can remove an omitted ownerless direct row. Query Core 5.90.15 or later is required for post-write refetch replacement and error-state recovery. (#2065)
An eager Collection that later joins a Query patched by another eager Collection projects the cached edit without starting a request, including when disabled. An on-demand Collection still revalidates an unverified cache edit before accepting it for a subset. A fresh persisted Collection refetches on a cached-row collision when it cannot recover the order of its stored direct write and that Query result.
Inactive Query entries under the Collection key prefix may be removed after a direct write. A physical Query whose stored key is outside that prefix remains in the cache, even when a custom hash aliases it with a Collection key; callers can explicitly evict or refetch that entry. -
A completed, active full-source Query Collection load can now serve later (#2135)
filtered or windowed live queries when the collection uses a static query key.
The narrower queries retain the full Query until their final owner releases,
so the original full view can unmount without dropping their rows or stopping
later invalidation updates. Incomplete full loads and explicit subset refetches
keep their own request paths. A narrower scope with retained persisted ownership
makes an exact request to revalidate its rows and owners. -
Updated dependencies [
cda9d6a,2f928e6,dfec42e,1a65c2c,1b4ee8d,bbbf017,bc6f30e,fade2e2,bbe9327,b34a579,6fa60aa,f84387c,be4a3d6,0dc696a,fd13e3c]:- @tanstack/db@0.14.0