X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=src%2Fcollectd-perl.pod;h=0f48ba58527faabc67fbd6f7bd1ca981bab8071d;hb=4027126a75439c7d2b1d5572092fd291ef19ead6;hp=90a35dafa1e996323a5508b024a8eeb51c75ae33;hpb=496a18cdae66e13d5aa3f096d1b31e92d6ba5d28;p=collectd.git diff --git a/src/collectd-perl.pod b/src/collectd-perl.pod index 90a35daf..0f48ba58 100644 --- a/src/collectd-perl.pod +++ b/src/collectd-perl.pod @@ -4,29 +4,176 @@ collectd-perl - Documentation of collectd's C =head1 SYNOPSIS - # See collectd.conf(5) LoadPlugin perl # ... IncludeDir "/path/to/perl/plugins" BaseName "Collectd::Plugin" + EnableDebugger "" LoadPlugin "FooBar" + + + Foo "Bar" + =head1 DESCRIPTION -The C includes a Perl-interpreter in collectd and provides -Perl-equivalents of the plugin-functions. This makes it possible to write -plugins for collectd in Perl. This is a lot more performant than executing a +The C embeds a Perl-interpreter into collectd and provides an +interface to collectd's plugin system. This makes it possible to write plugins +for collectd in Perl. This is a lot more efficient than executing a Perl-script every time you want to read a value with the C (see L) and provides a lot more functionality, too. +=head1 CONFIGURATION + +=over 4 + +=item B I + +Loads the Perl plugin I. This does basically the same as B would +do in a Perl program. As a side effect, the first occurrence of this option +causes the Perl-interpreter to be initialized. + +=item B I + +Prepends IB<::> to all plugin names loaded after this option. This is +provided for convenience to keep plugin names short. + +=item EB IE block + +This block may be used to pass on configuration settings to a Perl plugin. The +configuration is converted into a config-item data type which is passed to the +registered configuration callback. See below for details about the config-item +data type and how to register callbacks. + +The I identifies the callback. It is used literally and independent of +the B setting. + +=item B I[=I