server: skip instances that proclaimed themself dead via HTTP 410
All checks were successful
ci/woodpecker/push/lint-foundkey-js Pipeline was successful
ci/woodpecker/push/build Pipeline was successful
ci/woodpecker/push/lint-client Pipeline was successful
ci/woodpecker/push/lint-backend Pipeline was successful
ci/woodpecker/push/test Pipeline was successful

Changelog: Fixed
This commit is contained in:
Johann150 2022-11-10 00:23:30 +01:00
parent ca90cedba0
commit 5b61941e4c
Signed by: Johann150
GPG key ID: 9EE6577A2A06F8F1

View file

@ -33,7 +33,8 @@ export async function skippedInstances(hosts: Array<Instace['host']>): Array<Ins
})
.andWhere(new Brackets(qb => { qb
.where('instance.isSuspended')
.orWhere('instance.lastCommunicatedAt < :deadTime', { deadTime });
.orWhere('instance.lastCommunicatedAt < :deadTime', { deadTime })
.orWhere('instance.latestStatus = 410');
}))
.select('host')
.getRawMany()