Refresh HiveGrid Cloud reference snapshot
This commit is contained in:
1 parent
5e99e14772
commit
7f88026f79
5955 files changed
+1177325
-188362
No files matched your search
@@ -8,11 +8,14 @@
|
||||
* that need one compact web-process + dependency signal.
|
||||
*/
|
||||
import { db } from "~/utils/db.server";
|
||||
import { checkCachedWebReadiness } from "~/utils/readiness-cache.server";
|
||||
|
||||
const checkDatabase = () => db.appConfiguration.count();
|
||||
|
||||
export async function loader(): Promise<Response> {
|
||||
let dbStatus: "ok" | "down" = "ok";
|
||||
try {
|
||||
await db.appConfiguration.count();
|
||||
await checkCachedWebReadiness(checkDatabase);
|
||||
} catch {
|
||||
dbStatus = "down";
|
||||
}
|
||||
@@ -26,6 +29,6 @@ export async function loader(): Promise<Response> {
|
||||
uptime_seconds: Math.round(process.uptime()),
|
||||
region: process.env.APP_REGION?.trim() || process.env.FLY_REGION?.trim() || "unknown",
|
||||
},
|
||||
{ status: overall === "ok" ? 200 : 503 },
|
||||
{ status: overall === "ok" ? 200 : 503 }
|
||||
);
|
||||
}
|
||||
Reference in new issue
Block a user