Use the log database in hybrid as well

This commit is contained in:
Owen
2026-03-21 10:42:31 -07:00
parent 6c2c620c99
commit ad2a0ae127

View File

@@ -15,6 +15,7 @@ import { verifySessionRemoteExitNodeMiddleware } from "#private/middlewares/veri
import { Router } from "express"; import { Router } from "express";
import { import {
db, db,
logsDb,
exitNodes, exitNodes,
Resource, Resource,
ResourcePassword, ResourcePassword,
@@ -1885,7 +1886,7 @@ hybridRouter.post(
const batchSize = 100; const batchSize = 100;
for (let i = 0; i < logEntries.length; i += batchSize) { for (let i = 0; i < logEntries.length; i += batchSize) {
const batch = logEntries.slice(i, i + batchSize); const batch = logEntries.slice(i, i + batchSize);
await db.insert(requestAuditLog).values(batch); await logsDb.insert(requestAuditLog).values(batch);
} }
return response(res, { return response(res, {