2016-10-27 48 views
0

在我的ActiveMQ上,我有一些以.error結尾的隊列。在Grafana儀表板上,我想列出沒有這些錯誤隊列的所有隊列。 例子:普羅米修斯查詢 - 排除目的地

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

要列出所有隊列我使用此查詢:

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

如何排除所有.error隊列?

回答

1

您可以使用正則表達式負匹配:org_apache_activemq_localhost_QueueSize{Type="Queue",Destination=~"some.domain.*",Destination!~".*\.error"}

+0

酷,THX。我不知道我可以更頻繁地指定目的地。這對我現在有效:'org_apache_activemq_localhost_ConsumerCount {Type =「Queue」,Destination =〜「some.domain。*」,Destination!〜「。* error」}' –