enh(iplabel-ekara): change status match and timeframe option default value (#5429)

Refs: CTOR-1387
This commit is contained in:
Lucie Dubrunfaut 2025-02-06 09:53:49 +01:00 committed by GitHub
parent ee48767a11
commit 5751ee1bfd
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 8 additions and 6 deletions

View File

@ -61,8 +61,9 @@ sub set_counters {
$self->{maps_counters}->{global} = [
{ label => 'scenario-status',
type => 2,
warning_default => '%{status} !~ "Success"',
warning_default => '%{status} =~ /(Aborted|Stopped|Excluded|Degraded)/',
critical_default => '%{status} =~ "Failure"',
unknown_default => '%{status} =~ /(Unknown|No execution)/',
set => {
key_values => [ { name => 'status' }, { name => 'num_status' }, { name => 'display' } ],
closure_custom_output => $self->can('custom_status_output'),
@ -133,7 +134,7 @@ sub check_options {
my ($self, %options) = @_;
$self->SUPER::check_options(%options);
$self->{timeframe} = defined($self->{option_results}->{timeframe}) && $self->{option_results}->{timeframe} ne '' ? $self->{option_results}->{timeframe} : '900';
$self->{timeframe} = defined($self->{option_results}->{timeframe}) && $self->{option_results}->{timeframe} ne '' ? $self->{option_results}->{timeframe} : '7500';
}
my $status_mapping = {
@ -220,10 +221,10 @@ Check ip-label Ekara scenarios.
=item B<--timeframe>
Set timeframe period in seconds. (default: 900)
Example: --timeframe='3600' will check the last hour
Set timeframe period in seconds. (default: 7500)
Example: C<--timeframe='3600'> will check the last hour.
Note: If the API/Poller is overloaded, it is preferable to refine
this value according to the highest check frequency in the scenario.
=item B<--filter-type>

View File

@ -66,6 +66,7 @@ dfsrevent
--display-transform-src
dns-resolve-time
--dyn-mode
Ekara
-EncodedCommand
env
ESX