Riemann UDP write plugin

First implementation of a riemann plugin.
This is basic for now and only support
sending to a UDP target, later work will
include notification support and service
rewriting.

Signed-off-by: Florian Forster <octo@collectd.org>
add support for notifications as well

Signed-off-by: Florian Forster <octo@collectd.org>
take into account PR comments from @octo

Signed-off-by: Florian Forster <octo@collectd.org>
riemann plugin: Improve the riemann_send() function.

Make the passed in "Msg*" const, use swrite() to make sure the entire
buffer is sent and break out the disconnect logic into an own function.
riemann plugin: Remove trailing white-space.
riemann plugin: Make all private funcitons and module-global variables "static".
riemann plugin: Move the creation of protobufs into their own function.

This also adds a couple more tags, e.g. "type:..." and so on. The "host"
field is now correctly populated from the vl->host or n->host field.
riemann plugin: Add support for service names.

I.e. you can not define a "riemann" service in /etc/services and then use
«Port "riemann"» in the configuration. Also add support for arbitrarily
long host names.
riemann plugin: Fix a double-free issue with the shared structure.

The reference to the riemann_host structure is shared between the write
and the notification callback. Upon exit, riemann_free() is called twice,
via the user_data_t structure passed to the register functions. Previously
this would have caused a double-free, which is unacceptable.

This patch introduces a reference counter and will only free the structure
(and close the socket) when the last reference is freed.

The locking has been moved out of the riemann_connect() function and into
the riemann_send() function. It is unlikely, but not impossible that two
threads interfere with each other when writing to the socket.
riemann plugin: Fix two minor bugs.
src/common.[ch]: Implement strarray_{add,free}.
riemann plugin: Use the new strarray interface to allow indefinite number of tags.
riemann plugin: Implement the "StoreRates" option.
Merge remote-tracking branch 'github-octo/pyr/riemann' into pyr/riemann
riemann plugin: Clean up the riemann_connect() function.

Don't warn when connecting to some address fails. The system could, for
example, not have any IPv6 connectivity but the address record also
includes an IPv6 address. In this case a connect(2) call will fail but
this is not a problem.

Due to the new locking one of the concurrency checks was made redundant.
write_riemann plugin: Rename the "riemann" plugin.
write_riemann plugin: Ensure a unified logging prefix.
src/collectd.conf.in: Rename "riemann" to "write_riemann".
write_riemann plugin: Unify the plugin's configuration semantic.

The "write_mongodb" and "write_redis" plugins follow the same general
config schema, i.e. <Node /> blocks with "Host" and "Port" options.
Adapt the same style for "write_riemann".
collectd.conf(5): Add documentation for the write_riemann plugin.