We’re a small dev team (3 full-stack web devs + 1 mobile dev) working on a B2B IoT monitoring platform for an industrial energy component manufacturer. Think: batteries, inverters, chargers. We have 3 device types now, with plans to support 6–7 soon.
We're building:
- A minimalist mobile app for clients (React Native)
- A web dashboard for internal teams (Next.js)
- An admin panel for system control
Load Characteristics
- ~100,000 devices sending data every minute
- Message size: 100–500 bytes
- Time-series data that needs long-term storage
- Real-time updates needed for dashboards
- Multi-tenancy — clients can only view their own devices
- We prefer self-hosted infrastructure for cost control
Current Stack Consideration
- Backend: Node.js + TypeScript + Express
- Frontend: Next.js + TypeScript
- Mobile: React Native
- Queue: Redis + Bull or RabbitMQ
- Database: MongoDB (self-hosted) vs TimescaleDB + PostgreSQL
- Hosting: Self-hosted VPS vs Dedicated Server
- Tools: PM2, nginx, Cloudflare, Coolify (deployments), Kubernetes (maybe, later)
The Two Major Questions We're Facing:
1. MongoDB vs TimescaleDB for dynamic IoT schemas and time-series ingestion?
We need to store incoming data with flexible schemas (new product types have different fields), but also support efficient time-series querying (e.g., trends, performance over time).
- MongoDB seems flexible schema-wise, but might fall short on time-series performance.
- TimescaleDB has strong time-series support but feels more rigid schema-wise.
- Is there a proven pattern or hybrid approach that allows schema flexibility and good time-series performance?
2. How to structure ingestion for 100K writes/min while supporting schema evolution?
We’re worried about bottlenecks and future pain if we handle ingestion, schema evolution, and querying in one system.
- Should we decouple ingestion (e.g., raw JSON into a write-optimized store), then transform/normalize later?
- How do we avoid breaking the system every time a new product with a new schema is introduced?
- We’ve also considered storing a "data blob" per device and extracting fields on-demand — not sure if that scales.
Additional Sub-Questions:
(Feel free to address any of these if they fall into your expertise area)
- RabbitMQ vs Kafka — Is Kafka worth adopting now or premature for our stage?
- Real-time updates — Any architectural patterns that work well at this scale? (Polling, WebSockets, SSE?)
- Multi-tenancy — Best-practice for securely scoping data per client in both DB and APIs?
- Queue consumers — Should we custom-load-balance our job consumers or rely on built-in scaling?
- VPS sizing — Any heuristics for choosing VPS sizes for this workload? When to go dedicated?
- DevOps automation — We’re small. What lightweight CI/CD or IaC tools would you suggest? (Currently using Coolify)
- Any known bottlenecks, security traps, or reliability pitfalls from similar projects?
We're still early in the build phase and want to make smart decisions upfront. If any of you have dealt with similar problems in IoT, real-time dashboards, or large-scale data ingestion — your advice would mean a lot.
Thanks!