anchor.diff:        ValuesFrom "value"
       </Result>
     </Query>
  -  <Query "services_down">
  +  <Query "<%= @dbname %>_<%= @type %>_down">
       Statement "select concat_ws('.', 'services', replace(replace(s1.binary, 'nova-', ''), 'cinder-', ''), 'down') as metric, count(s2.id) as value from (select * from services where deleted=0) s1 left outer join services s2 on s1.id = s2.id and s1.disabled=0 and timestampdiff(SECOND,s1.updated_at,utc_timestamp())><%= @downtime %> group by s1.binary;"
       MinVersion 50000
       <Result>
  
positive.code:     DriverOption "password" "<%= @password %>"
      DriverOption "dbname" "<%= @dbname %>"
      SelectDB "<%= @dbname %>"
      Query "<%= @type %>_disabled"
      Query "<%= @type %>_up"
      Query "<%= @type %>_down"
      Query "<%= @type %>"
    </Database>
  </Plugin>
  
negative.code:       ValuesFrom "value"
      </Result>
    </Query>
    <Query "<%= @dbname %>_<%= @type %>_up">
      Statement "select concat_ws('.', 'agents', replace(replace(a1.binary, '-agent', ''), 'neutron-', ''), 'up') as metric, count(a2.id) as value from agents a1 left outer join agents a2 on a1.id = a2.id and a1.admin_state_up=1 and timestampdiff(SECOND,a1.heartbeat_timestamp,utc_timestamp())<=<%= @downtime %>  group by a1.binary;"
      MinVersion 50000
      <Result>
  