feat(web): resolve pending thumbnails via targeted thumbnails_ready SSE event #949

Merged
chris merged 1 commit from feat/thumbnail-sse-web into main 2026-09-28 23:25:18 +02:00
Owner

Summary

  • Frontend half of thumbnails_ready (backend: feat/thumbnail-sse-ready-events).
  • AppShell parses thumbnails_ready {"mediaItemIds":[...]} defensively (malformed payloads ignored) into a new thumbnailReadyIds store.
  • Pending thumbnails whose media item ID appears in the batch probe immediately (cache-busted swap) instead of waiting for their 6s timer; URLs without a media item segment keep the timer fallback. 6s/10-attempt budget and 60s summary poll unchanged as resilience for missed events.
  • Grid metadata refresh (thumbnailRefresh) also triggers on the event (pending-count gate + 500ms debounce preserved).

Verification

  • npm test -- tests/thumbnail-ready-sse.spec.ts tests/thumbnail-retry-budget.spec.ts green (4/4; new spec proves targeted immediate swap with frozen clock: malformed payloads inert, only addressed ID probes, second batch resolves the other spinner)
  • npm run build + npm run check green
## Summary - Frontend half of `thumbnails_ready` (backend: `feat/thumbnail-sse-ready-events`). - AppShell parses `thumbnails_ready {"mediaItemIds":[...]}` defensively (malformed payloads ignored) into a new `thumbnailReadyIds` store. - Pending thumbnails whose media item ID appears in the batch probe immediately (cache-busted swap) instead of waiting for their 6s timer; URLs without a media item segment keep the timer fallback. 6s/10-attempt budget and 60s summary poll unchanged as resilience for missed events. - Grid metadata refresh (`thumbnailRefresh`) also triggers on the event (pending-count gate + 500ms debounce preserved). ## Verification - `npm test -- tests/thumbnail-ready-sse.spec.ts tests/thumbnail-retry-budget.spec.ts` green (4/4; new spec proves targeted immediate swap with frozen clock: malformed payloads inert, only addressed ID probes, second batch resolves the other spinner) - `npm run build` + `npm run check` green
feat(web): resolve pending thumbnails via targeted thumbnails_ready SSE event
Some checks failed
Wiki Sync / Sync wiki from docs (push) Has been skipped
Build and Deploy / Detect changed services and test scopes (push) Successful in 10s
Build and Deploy / Android unit tests and debug APK (push) Has been skipped
Build and Deploy / Smoke API and media worker (push) Has been skipped
Build and Deploy / Smoke web (push) Has been skipped
Build and Deploy / Smoke ML worker (push) Has been skipped
Build and Deploy / Smoke people worker (push) Has been skipped
Build and Deploy / Build postgres image (push) Has been skipped
Build and Deploy / Build plants worker image (push) Has been skipped
Build and Deploy / Build converter worker image (push) Has been skipped
Build and Deploy / Deploy postgres (push) Has been skipped
Build and Deploy / Build API image (push) Has been skipped
Build and Deploy / Build media worker image (push) Has been skipped
Build and Deploy / Build ML worker image (push) Has been skipped
Build and Deploy / Build people worker image (push) Has been skipped
Build and Deploy / Build web image (push) Has been skipped
Build and Deploy / Deploy API (push) Has been skipped
Build and Deploy / Deploy web (push) Has been skipped
Build and Deploy / Deploy media worker (push) Has been skipped
Build and Deploy / Deploy ML worker (push) Has been skipped
Build and Deploy / Deploy plants worker (push) Has been skipped
Build and Deploy / Deploy people worker (push) Has been skipped
Build and Deploy / Deploy converter worker (push) Has been skipped
Build and Deploy / Clean Docker build artifacts (push) Has been skipped
Build and Deploy / Run scoped PR tests (push) Failing after 35m8s
469330778f
Replace the blind global retry bump with a targeted push: the new
thumbnails_ready SSE event carries explicit media item IDs, and only the
spinners whose ID appears in the payload probe immediately (retryNow path,
cache-busted swap on success). The 6s/10-attempt timer fallback and the
legacy global-signal short-circuit stay for missed events and URLs without
a derivable media item ID. thumbnailRefresh also triggers on the event
(unchanged pending-count gate and 500ms debounce) so grid metadata
refreshes after targeted replacement.
chris force-pushed feat/thumbnail-sse-web from 469330778f
Some checks failed
Wiki Sync / Sync wiki from docs (push) Has been skipped
Build and Deploy / Detect changed services and test scopes (push) Successful in 10s
Build and Deploy / Android unit tests and debug APK (push) Has been skipped
Build and Deploy / Smoke API and media worker (push) Has been skipped
Build and Deploy / Smoke web (push) Has been skipped
Build and Deploy / Smoke ML worker (push) Has been skipped
Build and Deploy / Smoke people worker (push) Has been skipped
Build and Deploy / Build postgres image (push) Has been skipped
Build and Deploy / Build plants worker image (push) Has been skipped
Build and Deploy / Build converter worker image (push) Has been skipped
Build and Deploy / Deploy postgres (push) Has been skipped
Build and Deploy / Build API image (push) Has been skipped
Build and Deploy / Build media worker image (push) Has been skipped
Build and Deploy / Build ML worker image (push) Has been skipped
Build and Deploy / Build people worker image (push) Has been skipped
Build and Deploy / Build web image (push) Has been skipped
Build and Deploy / Deploy API (push) Has been skipped
Build and Deploy / Deploy web (push) Has been skipped
Build and Deploy / Deploy media worker (push) Has been skipped
Build and Deploy / Deploy ML worker (push) Has been skipped
Build and Deploy / Deploy plants worker (push) Has been skipped
Build and Deploy / Deploy people worker (push) Has been skipped
Build and Deploy / Deploy converter worker (push) Has been skipped
Build and Deploy / Clean Docker build artifacts (push) Has been skipped
Build and Deploy / Run scoped PR tests (push) Failing after 35m8s
to 150c948d5f
All checks were successful
Wiki Sync / Sync wiki from docs (push) Has been skipped
Build and Deploy / Detect changed services and test scopes (push) Successful in 6s
Build and Deploy / Android unit tests and debug APK (push) Has been skipped
Build and Deploy / Smoke API and media worker (push) Has been skipped
Build and Deploy / Smoke web (push) Has been skipped
Build and Deploy / Smoke ML worker (push) Has been skipped
Build and Deploy / Smoke people worker (push) Has been skipped
Build and Deploy / Build postgres image (push) Has been skipped
Build and Deploy / Build plants worker image (push) Has been skipped
Build and Deploy / Build converter worker image (push) Has been skipped
Build and Deploy / Deploy postgres (push) Has been skipped
Build and Deploy / Build API image (push) Has been skipped
Build and Deploy / Build media worker image (push) Has been skipped
Build and Deploy / Build ML worker image (push) Has been skipped
Build and Deploy / Build people worker image (push) Has been skipped
Build and Deploy / Build web image (push) Has been skipped
Build and Deploy / Deploy API (push) Has been skipped
Build and Deploy / Deploy web (push) Has been skipped
Build and Deploy / Deploy media worker (push) Has been skipped
Build and Deploy / Deploy ML worker (push) Has been skipped
Build and Deploy / Deploy plants worker (push) Has been skipped
Build and Deploy / Deploy people worker (push) Has been skipped
Build and Deploy / Deploy converter worker (push) Has been skipped
Build and Deploy / Clean Docker build artifacts (push) Has been skipped
Build and Deploy / Run scoped PR tests (push) Successful in 11m57s
2026-09-28 22:48:38 +02:00
Compare
chris merged commit 8db1c2e8a3 into main 2026-09-28 23:25:18 +02:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
chris/memories!949
No description provided.