sensu/sensu-community-plugins — pull request #878 by earthgecko (2014-11-19 18:57:45+00:00)
Title: Update haproxy-metrics.rb

Added some further details regarding the statspath setting, to make it a little clearer.

The / is actually prepended to the STATUSPATH. The manner is which the other settings work makes this a bit confusing, because the other settings replace the default. However in the context of statspath setting, it is not replaced but prepended to the resulting variable in line 104.

```
req = Net::HTTP::Get.new("/#{config[:path]};csv;norefresh")
```

This caused expected failure with a setting of:

```
./haproxy-metrics.rb --scheme stats.`hostname`.haproxy --connect `hostname` --port 8888 --statspath /haproxy_stats
```

Works:

```
./haproxy-metrics.rb --scheme stats.`hostname`.haproxy --connect `hostname` --port 8888 --statspath haproxy_stats
```