HTTPd M1 — active upstream health probes¶
Summary¶
Completes plan todo m1-active-health: periodic GET probes on upstream peers ([health.active] in TOML), mark peers down on probe failure, and skip them in round-robin / least-conn rotation.
Agent continuation¶
- Run
./scripts/httpd-plan-gates.sh(includestest-active-upstream-health.shwhenHTTPD_RUN_ACTIVE_HEALTH_TEST=1, default on full build). - Run
./scripts/test-active-upstream-health.shafter./scripts/build-li-httpd.sh. - Example config:
packages/li-net-httpd/examples/active_health.toml.
Changed¶
| Area | Paths |
|---|---|
| Runtime | runtime/li_rt_net.c — httpd_tick_active_health_probes_i, probe in epoll + Li proxy loop |
| Seam | std/runtime/seam.li, runtime/li_rt.h |
| Proxy loop | packages/li-net-httpd/src/lib.li |
| Config | scripts/flatten-httpd-config.py, scripts/validate-httpd-config.py |
| Gates | scripts/httpd-plan-gates.sh, scripts/test-active-upstream-health.sh |
| Plan | docs/superpowers/plans/2026-05-16-li-httpd-plan.md — m1-active-health: completed |
Not changed¶
- Tier-5 bench matrix ingest; live Pages refresh (no new CSV this slice).
- Passive health (
max_failson connect errors) behavior unchanged.
Breaking¶
N/A — [health.active] is optional.
Security¶
Probe path must be relative (/… only); validate rejects ://, .., and %. Interval bounded to [1, 300] seconds.
Performance¶
Probes run at most once per health.active.interval per upstream pool; blocking connect with 2s socket timeouts.
Downstream¶
- benchmarks — re-run tier-5
lb_peer_downwhen refreshing httpd bench matrix.