mirror of
https://github.com/munin-monitoring/contrib.git
synced 2025-07-24 18:07:20 +00:00
Whitespace cleanup
* remove trailing whitespace * remove empty lines at the end of files
This commit is contained in:
parent
ef851f0c34
commit
17f784270a
604 changed files with 2927 additions and 2945 deletions
|
@ -1,14 +1,14 @@
|
|||
#!/usr/bin/perl
|
||||
use strict;
|
||||
|
||||
# HTTP response times for either entire page views
|
||||
# HTTP response times for either entire page views
|
||||
# or just the index, depending on configuration.
|
||||
# Full or index resource pulling is determined by the suffix of the
|
||||
# Full or index resource pulling is determined by the suffix of the
|
||||
# script name. ie. http_response_full or http_response_index
|
||||
#
|
||||
|
||||
# Parameters:
|
||||
#
|
||||
#
|
||||
# config
|
||||
#
|
||||
# Configuration variables:
|
||||
|
@ -52,13 +52,13 @@ if (! @urls) {
|
|||
|
||||
#output configuration and exit - required by Munin
|
||||
if (exists $ARGV[0] and $ARGV[0] eq "config") {
|
||||
print "graph_title $domain Site Response Times - $ENV{'action'}\n";
|
||||
print "graph_title $domain Site Response Times - $ENV{'action'}\n";
|
||||
print "graph_category webserver\n";
|
||||
print "graph_vlabel request time (seconds)\n";
|
||||
print "graph_info Response times for public areas of $domain.\n";
|
||||
|
||||
foreach my $url (@urls) {
|
||||
my $label = $url;
|
||||
my $label = $url;
|
||||
#fix up our label name to be a valid variable name
|
||||
$label =~ s@[^A-Za-z0-9_]@_@g;
|
||||
print "$label.label $url\n";
|
||||
|
@ -73,7 +73,7 @@ if (exists $ARGV[0] and $ARGV[0] eq "config") {
|
|||
|
||||
#function to make the request and get the response time
|
||||
sub req_time {
|
||||
my $url = shift;
|
||||
my $url = shift;
|
||||
my $time;
|
||||
my $outdir = '/tmp/munin/' . int(rand(32000));
|
||||
system("mkdir -p $outdir");
|
||||
|
@ -88,7 +88,7 @@ sub req_time {
|
|||
|
||||
#loop over every url and output the responses
|
||||
foreach my $url (@urls) {
|
||||
my $label = $url;
|
||||
my $label = $url;
|
||||
#fix up our label name to be a valid name
|
||||
$label =~ s@[^A-Za-z0-9_]@_@g;
|
||||
print "$label.value " . req_time($domain.$url);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue