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%
* v0.9.20: regional subject routing on quake / fire / hydro / disaster adapters Adds regional subject tokens to four adapters that previously published without location-based routing: - usgs_quake: central.quake.event.<tier>.us.<state> (US) or .<country> (intl) - firms: central.fire.hotspot.<sat>.<conf>.us.<state> or .<country> - nwis: central.hydro.<param>.<agency>.<site>.us.<state> (always US) - eonet: central.disaster.eonet.<cat>.<country> (replaces hardcoded .global) The us.<state> pattern (two tokens for US events) matches the NWS precedent and resolves the ISO-2 collision between Idaho (id) and Indonesia. New shared helper module: src/central/adapters/_subject_helpers.py - US_STATE_NAME_TO_CODE: 50 states + DC + territories - subject_for_country(): normalized country token - subject_for_region(): returns us.<state>, <country>, or unknown gdacs.py refactored to import subject_for_country from shared module. Fixes: meshai v0.4 Phase C.3 bug (M4.1 Nevada quake routed globally) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> * v0.9.20: stale docstring nit on renamed test Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> --------- Co-authored-by: Matt Johnson <mj@k7zvx.com> Co-authored-by: Claude Opus 4.5 <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.