Fix logic for critical_threshold to match the documentation
Change-Id: I1ac031106d487d61688207c714911fd91d1a717f
This commit is contained in:
parent
6f41c6ee84
commit
a262c243d2
|
@ -134,7 +134,7 @@ def evaluate_results(response, args):
|
|||
crit_message = ('Found %s >= %s(threshold) occurrences within the last %s minute(s). %s')
|
||||
message = ('Found %s >= %s(threshold) occurrences within the last %s minute(s).')
|
||||
ok_message = ('Found %s [threshold: %s] occurrences within the last %s minute(s).')
|
||||
if hits > args.critical_threshold:
|
||||
if hits >= args.critical_threshold:
|
||||
if args.simple_query_fields:
|
||||
allmsgs = ', '.join([m["_source"][args.simple_query_fields] for m in results['hits']['hits']])
|
||||
NagiosUtil.service_critical(crit_message % (str(hits), args.critical_threshold, args.range, allmsgs))
|
||||
|
|
Loading…
Reference in New Issue