mirror of
https://github.com/zvx-echo6/central.git
synced 2026-06-10 11:54:37 +02:00
Central - data hub spine. Adapters -> NATS/JetStream -> archive.
- Python 89.1%
- HTML 9.3%
- CSS 1.3%
- PLpgSQL 0.3%
Narrow which WZDx registry feeds are fetched at poll time, so out-of-state feeds are never requested (no bandwidth/quota cost), rather than fetching nationally and dropping out-of-bounds events at the archive INSERT (v0.9.12). - states is now list[StateCode] (Literal of 56 canonical 2-letter codes), default ["ID","WA","OR","NV","UT","WY","MT"]. Semantic flip: empty/unset/null now means the Idaho-region default, NOT "every eligible feed". Poll nationally by selecting all states in the GUI. - list[Literal] renders as the existing checkboxes multi-select widget (firms.py precedent); pydantic rejects malformed codes at save time. - Add informational quota_estimate (cap=None: never warns/blocks) so the edit page shows the fetch-volume reduction. - adapters_edit.html: standalone quota panel for flat-config adapters, guarded by not has_model_list so model_list adapters don't double-render; reuses the identical quota.* keys + CSS so the v0.9.15 client recompute works for them too. - 7 new tests (default/null fallback, _discover filtering, malformed rejection, quota math, offline Jinja panel render). Event data shape is unchanged (poll-behavior-only), so no published_ids reset is needed. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> |
||
|---|---|---|
| docs | ||
| etc-templates | ||
| scripts | ||
| sql | ||
| src/central | ||
| systemd | ||
| tests | ||
| .gitattributes | ||
| .gitignore | ||
| .python-version | ||
| CHANGELOG.md | ||
| LICENSE | ||
| pyproject.toml | ||
| README.md | ||
| uv.lock | ||
Central
Central is the data hub spine for the infrastructure. Adapters normalize upstream sources into a canonical event shape, publish CloudEvents to NATS/JetStream, and archive to TimescaleDB for historical query. Single-LXC deployment.
Status
Phase 0 — scaffold. Not yet operational.
Architecture
- Python 3.12 (uv-managed)
- NATS + JetStream for live event bus
- TimescaleDB + PostGIS for archive and geospatial query
- One supervisor process managing adapter lifecycle
- One archive consumer process persisting events to TimescaleDB
- Both processes systemd-managed
Testing
See docs/test-database.md for test database setup.
License
MIT. See LICENSE.