Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion .github/workflows/atlas-search-worker-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ name: atlas-search worker tests
# The atlas-search cache Worker's vitest suite — pkgs/atlas-search/
# worker/test/ (key.test.ts: query canonicalisation + the DO cache-key
# digest oracle; space.test.ts: validateEmbed embedding-space pins;
# measurement.test.ts: the #13107 D1 hot-cache §7 counters + report
# renderer against the #9134 design §7 oracle;
# worker.test.ts: auth gate, DO cache hit, the #6937 whitespace-query
# and #6982 null-search-response regressions) — was run by no
# workflow, flake check, or justfile recipe, only by hand via npm test.
Expand Down Expand Up @@ -50,7 +52,7 @@ jobs:
- name: Run the atlas-search worker vitest suite
working-directory: pkgs/atlas-search/worker
run: |
for f in test/key.test.ts test/space.test.ts test/worker.test.ts package.json package-lock.json; do
for f in test/key.test.ts test/space.test.ts test/measurement.test.ts test/worker.test.ts package.json package-lock.json; do
if [ ! -f "$f" ]; then
echo "::error::pkgs/atlas-search/worker/$f is missing — the worker suite was not run."
exit 1
Expand Down
10 changes: 8 additions & 2 deletions pkgs/atlas-search/worker/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,12 @@ and caches the result **indefinitely** (no TTL/eviction in v1).
revision, vector table, and k. A cached entry is never served
across ceilings, disclosure contexts, or embedding spaces;
entries keyed under schema v1 are orphaned, never served.
- `src/measurement.ts` — the D1 hot-cache measurement report
(#13107; design #9134 §7): the §7 counters (hits, skips,
revalidations per class and tenant; stale_serves, expected
zero; estimated Turso cost avoided; D1 bytes per tenant vs
quota) rendered as a report for #9098's economics prototype.
Pure accumulator + renderer, fed by the read path (follow-on 4).

## Endpoints

Expand Down Expand Up @@ -82,8 +88,8 @@ wired into the request path at all: nothing in the Worker calls
it outside tests, so the flag alone does not activate the cache —
with the flag on and the binding present, the Worker still never
touches D1 and the read path is unchanged. Freshness
(#13101), admission/eviction (#13103), and read-path integration
(#13105) are separate follow-ons. The committed `database_id` is a
(#13101), admission/eviction (#13103), measurement (#13107),
and read-path integration (#13105) are separate follow-ons. The committed `database_id` is a
local placeholder: the real `atlas-hot-cache` database is created at
deploy time and its id replaces the placeholder in both
`wrangler.toml` and `cloudflare.config.ts`.
Expand Down
Loading