Security & Sync
/
Local Iceberg Cache
Local Iceberg Cache
Cache the database's own Iceberg files on the device — not a second database.
View as Markdown
llms.txt
The database is a set of Iceberg files on object storage, and the WASM engine already reads those exact files. So the client cache is not a new database — it is a byte cache of warehouse objects, sitting transparently underneath the engine.
How it works
Immutable files cached forever — Parquet and metadata objects never change, so they cache indefinitely.
One pointer read to revalidate — a single read of the table pointer tells the cache whether a table changed.
Namespaced per identity — on IndexedDB (web) or any key-value engine (React Native), keyed by Cognito sub.
Revocation-driven deletion
Because every cached byte is tagged with the identity that fetched it, revoking access has a precise consequence: every locally persisted byte that access fetched is deleted. There is no orphaned copy in a second store because there is no second store.
app/_layout.tsx
tsx · copy
1
import
{
RAStackProvider
}
from
"rastack/provider"
;
2
3
// The cache lives under the provider; it is transparent to your hooks.
4
<
RAStackProvider
mode
=
"local"
>
5
<
App
/>
6
</
RAStackProvider
>
Tip
The cache lives in tools/cache and ships as rastack/cache. Your hooks never touch it directly — it sits beneath the engine.
Build with AI
Every page is available as clean Markdown for LLMs and coding agents. Point one at the files below to build on top of React API Stack.
React API Stack · alpha · built to scale to millions