// Business & Enterprise Systems•2023•VerifiedProfessional / Client Work

Smart E-VMS

Automated Traffic Violation & CCTV RTSP Monitoring Platform

Proprietary Client Architecture (Confidential Production System)
// FIGURE 01SYSTEM INTERFACE SPECIMEN
Smart E-VMS system interface
Smart E-VMS // Automated Traffic Violation & CCTV RTSP Monitoring Platform

Project at a Glance

  • Problem: Roadside traffic enforcement CCTV cameras transmit raw RTSP video feeds that standard web browsers cannot natively render, while high-volume traffic violation logs, solar-powered field node health, camera AI statuses, and vehicle flow analytics require a centralized web operations platform.
  • Deliverables: A web-based traffic monitoring and automatic traffic ticket violation (ETLE) platform featuring low-latency browser multi-camera live grids via FFmpeg + WebSocket + MSE, violation log verification and reporting, camera AI module monitoring, system/power diagnostics, and vehicle traffic flow analytics.
  • Core Stack: Nuxt 3, Vue 3, Tailwind CSS, AdonisJS, MySQL, Redis / Queue, and an RTSP-to-MSE streaming pipeline powered by FFmpeg over WebSocket.
  • Practical Value: Replaced desktop-only camera viewers with a responsive, browser-native operations suite enabling traffic operators to monitor live CCTV streams without .ts segment delay, verify automated violation captures, track field device/power health, and review traffic statistics from one interface.

Project Overview

Smart E-VMS (Smart Energy Video Monitoring System) is an enterprise traffic surveillance and automatic traffic ticket violation (ETLE) web platform developed at PT Lasbon Technology Indonesia for solar/battery-powered roadside monitoring units. Working as a Fullstack Web Developer within the engineering team, I built the Nuxt 3 monitoring dashboard, browser-based multi-stream video player (MSE over WebSocket), AdonisJS REST API and WebSocket backend, MySQL data layer, and traffic violation management workflows, coordinating closely with the hardware and detection team responsible for roadside cameras and violation detection.

The platform consolidates live CCTV monitoring (Live), violation and VMS record management (Data VMS), camera hardware & AI module status tracking (AI Kamera), traffic flow analytics (Informasi Arus Lalu Lintas), field system/power & storage health (Informasi System), user access control (User Management), and audit history (Activity Log) into one unified web application.

Interface Specimens

Smart E-VMS traffic analytics dashboard displaying vehicle counts, passenger cars, motorcycles, trucks, and monthly traffic statistics

Traffic & System Dashboard (Informasi Arus Lalu Lintas & Informasi System): Consolidated vehicle volume breakdowns (passenger cars, motorcycles, trucks), monthly trend and vehicle-type charts, alongside system/device health monitoring for solar-powered roadside nodes (power, storage, and node status).

Smart E-VMS AI Camera status console showing IP camera inventory and active detection modules per camera

Camera & Detection Status Console (AI Kamera): Centralized monitoring of roadside IP camera units, network addresses, and active detection module statuses (license plate, traffic violation, traffic flow, vehicle type/color/logo, congestion).

Context & The Problem

Municipal traffic enforcement networks deploy solar/battery-powered roadside IP cameras transmitting continuous raw RTSP video streams alongside automated violation capture events. Operating these networks effectively presented several engineering challenges:

  • Browser Protocol Incompatibility: Standard web browsers cannot natively play raw RTSP feeds without legacy plugins, while file-segmented approaches (such as .ts HLS playlists) add unacceptable buffering latency for live operator monitoring.
  • Multi-Stream Resource Exhaustion: Rendering multiple simultaneous live CCTV feeds inside a browser tab via MediaSource buffers can rapidly consume memory and CPU if source buffers and WebSocket connections are not aggressively recycled.
  • Unstable Field Networks: Roadside camera connections frequently experience jitter or brief dropouts, requiring resilient stream reconnection and clear online/offline camera and node diagnostics.
  • High-Volume Violation & Traffic Data: Operators need fast multi-criteria filtering across large volumes of traffic violation logs, capture evidence, and monthly vehicle count reports without slow database queries.

The core engineering objectives were:

  • Bridge raw RTSP camera streams directly to modern web browsers with low-latency playback using FFmpeg, WebSocket, and Media Source Extensions (MSE).
  • Provide complete web workflows for verifying automated traffic violations, managing camera configurations, monitoring field system/power health, and visualizing traffic flow reports.
  • Maintain clean API contracts and reliable data synchronization between the AdonisJS backend and the external camera/detection layer.

System Architecture

Smart E-VMS uses a decoupled web and streaming pipeline architecture separating roadside camera hardware from the browser-based operator console:

+-------------------------------------------------------------------+
|               Roadside Smart-Energy Hardware & Detection          |
|   Solar/Battery IP Cameras (RTSP) + Violation Detection Layer     |
+---------------------------------+---------------------------------+
                 | Raw RTSP       | Violation Events & System Health
                 v                v
+-------------------------+  +--------------------------------------+
| Media Streaming Service |  | Backend Core (AdonisJS / TypeScript) |
| FFmpeg -> WebSocket     |  | REST API + WebSocket + Redis/Queue   |
+------------+------------+  +------------------+-------------------+
             |                                  |
             | Fragmented Stream (WS)           | Relational Storage
             |                                  v
             |               +--------------------------------------+
             |               |            Primary DB (MySQL)        |
             |               |   Violation Logs, Cameras, Reports   |
             |               +------------------+-------------------+
             |                                  |
             +----------------+-----------------+
                              v
+-------------------------------------------------------------------+
|                 Operator Web Dashboard (Nuxt 3)                   |
|        Vue 3 + Tailwind CSS + Browser MSE (MediaSource API)       |
|  +--------------------+  +------------------+  +---------------+  |
|  | Live CCTV Grid     |  | Violation Logs & |  | Traffic Flow  |  |
|  | & AI Camera Status |  | Evidence Review  |  | & System Info |  |
|  +--------------------+  +------------------+  +---------------+  |
+-------------------------------------------------------------------+

Architectural Decisions

  1. Nuxt 3 & Vue 3 Modular Dashboard: Vue 3's fine-grained reactivity enabled live camera tiles, violation status updates, and analytics charts to update independently without triggering unnecessary re-renders across adjacent active <video> MSE elements.
  2. FFmpeg + WebSocket + Browser MSE Streaming Pipeline: Instead of splitting streams into disk-backed .ts playlist segments, FFmpeg ingests raw RTSP feeds and streams fragmented video chunks continuously over WebSocket directly into the browser's MediaSource (MSE) API. This eliminates segment-file overhead and keeps live monitoring latency low.
  3. AdonisJS + MySQL + Redis / Queue: AdonisJS powers the structured REST API and WebSocket channels, MySQL stores indexed violation logs, camera inventories, and activity audits, while Redis and background queues handle real-time event buffering and dashboard aggregation caching.

Engineering Challenges & Solutions

1. Bridging Raw RTSP Streams to Modern Browsers via FFmpeg, WebSocket & MSE

Standard web browsers cannot consume raw RTSP streams directly, and segment-based streaming (.ts files) adds multi-second latency unsuitable for live traffic monitoring.

  • Solution: Built a streaming pipeline using FFmpeg to repackage raw RTSP feeds into fragmented streams delivered over WebSocket directly into the browser's MediaSource (MSE) SourceBuffer, enabling low-latency live playback directly in standard browsers without desktop plugins.

2. Browser Memory & Resource Management in Multi-Camera Grids

Continuously appending video chunks to multiple MediaSource buffers inside a single browser tab quickly leads to memory leaks and tab crashes if old buffer ranges and WebSocket streams are not pruned and torn down cleanly.

  • Solution: Implemented strict Vue lifecycle cleanup hooks and buffer trimming so that switching routes, changing grid layouts, or closing camera tiles immediately closes the WebSocket stream, detaches and destroys the MediaSource buffer, and releases browser memory.

3. Stream Stability, Auto-Reconnect & Network Jitter Handling

Field-deployed roadside cameras periodically experience transient packet loss, bitrate fluctuations, or temporary disconnects.

  • Solution: Added automatic WebSocket reconnection logic with backoff, explicit online/offline camera and field-node health indicators, and MSE buffer recovery so operators do not need to manually reload the dashboard after transient network drops.

4. High-Volume Violation Log Querying & Evidence Loading

Automated traffic monitoring generates large MySQL tables of violation records, timestamps, camera references, and capture images that must remain fast to search and filter.

  • Solution: Structured indexed MySQL tables with server-side pagination, multi-criteria filtering (date range, camera location, violation type), Redis caching for analytics summaries, and optimized lazy loading for violation capture evidence.

5. Cross-Team API & Event Contract Coordination

Because roadside camera hardware, solar power telemetry, and violation detection engines were maintained by a separate hardware/detection team, mismatched payload schemas or event timings could break ingestion.

  • Solution: Established explicit REST API and event payload contracts between the detection/hardware layer and the AdonisJS backend, supported by request validation and activity logging to diagnose ingestion discrepancies quickly.

Outcomes & Key Learnings

  • Delivered a browser-native Smart Energy Video Monitoring System covering live CCTV monitoring (RTSP via FFmpeg + WebSocket + MSE), camera AI status diagnostics, field system/power info, violation review, and traffic flow analytics.
  • Strengthened hands-on engineering discipline around MediaSource buffer lifecycle management, low-latency WebSocket streaming resilience, and cross-team integration between web platforms and field hardware systems.