mirror of
https://github.com/MeshCore-Beacon/beacon-server.git
synced 2026-10-16 03:00:29 +00:00
Stats endpoints read hourly rollup tables filled once per closed hour by one advisory-locked task, instead of materialized views that re-scanned every observation on each refresh. IATA-set tables give exact distinct counts for any IATA set or region. Cleanup holds raw rows for unrolled hours (up to 24h). Adds /stats/series; ingest keeps packet observation counts, observer last IATA, channel message counts and trace tag summaries. 001_baseline.sql is rewritten, so pre-release 2.0 databases must be recreated. See docs/historical-stats.md.
1.6 KiB
1.6 KiB
Shoulders
Beacon stands on the shoulders of giants. Thank you to the following open source projects that make this possible:
Core dependencies
- meshcore-go — MeshCore packet decoding
- paho.mqtt.golang — MQTT client
- pgx — PostgreSQL driver and connection pool
- sqlc — Type-safe SQL code generation
- chi — HTTP router
- go-chi/cors — CORS middleware for chi
- go-chi/httprate — Per-client HTTP sliding-window rate limits and retry headers
- go-redis — Redis client
- coder/websocket — WebSocket implementation
- swaggo/swag — OpenAPI documentation generation
- godotenv — .env file loading
- yaml.v3 — YAML config parsing
- google/uuid — UUID generation
- golang.org/x/sync — singleflight for collapsing concurrent cache misses
Data
- OurAirports — IATA airport geographic data (CC0 public domain)
Infrastructure
- PostgreSQL — Primary data store
- Redis — Optional caching layer
- Caddy — Reverse proxy
Language
- Go — The language that makes this all possible