Révision 5562eec2
support multiple instances of varnish
If you make a symlink like varnish4_shop_request_rate (etc.), you can
add plugin configuration
[varnish4_shop_*]
env.name shop
and it will run all commands with -n shop to get the stats for that instance.
| plugins/varnish/varnish4_ | ||
|---|---|---|
| 631 | 631 |
}, |
| 632 | 632 |
'bans_tested' => {
|
| 633 | 633 |
'type' => 'DERIVE', |
| 634 |
'min' => '0'
|
|
| 634 |
'min' => '0'
|
|
| 635 | 635 |
}, |
| 636 | 636 |
'bans_obj_killed' => {
|
| 637 | 637 |
'type' => 'DERIVE', |
| 638 |
'min' => '0'
|
|
| 638 |
'min' => '0'
|
|
| 639 | 639 |
}, |
| 640 | 640 |
'bans_tests_tested' => {
|
| 641 | 641 |
'type' => 'DERIVE', |
| 642 |
'min' => '0'
|
|
| 642 |
'min' => '0'
|
|
| 643 | 643 |
}, |
| 644 | 644 |
'bans_dups' => {
|
| 645 | 645 |
'type' => 'GAUGE' |
| ... | ... | |
| 1031 | 1031 |
{
|
| 1032 | 1032 |
$self = $0; |
| 1033 | 1033 |
$self =~ s/^.*\/varnish[0-9]?_//; |
| 1034 |
return if defined($ASPECTS{$self});
|
|
| 1035 |
# remove instance name and try again |
|
| 1036 |
$self =~ s/^.*?_//; |
|
| 1034 | 1037 |
if (!defined($ASPECTS{$self}) && @ARGV == 0) {
|
| 1035 | 1038 |
usage "No such aspect"; |
| 1036 | 1039 |
} |
Formats disponibles : Unified diff