Revert "Revert "feat: add-healthcheck""

This commit is contained in:
Charles GTE
2026-03-28 16:35:02 +01:00
committed by GitHub
parent 1d209ceb28
commit 04785c323b
53 changed files with 19942 additions and 1337 deletions
+11 -1
View File
@@ -13,6 +13,7 @@ export type databaseAgent = {
name: string,
dbms: EDbmsSchema,
generatedId: string
pingStatus: boolean
}
export type Body = {
@@ -62,10 +63,19 @@ export async function POST(
.update(drizzleDb.schemas.agent)
.set(withUpdatedAt({
version: body.version,
lastContact: lastContact
lastContact: lastContact,
healthErrorCount: null
}))
.where(eq(drizzleDb.schemas.agent.id, agentId));
await db
.insert(drizzleDb.schemas.healthcheckLog)
.values({
kind: "agent",
status: "success",
objectId: agentId,
date: lastContact
})
const response = {
agent: {