Alerting
Questions about alerting and problem detection in Dynatrace.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

how to exclude 403 from fourxx error for metric selector

padarthimanoj
Newcomer

i want to exclude 403 from this metric selector of query queryDefinition for API yaml

 

builtin:service.keyRequest.errors.fourxx.count:filter(and(or(in("dt.entity.service_method",entitySelector("type(service_method),entityName.equals(~"<my-api-url>~")"))))):splitBy():sort(value(auto,descending)):limit(20)

 

i have tried this 

builtin:service.keyRequest.errors.fourxx.count:filter(and(ne("http.status",403),or(in("dt.entity.service_method",entitySelector("type(service_method),entityName.equals(~"<my-api-url>~")"))))):splitBy():sort(value(auto,descending)):limit(20)

 

but i am getting error that http.status is not a valid dimension. we are using dyntrace classic

 

is it possible through queryDefinition or any other setting configuration is required ?

 

 

1 REPLY 1

Julius_Loman
DynaMight Legend
DynaMight Legend

It simple - you cannot. This classic metric sums all 4xx codes already.
If you need any other behaviour, there are multiple ways. Probably I'd go with defining a calculated service metric for this purpose.

If you are on SaaS, the Grail metric has the dimension:

timeseries sum(dt.service.request.failure_count), by: { http.response.status_code }

 

Certified Dynatrace Master | Alanata a.s., Slovakia, Dynatrace Master Partner

Featured Posts