GraphReFlyTS

API Reference

reactiveCascadingCache()

Free-standing graph-layer cascading cache factory (D104/D105/D107).

Passive tiers stay in tieredReadThrough; this factory wraps lookup work at an async pool boundary and exposes every request, invalidation, lookup, promotion, fill, status, and value change through declared graph nodes. requestSeq is the stale-fill guard for visible graph nodes: older async fills may still be observable as events, but downstream value/status nodes ignore them. Storage promotion defaults to false here because passive tier writes have no generation/CAS contract; callers may opt in with promoteTo when best-effort promotion is acceptable.

Import

import { reactiveCascadingCache } from "@graphrefly/ts/graph";

Signature

function reactiveCascadingCache(opts: ReactiveCascadingCacheOptions<K, V>): ReactiveCascadingCache<K, V>

Parameters

ParameterTypeDescription
optsReactiveCascadingCacheOptions<K, V>Options that configure the helper.

Returns

A ReactiveCascadingCache<K, V> value.

Example

import { reactiveCascadingCache } from "@graphrefly/ts/graph";

Source

packages/ts/src/graph/cascading-cache.ts