This commit is contained in:
seb
2026-10-18 20:48:50 +02:00
parent c06a5e3413
commit a717a05e8d
10 changed files with 294 additions and 11 deletions

View File

@@ -19,6 +19,7 @@ import { createLogger } from '../util/logger.js';
import v1Router from '../v1/index.js';
import { startBackendMonitor, stopBackendMonitor, isDevMode } from '../backendmonitor/server.js';
import { startBackupService, stopBackupService } from '../services/backupService.js';
import { startHealthMonitorService, stopHealthMonitorService } from '../services/healthMonitorService.js';
const apiLog = createLogger('api');
@@ -252,6 +253,12 @@ export async function startApi() {
apiLog.error('Failed to start Backup Service:', err.message);
}
try {
startHealthMonitorService();
} catch (err) {
apiLog.error('Failed to start Health Monitor Service:', err.message);
}
return server;
})();
@@ -275,6 +282,7 @@ export async function stopApi() {
// Same for the pooled sandbox threads that run `javascript_execute` / applets.
await shutdownJavascriptSandboxWorkers();
await stopBackupService();
await stopHealthMonitorService();
const closers = [];
if (server) {
const s = server;