A US retail chain needed modern security to prevent after-hours intrusions; we built an AI-powered edge-cloud system delivering accurate real-time alerts.
Quick Facts
Industry: Retail / Security Automation
Location: USA
Platform Type: Hybrid Edge Cloud Architecture
Core Stack: AWS Lambda, IoT Core, DynamoDB, S3, Spring Boot, React
Edge Tech: Raspberry Pi, OpenCV, DeepStack AI
Authentication: AWS Cognito (JWT + RBAC)
Alerting: Slack Webhooks
Rigrex delivered end-to-end system architecture, IoT engineering, AI integration, cloud infrastructure setup, backend and frontend development, and DevOps implementation to ensure a scalable, secure, and high-performance intrusion detection platform.
Background
A major retail chain experienced unauthorized after-hours access across multiple branches. Existing legacy camera systems lacked intelligent triggers, real-time notifications, and contextual awareness.
Manual activation and deactivation of systems led to unreliable enforcement. Meanwhile, constant alerts during working hours overwhelmed staff and reduced trust in the system.
DES required an intelligent, automated, and scalable security solution capable of real-time response without operational noise.
The Challenge
Business Challenges
- Repeated after-hours security breaches
- No automated detection or scheduling
- Alert fatigue during working hours
- Need for visual evidence with alerts
Operational Pain Points
- Manual system activation/deactivation
- Lack of centralized store monitoring
- No structured intrusion logs
- Delayed incident response (~30 minutes)
Technical Challenges
- <5-second response requirement
- Handling up to 10 intrusion events per second
- Capturing ±5-second image windows around trigger events
- Preventing race conditions between sensor and camera logic
- Maintaining privacy while implementing AI-based face detection
The Solution
Rigrex designed a hybrid edge-cloud architecture optimized for scalability, modularity, and event-driven responsiveness.
Hybrid Edge Cloud Architecture
Edge Layer (Store Level)
- Raspberry Pi with door sensor & camera
- OpenCV + ffmpeg circular buffer (±5-second capture window)
- DeepStack AI for on-device face detection
- Secure MQTT communication
Cloud Layer (AWS)
- AWS IoT Core for managed MQTT routing
- AWS Lambda for event handling & Slack alerts
- AWS DynamoDB for intrusion metadata logging
- S3 for secure image storage
- AWS Scheduler for automatic arming/disarming
- AWS Cognito for authentication & RBAC
Backend & Dashboard
- Spring Boot REST API
- React Admin Dashboard
- Schedule overrides, store configuration, and log viewer
Smart Scheduling System
AWS Scheduler triggers arm/disarm Lambda functions based on store open/close times.
The system only triggers alerts when:
- The door is closed
- The system is within an active time window
Results were zero false positives during working hours.
AI-Based Visual Verification
- Images captured ±5 seconds of motion trigger
- DeepStack AI performs local face detection
- Annotated images uploaded to S3
- Slack alerts include image preview + detection metadata
All processing occurs locally to preserve privacy and reduce latency.
Implementation Process
Phase 1: Event Infrastructure & Secure Cloud Foundation
- AWS IoT Core device registration with X.509 certificates
- MQTT topic structuring per store
- Lambda integration for real-time Slack alerts
- DynamoDB for intrusion logs with TTL
- Cognito JWT-based authentication
- Spring Security RBAC enforcement
- CI/CD pipelines using GitHub Actions
Phase 2: Edge AI & Image Intelligence
- Circular frame buffer implementation using OpenCV
- Clock synchronization for timestamp accuracy
- DeepStack AI container deployment on Raspberry Pi
- Annotated image generation
- Slack alert enrichment with visual evidence
Observability was intentionally deferred during MVP to prioritize rapid functional validation.
Results & Impact
Security Improvements
- Incident response reduced from ~30 minutes to <2 minutes
- 100% detection of off-hours intrusions
- Prevented 3 intrusion attempts within first 30 days
- 0 false alerts during operational hours
Performance Metrics
- 2–4.5 second alert latency
- Sustained throughput of 10 intrusion events/sec
- Scalable serverless architecture
Operational Impact
- Visual Slack alerts improved trust and verification
- Regional managers adopted admin dashboard for scheduling
- Local AI processing maintained compliance and privacy
Lessons Learned
- AWS IoT Core significantly simplifies scalable MQTT routing
- Lambda + Scheduler pairing creates clean time-based automation
- Early modularization of edge logic simplified scaling across stores
- Slack is ideal for MVP alerting but future escalation channels are recommended
- Delaying observability accelerates MVP delivery but increases debugging complexity
Why It Matters
This project demonstrates Rigrex’s ability to build intelligent, real-time IoT security systems that combine:
- Edge AI processing
- Serverless cloud scalability
- Secure authentication & device communication
- Low-latency event handling
- Cost-efficient hybrid architecture
DES now operates a proactive, automated first line of defense enabling store staff to respond within seconds rather than minutes.