Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Prometheus query - exclude destination

On my ActiveMQ I have some Queues, which end with .error. On a Grafana Dashboard I want to list all queues without these .error-queues. Example:

some.domain.one
some.domain.one.error
some.domain.two
some.domain.two.error

To list all queues I use this query:

org_apache_activemq_localhost_QueueSize{Type="Queue",Destination=~"some.domain.*",}

How do I exclude all .error-queues?

like image 722
Marco H Avatar asked Oct 27 '16 06:10

Marco H


1 Answers

You can use a negative regex matcher: org_apache_activemq_localhost_QueueSize{Type="Queue",Destination=~"some.domain.*",Destination!~".*\.error"}

like image 94
brian-brazil Avatar answered Oct 22 '22 14:10

brian-brazil