diigo-cache: fill job — a button that grabs every page (goal 1e)

POST /_fill (cache id in the body; target private|public; action
start|stop) starts or stops a background walk of every diigo page into
the cache. DO alarms advance it pagesPerStep pages per step (default
20), a second apart; progress (FillStatus) is stored in the DO after
each page, so it survives eviction. Cached pages are skipped; starting
while running rejoins the job; a stop mid-step wins; a failure is
recorded with its reason and logged once. The created page gets fill
buttons; the public page shows "filling: n of m pages".

Fill state is new, additive DO storage (fill, fillStep): no existing
state changes meaning.

The 13 fill specs are unskipped and green, plus one: a fill makes one
diigo call per page fetched.

Generated-by: Claude Opus 5.5
This commit is contained in:
dckc committed 2026-10-07 04:25:38 -05:00
1 parent 530942f5d9
commit 31ded9735b
4 files changed
+182 -15

No files matched your search

+5
View File
@@ -33,6 +33,11 @@ goal 2 preamble).
outcome}`.
- **Publish later**: `POST /_publish` (cache id in the body) wires a
public companion to a private-only cache.
- **Fill job**: `POST /_fill` (cache id in the body; `target=private|public`,
`action=start|stop`) walks every diigo page into a cache in the
background — DO alarms, a few pages per step, progress stored in the
DO (`startFill`/`fillStatus`/`stopFill`). The created page has the
buttons; the public page shows progress.
- The `DiigoBridge` entrypoint for other workers (its cache-id source is
the goal-2 wiring TODO).