mirror of
https://github.com/puppetlabs/vmpooler.git
synced 2026-01-26 10:08:40 -05:00
'booting' metric should never be a negative number
This commit is contained in:
parent
261fdb5007
commit
c286b44553
1 changed files with 1 additions and 0 deletions
|
|
@ -51,6 +51,7 @@ get '/dashboard/stats/vcloud/numbers' do
|
|||
|
||||
result['cloning'] = $redis.get( 'vmware_host_pool__tasks__clone' )
|
||||
result['booting'] = result['pending'].to_i - result['cloning'].to_i
|
||||
result['booting'] = 0 if result['booting'] < 0
|
||||
result['total'] = result['pending'].to_i + result['ready'].to_i + result['running'].to_i + result['completed'].to_i
|
||||
|
||||
content_type :json
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue