feat(monitoring): add date range filtering and log cleanup scheduling

- Implement date range filtering for access logs and request statistics
- Add log cleanup scheduling with configurable cron expression
- Update UI components to support date range selection
- Refactor log processing and parsing to handle date filtering
- Add new database migration for log cleanup cron configuration
- Remove deprecated log rotation management logic
This commit is contained in:
Mauricio Siu
2025-03-08 14:20:27 -06:00
parent b64ddf1119
commit 673e0a6880
15 changed files with 5620 additions and 202 deletions

View File

@@ -12,6 +12,7 @@ import { runMongoBackup } from "./mongo";
import { runMySqlBackup } from "./mysql";
import { runPostgresBackup } from "./postgres";
import { findAdmin } from "../../services/admin";
import { startLogCleanup } from "../access-log/handler";
export const initCronJobs = async () => {
console.log("Setting up cron jobs....");
@@ -168,4 +169,8 @@ export const initCronJobs = async () => {
}
}
}
if (admin?.user.logCleanupCron) {
await startLogCleanup(admin.user.logCleanupCron);
}
};