refactor: remove legacy scheduling and analytics code

- Deleted the scheduler module and its associated functions, transitioning to OS-level scheduling.
- Removed the Analytics module and its related interfaces, retaining only a placeholder for backward compatibility.
- Updated ConfigValidator to warn about legacy schedule and analytics configurations.
- Cleaned up StartupValidator to remove diagnostics and schedule validation logic.
- Adjusted Load.ts to handle legacy flags for diagnostics and analytics.
- Removed unused diagnostics capturing functionality.
This commit is contained in:
2025-11-03 19:18:09 +01:00
parent 67006d7e93
commit 43ed6cd7f8
39 changed files with 415 additions and 1494 deletions

View File

@@ -1,12 +1,12 @@
#!/bin/bash
set -e
# Docker entrypoint with cron support
# Docker entrypoint with optional cron support
# Usage:
# Default (scheduler): npm run start:schedule
# Default: node --enable-source-maps ./dist/index.js
# Cron mode: set USE_CRON=true
# If USE_CRON is set, configure cron instead of using built-in scheduler
# If USE_CRON is set, configure cron for repeated runs
if [ "$USE_CRON" = "true" ] || [ "$USE_CRON" = "1" ]; then
echo "==> Cron mode enabled"
@@ -57,10 +57,10 @@ if [ "$USE_CRON" = "true" ] || [ "$USE_CRON" = "1" ]; then
# Start cron in foreground and tail logs
cron && tail -f /var/log/cron.log
else
echo "==> Using built-in scheduler (JavaScript)"
echo "==> To use cron instead, set USE_CRON=true"
echo "==> Running single execution"
echo "==> To run on a schedule inside the container, set USE_CRON=true"
echo ""
# Execute passed command (default: npm run start:schedule)
# Execute passed command (default: node --enable-source-maps ./dist/index.js)
exec "$@"
fi