-
Notifications
You must be signed in to change notification settings - Fork 0
Testing & Debugging
This page is the operational test and triage playbook for the current stack.
Use this page when validating local changes, checking runtime health, or diagnosing user-facing failures across API, telemetry, and monitoring.
- Developers debugging service behavior.
- Operators triaging incidents in local/cluster-like environments.
From project-code/backend:
uv run python -m ruff check .
uv run python -m pytest -qExpected result: lint exits 0; tests complete with no failures.
From project-code/frontend:
npm run lint
npm run testExpected result: no lint errors and passing test suite.
From project-code/:
pre-commit run --all-filesExpected result: all enabled hooks pass.
curl http://localhost:8000/healthExpected result: 200 and healthy/liveness payload.
curl http://localhost:8001/health
curl http://localhost:8001/readyExpected result: liveness 200; readiness confirms Docker API + model registry are ready.
docker compose exec mqtt-proxy wget -qO- http://localhost:8010/health
docker compose exec mqtt-proxy wget -qO- http://localhost:8010/ready/bridgeExpected result: liveness is healthy; bridge readiness reflects configured bridge mode.
docker compose exec db-sync wget -qO- http://localhost:8009/health
docker compose exec db-sync wget -qO- http://localhost:8009/ready/schemaExpected result: service healthy and schema ready.
Tail critical services:
docker compose logs -f api-gateway tactic-middleware db-sync mqtt-proxy mqtt-radarFocused last-lines checks:
docker compose logs --tail 200 api-gateway
docker compose logs --tail 200 tactic-middleware
docker compose logs --tail 200 mqtt-proxy
docker compose logs --tail 200 db-sync- Confirm frontend API target:
# verify VITE_API_URL in active run mode- Check gateway liveness:
curl http://localhost:8000/health- Check TACTIC readiness:
curl http://localhost:8001/ready- Inspect gateway logs for upstream failures.
- Confirm model registry endpoints are populated:
curl http://localhost:8000/v1/monitors/models
curl http://localhost:8000/v1/monitors/preprocessors- Confirm TACTIC readiness.
- Inspect TACTIC logs for Docker API, registry validation, or orchestration failures.
- Verify source publisher (or simulator) is active.
- Check proxy health/readiness endpoints.
- Inspect proxy logs for topic regex/parse errors or DB write failures.
- Verify DB/service path using telemetry endpoints.
- Verify monitor workload exists:
curl http://localhost:8000/v1/monitors/all- Confirm workload config/model is valid and warmed up.
- Check anomaly endpoints:
curl http://localhost:8000/v1/anomalies/count- Inspect RADAR logs for model/runtime errors.
| Component | Host Port |
|---|---|
| Frontend | 5173 |
| API Gateway | 8000 |
| TACTIC Middleware | 8001 |
| DB Sync | 8009 |
| MQTT Proxy |
8010 (internal health) |
| PostgreSQL/TimescaleDB | 5432 |
| MQTT (EMQX) | 1883 |
| Source broker (host loopback) | 1884 |
| EMQX Dashboard | 18083 |
| Mailpit UI / SMTP |
8025 / 1025
|