Bug #184
closedQuery 'state' doesn't work
Description
According to the web UI:
Out Of Sync Hosts 23
Hosts in Error State 4
Total hosts 204
(For the queries below, the web ui shows 198 hosts in 'base', 15 in 'memcached')
The query interface isn't reflecting that:
Memcached runs every 6 ours, so this test is ok:irb(main):049:0> gethosts( { 'class' => 'memcached' } ).length
NoMethodError: undefined method `length' for nil:NilClass
from (irb):49
from :0
This test is not though, should list 15 hosts:irb(main):050:0> gethosts( { 'class' => 'memcached', 'state' => 'all' } ).length
NoMethodError: undefined method `length' for nil:NilClass
from (irb):50
from :0
Should list 175 hosts:irb(main):052:0> gethosts( { 'class' => 'base' } ).length
=> 175
Should list 198 hosts:irb(main):051:0> gethosts( { 'class' => 'base', 'state' => 'all' } ).length
=> 175
Should list 204 hosts:irb(main):053:0> gethosts( { 'state' => 'all' } ).length
NoMethodError: undefined method `length' for nil:NilClass
from (irb):53
from :0
Updated by Ohad Levy almost 15 years ago
can you add a simple fact, just to be sure that the lack of fact usage doesnt break something?
Updated by Dis Connect almost 15 years ago
It works with the addition of a fact.
Updated by Ohad Levy almost 15 years ago
- Assignee set to Ohad Levy
- Target version set to 0.1-5