tracker
All repositories: gitoria
1.8 KB
// lib/warm.hl — THE START-UP STATE (mission T17, boot time): the server listens BEFORE the derived structures (public lists, slug maps,// search index, short ids, people view) are built; bootscan.hl builds them in time-boxed steps between requests. This is the one// place that says how far it is. `running` = a progressive start is under way (a module's lazy full-scan fallback must NOT run// then — it would block the server for minutes); the three flags turn true one after the other:// titles → the slug map (shows.hl), the titles' own derived data are in// catalog → titles + episodes: the public lists, the genre lists, the newest-episode dates (catalog.hl)// people → everything: search index, short ids (owners), person slug / TMDB maps, /people's order; the jobs start// A tool or a test that never starts the progressive scan has running = false: the modules' lazy builds work as before.import { now } from 'hl:time'static warm = { running = false titles = false catalog = false people = false phase = '' rows = 0 startedAt = 0 readyAt = 0 }static warmRunning = () => { return warm.running }// what a page that needs `level` ('titles' | 'catalog' | 'all') may do: true = go aheadstatic warmReady = (level) => {if (!warm.running) { return true }if (level == 'titles') { return warm.titles }if (level == 'catalog') { return warm.catalog }return warm.people}// the writers that rely on the complete indexes (a duplicate title / person / short id otherwise) refuse until all is builtstatic warmBlocked = () => { return warm.running && !warm.people }static warmSeconds = () => {if (warm.startedAt == 0) { return 0 }s = (now() - warm.startedAt) / 1000return s - s % 1}static warmText = () => {return 'tracker is starting up: the lists, the search and the people are being built (' + warm.phase + ', ' + warmSeconds() + ' s so far). Reload this page in a minute or two.'}
Branches
Latest commits
- 05d89fd0deploy: security gate (tests/security.mjs)mre
- 2ae8a47bMerge branch 'sk-sec'mre
- 8fee5d52sessions last 99 years (creator 2026-10-23: logins never expire; only sign out ends them)mre
- 944ad51eSK: report reports/SK-sec.md, LOGsk
- 415487c1SK: import budget per user + id type check, gate checkssk
- 7b8a4f74security audit SK: nosniff + image sandbox headers, face id checks, adult follow, login budget + new session at login, guest-link budget, tests/security.mjssk
- f0f26c5areports: T18 section (gates, boot-gate, 3x3 table, search + short-id compare)mre
- 2a8682a1deploy.sh GATES: tests/warmstart.mjsmre
- 3761338breports/T17-boot.md: handoff (phase table, fix, numbers so far, open proof)mre
- 52e09eb2boot: sync window 1000 ms (the gates ask for a complete start), README boot-time sectionmre
- c87149e8tests/warmstart.mjs: the progressive start proven over HTTP (note in the window, 503 short id, after: everything); bootBeginmre
- 593a6350boot: resumable start-up scan, the server listens first (T17)mre
- be4890a0reports: H2 hydration audit (no test change needed)mre
- 1f9c8bf4re-vendor Hybriel 5406d146 (hl:web batches 9+10: #72 emits while the socket is closed delivered after reconnect, browser boot linear, faster list appends; contains int 6–14 + m406)mre
- c1df88eddocker-compose: HL_GC_TABLE_LOAD=62 (tracker mission 048, T16 real-data numbers)mre
- d0a82867mission 048: report, LOG (HL_GC_TABLE_LOAD=62 measured)mre
- 2d4be66fre-vendor Hybriel 5df4eb7e (GC: HL_GC_TABLE_LOAD knob, mission 406)mre
- 99e7c8b9tests: realdata-m035-radii, repro-t38, realdata-060-backfill ports from env (REAL_PORT, REAL_CHROME, REPRO_CHROME), defaults unchangedmre
- 4625aa22re-vendor Hybriel 6f8a0689 (int 6–11: streaming cursors, #203 index heal + close() fix, fd403 listDir/cursor fds, hl:time browser side, hl:web batches 5+6)mre
- a6dfd6ecdeploy: person-lookup gate (tracker#46)mre