mirror of
https://github.com/munin-monitoring/contrib.git
synced 2025-07-21 18:41:03 +00:00
Fix geowebcache-cache-hits-ratio
This commit is contained in:
parent
f6738f415e
commit
5a37346602
1 changed files with 5 additions and 5 deletions
|
@ -1,10 +1,10 @@
|
||||||
#!/usr/bin/perl
|
#!/usr/bin/perl
|
||||||
# -*- perl -*-
|
# -*- perl -*-
|
||||||
|
|
||||||
# Author Rodolphe Quiédeville <rodolphe@quiedeville.org>
|
# Author Rodolphe Quiédeville <rodolphe@quiedeville.org>
|
||||||
# Licence : GPLv2
|
# Licence : GPLv2
|
||||||
# Code based on tomcat_volume plugin by
|
# Code based on tomcat_volume plugin by
|
||||||
# Rune Nordbøe Skillingstad <runesk@linpro.no>
|
# Rune Nordbøe Skillingstad <runesk@linpro.no>
|
||||||
|
|
||||||
=head1 NAME
|
=head1 NAME
|
||||||
|
|
||||||
|
@ -41,7 +41,7 @@ HTTP port numbers
|
||||||
|
|
||||||
=head1 AUTHOR
|
=head1 AUTHOR
|
||||||
|
|
||||||
Rodolphe Quiédeville <rodolphe@quiedeville.org>
|
Rodolphe Quiédeville <rodolphe@quiedeville.org>
|
||||||
|
|
||||||
=head1 USAGE
|
=head1 USAGE
|
||||||
|
|
||||||
|
@ -111,8 +111,8 @@ if(exists $ARGV[0] and $ARGV[0] eq "config") {
|
||||||
my $ua = LWP::UserAgent->new(timeout => $TIMEOUT);
|
my $ua = LWP::UserAgent->new(timeout => $TIMEOUT);
|
||||||
my $response = $ua->request(HTTP::Request->new('GET',$url));
|
my $response = $ua->request(HTTP::Request->new('GET',$url));
|
||||||
|
|
||||||
if ($response->content =~ '<tr><td colspan="5"> </td></tr><tr><td colspan="2">Cache hit ratio:</td><td colspan="3">(\d\d?\.?\d+)% of requests</td></tr>' ) {
|
if ($response->content =~ '<tr><th colspan="2" scope="row">Cache hit ratio:</th><td colspan="3">(\d+\.\d+)% of requests</td></tr>' ) {
|
||||||
print "ratio.value " . $1;
|
print "ratio.value " . $1 . "\n";
|
||||||
} else {
|
} else {
|
||||||
print "ratio.value U\n";
|
print "ratio.value U\n";
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue