NyxMon Documentation¶
Welcome to the NyxMon documentation. NyxMon is a minimalistic monitoring application for services and health checks, designed with a clean architecture approach and SQLite as its storage backend.
Quick Start¶
Install NyxMon with
pipx install nyxmonoruv tool install nyxmonRun database migrations:
uv run src/django/manage.py migrateStart the agent and dashboard:
uvx honcho startAccess the dashboard at http://localhost:8000
Note
For detailed installation instructions and development setup, see Installation.
Key Features¶
Event-Driven Architecture: Built on a message bus pattern with commands and events
Multiple Check Types: HTTP checks and DNS checks today (ping and metric validation are planned)
Django Dashboard: Web interface for monitoring and configuration
Telegram Notifications: Optional notifications for check failures
SQLite Backend: Deliberate choice to avoid database dependencies for monitoring
Async Check Runner: Efficient concurrent check execution
Contents¶
Guides
Architecture
- Architecture Document - Minimalistic Monitoring Tool
- AsyncCheckRunner Execution Flow
- 1. Entry Point:
CheckRunner.run_all - 2. Using a Portal to Enter the Async World
- 3.
_async_run_all: Fan Out Work and Gather Results - 4. Executor Registry
- 5.
_run_one: Execute a Single Check - 6. Returning to the Synchronous Callback
- 7. Resource Cleanup and Ordering Guarantees
- 8. Opportunities for Future Refinement
- 1. Entry Point:
- Runtime Concurrency Model
- 1. Startup Timeline (
entrypoints/cli.py:start_agent) - 2. Portal Thread (
BlockingPortalProvider) - 3. Message Bus and Handlers
- 4. Collector and Cleaner Threads
- 5. Worker Thread Pool (
anyio.to_thread.run_sync) - 6. Streaming Results (
anyio.create_memory_object_stream) - 7. Concurrency Summary
- 8. Interaction Between Handlers and Async Code
- 9. Shutdown
- 1. Startup Timeline (
Reference
Additional Resources¶
Source code: https://github.com/ephes/nyxmon
Architecture Overview - detailed system design and component documentation
Async Check Runner - detailed walkthrough of the asynchronous runner implementation