mirror of
https://github.com/appwrite/appwrite
synced 2026-05-24 09:28:40 +00:00
debug
This commit is contained in:
parent
5b2fdf7e5b
commit
21ef33ea45
1 changed files with 4 additions and 14 deletions
|
|
@ -124,26 +124,16 @@ App::get('/v1/health/db')
|
||||||
]);
|
]);
|
||||||
} else {
|
} else {
|
||||||
$failures[] = $database;
|
$failures[] = $database;
|
||||||
// Add failure to output instead of throwing
|
|
||||||
$output[] = new Document([
|
|
||||||
'name' => $key . " ($database)",
|
|
||||||
'status' => 'fail',
|
|
||||||
'ping' => 0
|
|
||||||
]);
|
|
||||||
}
|
}
|
||||||
} catch (\Throwable $e) {
|
} catch (\Throwable) {
|
||||||
|
var_dump($key . " ($database)",);
|
||||||
$failures[] = $database;
|
$failures[] = $database;
|
||||||
// Add failure to output instead of throwing
|
|
||||||
$output[] = new Document([
|
|
||||||
'name' => $key . " ($database)",
|
|
||||||
'status' => 'fail',
|
|
||||||
'ping' => 0
|
|
||||||
]);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!empty($failures)) {
|
if (!empty($failures)) {
|
||||||
|
|
||||||
throw new Exception(Exception::GENERAL_SERVER_ERROR, 'DB failure on: ' . implode(", ", $failures));
|
throw new Exception(Exception::GENERAL_SERVER_ERROR, 'DB failure on: ' . implode(", ", $failures));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue