feat: Implement HTTP Poller for IoT device data ingestion

- Added iots-right.json configuration file to define IoT devices and their sensors.
- Developed HttpPoller class to handle polling of IoT devices via HTTP.
- Created IoT configuration loader to validate and load device configurations from JSON.
- Introduced models for device status, polling metrics, and data sources.
- Implemented API routes for health checks, device status retrieval, and configuration management.
- Enhanced error handling and logging throughout the data ingestion process.
This commit is contained in:
rafaeldpsilva
2025-12-22 16:35:22 +00:00
parent ccf5f5a5c3
commit 4bedcecf5d
18 changed files with 3157 additions and 1167 deletions

View File

@@ -1,20 +1,12 @@
# MongoDB Configuration (external deployment)
# MongoDB Configuration
# Update with your MongoDB connection string
MONGO_URL=mongodb://admin:password123@mongodb-host:27017/?authSource=admin
MONGO_URL=mongodb://admin:password123@localhost:27017/?authSource=admin
# Redis Configuration (external deployment, optional)
# Update with your Redis connection string
REDIS_URL=redis://redis-host:6379
REDIS_ENABLED=false
# FTP Configuration
FTP_SA4CPS_HOST=ftp.sa4cps.pt
FTP_SA4CPS_PORT=21
FTP_SA4CPS_USERNAME=curvascarga@sa4cps.pt
FTP_SA4CPS_PASSWORD=
FTP_SA4CPS_REMOTE_PATH=/SLGs/
FTP_CHECK_INTERVAL=21600
FTP_SKIP_INITIAL_SCAN=true
# HTTP Poller Configuration
# IoT device polling settings
HTTP_POLL_INTERVAL=60
HTTP_TIMEOUT=10
HTTP_MAX_CONCURRENT=5
# Application Settings
DEBUG=false