(QENG-7531) Add Marked as Failed Stat

This is a useful measure for monitoring the health of pools that we
don't capture yet.
This commit is contained in:
John O'Connor 2019-12-11 15:24:57 +00:00
parent ae10bd4e22
commit f581d065ae

View file

@ -104,6 +104,7 @@ module Vmpooler
if time_since_clone > timeout if time_since_clone > timeout
if exists if exists
$redis.smove('vmpooler__pending__' + pool, 'vmpooler__completed__' + pool, vm) $redis.smove('vmpooler__pending__' + pool, 'vmpooler__completed__' + pool, vm)
$metrics.increment("errors.markedasfailed.#{pool}")
$logger.log('d', "[!] [#{pool}] '#{vm}' marked as 'failed' after #{timeout} minutes") $logger.log('d', "[!] [#{pool}] '#{vm}' marked as 'failed' after #{timeout} minutes")
else else
remove_nonexistent_vm(vm, pool) remove_nonexistent_vm(vm, pool)