OmniPulse is an enterprise-grade, event-driven polyglot microservice ecosystem designed for high-throughput IoT/energy telemetry ingestion, background analytical aggregation, and AI-driven anomaly detection in real time.
+----------------------------------+
| React / Next.js Dashboard |
+-----------------+----------------+
| ▲
HTTP / REST (JWT) | | WebSockets (Live Alerts)
▼ |
+------------------------------------------------------+
| SERVICE 1: NestJS (API & Ingestion Gateway) |
| • DTO Validation (class-validator) |
| • Rate Limiting & Auth Guards |
| • Redis Message Producer |
+--------------------------+---------------------------+
|
| Event Queue (LPUSH / RPOP)
▼
+--------------------------+
| Redis Message Broker |
+-------------+------------+
|
| Task Execution
▼
+------------------------------------------------------+
| SERVICE 2: Django REST & Celery (Analytics Engine)|
| • PostgreSQL Data Persistence |
| • Celery Workers (Batch Processing & Aggregations) |
| • Scheduled Tasks (Celery Beat CRON) |
| • AI / LLM Anomaly Detection Pipeline |
+--------------------------+---------------------------+
|
▼
+--------------------------+
| PostgreSQL Database |
+--------------------------+
- Polyglot Microservices: NestJS for event-driven async I/O & Django for analytical computation and data modeling.
- High-Throughput Ingestion: Non-blocking ingestion pipeline via NestJS connected to Redis queues.
- Background Worker Architecture: Asynchronous workers powered by Celery & Redis for scheduled tasks and heavy reporting.
- Robust Data Validation: Type-safe DTOs (
class-validator) on the gateway and strictDRF Serializerson the analytics layer. - Containerized Infrastructure: Single-command local infrastructure setup with Docker Compose.
omnipulse/
├── docker-compose.yaml # PostgreSQL & Redis infrastructure
├── gateway-nest/ # NestJS Ingestion Gateway & WebSockets
│ ├── src/
│ │ ├── telemetry/ # Telemetry ingestion controller & DTOs
│ │ └── redis/ # Redis connection service & DI provider
│ ├── package.json
│ └── tsconfig.json
└── analytics-django/ # Django REST Framework & Celery Worker
├── core/ # Django settings & Celery config
├── api/ # Models, Serializers, Views & Celery Tasks
├── manage.py
└── requirements.txt
- Docker & Docker Compose
- Node.js (v18+)
- Python (v3.10+)
From the project root:
docker compose up -d
cd gateway-nest
npm install
npm run start:dev
- Endpoint:
http://localhost:3000
Step 4.1: Database Migrations & Django Server
cd analytics-django
python3 -m venv env
source env/bin/activate # On Windows: env\Scripts\activate
pip install -r requirements.txt
python manage.py migrate
python manage.py runserver 8000
Step 4.2: Run Celery Worker (In a separate terminal)
cd analytics-django
source env/bin/activate
celery -A core worker -l info
POST /api/telemetry (NestJS Gateway)
{
"device_id": "sensor-eu-west-01",
"metric_value": 78.4,
"sensor_type": "power_load"
}{
"status": "queued",
"message": "Telemetry sent to analytics processing pipeline",
"data": {
"device_id": "sensor-eu-west-01",
"metric_value": 78.4,
"sensor_type": "power_load",
"received_at": "2026-08-16T15:10:00.000Z"
}
}| Layer | Technology | Purpose |
|---|---|---|
| API Gateway | NestJS (TypeScript) | Ingestion, validation, rate limiting, WebSockets |
| Message Broker | Redis | Asynchronous queue and inter-service messaging |
| Analytics Backend | Django & DRF (Python) | ORM aggregations, business logic, reporting |
| Task Queue | Celery & Celery Beat | Scheduled polling, anomaly detection, background processing |
| Database | PostgreSQL | Relational data persistence |
| DevOps | Docker Compose | Orchestration of local development services |
This project is open-source and available under the MIT License.