Lighten library cache reports and heartbeat cleanup

This commit is contained in:
2026-10-05 15:51:55 -04:00
parent 847399a4ff
commit c8c53e87d6
5 changed files with 127 additions and 3 deletions
+1 -2
View File
@@ -2,7 +2,7 @@ import { json } from '@sveltejs/kit';
import { heartbeat, pendingCreationCancellations } from '$lib/server/hosts/index.js';
import { authenticateAgent, hostApiError, objectBody } from '$lib/server/hosts/http.js';
import { reconcileHostPreparation } from '$lib/server/hosts/preparation.js';
import { reconcileHostLibraryCleanup, cleanupControllerLibraries } from '$lib/server/game-files/index.js';
import { reconcileHostLibraryCleanup } from '$lib/server/game-files/index.js';
import { fleetSettings } from '$lib/server/settings.js';
export async function POST({ request }: { request: Request }) {
const authenticated = authenticateAgent(request);
@@ -16,7 +16,6 @@ export async function POST({ request }: { request: Request }) {
}
reconcileHostPreparation(host.id);
reconcileHostLibraryCleanup(host.id);
await cleanupControllerLibraries();
return json({ host, cancelledCreations: pendingCreationCancellations(host.id), heartbeatSeconds: 15,
observationKeepDays: fleetSettings().observationKeepDays, serverTime: new Date().toISOString() });
} catch (cause) { return hostApiError(cause); }