add unit to some perfdatas
This commit is contained in:
parent
4233b497ef
commit
bcf4e19365
|
@ -63,7 +63,7 @@ sub set_counters {
|
||||||
key_values => [ { name => 'disk_used' } ],
|
key_values => [ { name => 'disk_used' } ],
|
||||||
output_template => "Disk used: %d ",
|
output_template => "Disk used: %d ",
|
||||||
perfdatas => [
|
perfdatas => [
|
||||||
{ label => 'disk_used', value => 'disk_used', template => '%d', min => 0 }
|
{ label => 'disk_used', value => 'disk_used', template => '%d', unit => 'o', min => 0 }
|
||||||
],
|
],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -71,7 +71,7 @@ sub set_counters {
|
||||||
key_values => [ { name => 'disk_usage' } ],
|
key_values => [ { name => 'disk_usage' } ],
|
||||||
output_template => "Disk usage: %d %%",
|
output_template => "Disk usage: %d %%",
|
||||||
perfdatas => [
|
perfdatas => [
|
||||||
{ label => 'disk_usage', value => 'disk_usage', template => '%d', min => 0 }
|
{ label => 'disk_usage', value => 'disk_usage', template => '%.2f', unit => '%', min => 0 }
|
||||||
],
|
],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
|
@ -80,7 +80,7 @@ sub set_counters {
|
||||||
sub prefix_output_balances {
|
sub prefix_output_balances {
|
||||||
my ($self, %options) = @_;
|
my ($self, %options) = @_;
|
||||||
|
|
||||||
return "*Balance* '" . $options{instance_value}->{display} . "' ";
|
return "Balance '" . $options{instance_value}->{display} . "' ";
|
||||||
}
|
}
|
||||||
|
|
||||||
sub prefix_output_events {
|
sub prefix_output_events {
|
||||||
|
|
|
@ -36,7 +36,7 @@ sub new {
|
||||||
'stats' => 'blockchain::parity::ethpoller::mode::stats',
|
'stats' => 'blockchain::parity::ethpoller::mode::stats',
|
||||||
'disk' => 'blockchain::parity::ethpoller::mode::disk',
|
'disk' => 'blockchain::parity::ethpoller::mode::disk',
|
||||||
'tracking' => 'blockchain::parity::ethpoller::mode::tracking',
|
'tracking' => 'blockchain::parity::ethpoller::mode::tracking',
|
||||||
'prct' => 'blockchain::parity::ethpoller::mode::prct'
|
# 'prct' => 'blockchain::parity::ethpoller::mode::prct'
|
||||||
);
|
);
|
||||||
$self->{custom_modes}{api} = 'blockchain::parity::ethpoller::custom::api';
|
$self->{custom_modes}{api} = 'blockchain::parity::ethpoller::custom::api';
|
||||||
return $self;
|
return $self;
|
||||||
|
|
|
@ -97,7 +97,7 @@ sub set_counters {
|
||||||
key_values => [ { name => 'block_usage' } ],
|
key_values => [ { name => 'block_usage' } ],
|
||||||
output_template => "Block usage: %d %%",
|
output_template => "Block usage: %d %%",
|
||||||
perfdatas => [
|
perfdatas => [
|
||||||
{ label => 'block_usage', value => 'block_usage', template => '%d', min => 0 }
|
{ label => 'block_usage', value => 'block_usage', template => '%.2f', unit => '%', min => 0 }
|
||||||
],
|
],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
|
@ -56,7 +56,7 @@ sub set_counters {
|
||||||
key_values => [ { name => 'mempool_usage' } ],
|
key_values => [ { name => 'mempool_usage' } ],
|
||||||
output_template => "Mempool usage: %d %% ",
|
output_template => "Mempool usage: %d %% ",
|
||||||
perfdatas => [
|
perfdatas => [
|
||||||
{ label => 'mempool_usage', value => 'mempool_usage', template => '%d', min => 0 }
|
{ label => 'mempool_usage', value => 'mempool_usage', template => '%.2f', unit => '%', min => 0 }
|
||||||
],
|
],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -83,7 +83,7 @@ sub set_counters {
|
||||||
key_values => [ { name => 'peers_usage' } ],
|
key_values => [ { name => 'peers_usage' } ],
|
||||||
output_template => "Peers usage: %d %% ",
|
output_template => "Peers usage: %d %% ",
|
||||||
perfdatas => [
|
perfdatas => [
|
||||||
{ label => 'peers_usage', value => 'peers_usage', template => '%d', min => 0 }
|
{ label => 'peers_usage', value => 'peers_usage', template => '%.2f', unit => '%', min => 0 }
|
||||||
],
|
],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in New Issue