[document-updater] trigger graceful shutdown on unhandled error (#31027)

GitOrigin-RevId: dde99528bfbc1d33f392a52fa8eaf5d4e82266b3
This commit is contained in:
Jakob Ackermann
2026-01-26 16:37:01 +00:00
committed by Copybot
parent c876bf2c5f
commit d5936d8566

View File

@@ -299,6 +299,11 @@ for (const signal of [
process.on(signal, shutdownCleanly(signal))
}
process.on('uncaughtException', function (err) {
logger.error({ err }, 'uncaught exception')
shutdownCleanly('uncaughtException')()
})
function longerTimeout(req, res, next) {
res.setTimeout(6 * 60 * 1000)
next()