gitoria

tracker

All repositories: gitoria

ReadmeCodePull requestsReleasesTicketsSettings
Commitf57f64f0f57f64f0mission 046: report, LOGmref57f64f0/tests/realdata-060-backfill.sh

1.8 KB

  1. #!/bin/bash
  2. # tests/realdata-060-backfill.sh — mission 060 (tracker#27), NOT the gate: starts the app on the COPY in .scratch/realdata (:8730,
  3. # no TMDB sync, no adult backfill) and times 4 pages with curl, back to back, until the short-id backfill says done (or MAX s).
  4. # The server keeps running (its pid in $OUT/real.pid) — stop it yourself. STATUS.md mission 060 has the whole procedure.
  5. # tests/realdata-060-backfill.sh <run name> [MAX seconds, 500] [full = time until MAX even when done] [VAR=value …]
  6. # → $OUT/real-<run>.log (the app's log), $OUT/times-<run>.txt (path seconds), a summary per page (avg, max, answers over 1 s)
  7. cd "$(dirname "$0")/.."
  8. N=$1; MAX=${2:-500}; FULL=$3; shift 3
  9. OUT=${OUT:-/tmp/w060}
  10. mkdir -p .scratch/realdata-sessions "$OUT"
  11. env TRACKER_PORT=8730 TRACKER_SYNC=0 TRACKER_WATCH=0 TRACKER_BACKFILL=0 TRACKER_STORAGE=$PWD/.scratch/realdata/storage/mpackdb TRACKER_SESSIONS=$PWD/.scratch/realdata-sessions/ TRACKER_URL=http://127.0.0.1:8730 HL_HOST=127.0.0.1 "$@" setsid nohup ./bin/hybriel project.hl > "$OUT/real-$N.log" 2>&1 < /dev/null & echo $! > "$OUT/real.pid"
  12. for i in $(seq 1 400); do curl -s -o /dev/null http://127.0.0.1:8730/ && break; sleep 0.05; done
  13. : > "$OUT/times-$N.txt"
  14. END=$(( $(date +%s) + MAX ))
  15. while { [ -n "$FULL" ] || ! grep -q "short ids done\|short ids: nothing\|backfill off" "$OUT/real-$N.log"; } && [ $(date +%s) -lt $END ]; do
  16. for p in /shows/Foundation / /person/Jared-Harris /movies; do
  17. echo "$p $(curl -s -m 20 -o /dev/null -w '%{time_total}' http://127.0.0.1:8730$p)" >> "$OUT/times-$N.txt"
  18. done
  19. kill -0 $(cat "$OUT/real.pid") 2>/dev/null || { echo DIED; break; }
  20. done
  21. grep -v "^$" "$OUT/real-$N.log" | head -40
  22. awk '{n[$1]++; s[$1]+=$2; if($2>m[$1])m[$1]=$2; if($2>1)o[$1]++} END{for(k in n) printf "%s n=%d avg=%.3f max=%.3f over1s=%d\n",k,n[k],s[k]/n[k],m[k],o[k]}' "$OUT/times-$N.txt"

Branches

Latest commits

  • f57f64f0mission 046: report, LOGmre
  • efe1b485mission 046: re-vendor Hybriel master 60b2817b (integration 8, #203): plugins mpackdb + web (bin/ git-ignored: hybriel, libhlrt.a, hlc.o, hlrt/ from native/zig-out)mre
  • 53099ffbmission 046: person page reads a slim per-title credit row cache (no whole-record fetch per credit); gate tests/person-lookup.mjsmre
  • 9b3828aemission 046a: report, LOGmre
  • 4b37356emission 046: franchise seed supersedeCollections reads the curated timelines once (10 s one-tick block at the end of boot)mre
  • ac6268e3mission 046a: re-vendor Hybriel 528bc89f (integration 6): plugins mpackdb/time/web (bin/ git-ignored)mre
  • 322b3293mission 046: photoQueue guard for non-row fetch results (damaged persons index)mre
  • e5b99aecmission 046: photoQueue in slices (people.hl photoQueueStart/Step, jobs.hl photoTick), tests/photoqueue.hlmre
  • 31dcf2admission 045: report, LOGmre
  • 9c3971d0tests/persons-skip-count.hlmre
  • 4d72e365mission 045mre
  • b9cae4c9slices: skip and count non-row values from range(); merge persons pass falls back to iterate; guard testmre
  • 3db7dc31merge w44-jobs-slices into w43-trkmemmre
  • 593dab6fmission 043: report, LOGmre
  • 1a5a4818boot scans back to iterate (slices measured slower: titles 114 s, episodes 141 s, persons failed); lambda per rowmre
  • 03d29893boot scans read primary-key slices (lib/slices.hl from mission 044): iterate is eager too; people view log line back; allShows/allEpisodes stay for toolsmre
  • 23375c58mission 044: report, LOG, STATUSmre
  • c6fd928emission 044: 4096 slices for tables over 200 K rows, 15 ms budget, TRACKER_SLICE_DEPTH for testsmre
  • fb057680mission 044: jobs.hl imports mergeLeft (gate found it), mission file, slices benchmre
  • 0d6293ebmission 043: mission filemre