Andrew Johnson > HeliosX-Logger-Syslog-0.02_0771 > HeliosX::Logger::Syslog

Download:
HeliosX-Logger-Syslog-0.02_0771.tar.gz

Dependencies

Annotate this POD

CPAN RT

Open  0
Report a bug
Module Version: 0.02_0771   Source  

NAME ^

HeliosX::Logger::Syslog - HeliosX::Logger subclass implementing logging to syslogd for Helios

SYNOPSIS ^

 # in helios.ini
 loggers=HeliosX::Logger::Syslog
 syslog_facility=user
 # can use other options as necessary
 syslog_options=nofatal,pid 

DESCRIPTION ^

This class extends the HeliosX::Logger class to provide a shim between HeliosX::ExtLoggerService and Sys::Syslog. This will allow Helios applications using HeliosX::ExtLoggerService to log messages to syslogd.

NOTE: The base Helios system contains syslogd logging functionality, but this class enables syslogd logging with HeliosX::ExtLoggerService. An added benefit is the ability to completely turn off internal Helios logging if desired, sending log messages only to syslogd.

CONFIGURATION ^

Config options:

syslog_facility [REQUIRED]

The syslogd facility to log messages to.

syslog_options

A comma-delimited list of syslog options. This will be passed as the second parameter of openlog(). See the Sys::Syslog manpage for more details.

IMPLEMENTED METHODS ^

init()

The init() method verifies that the syslog_facility configuration parameter is set in helios.ini. Without it, HeliosX::Logger::Syslog (and Sys::Syslog) will not function properly.

logMsg($job, $priority_level, $message)

The logMsg() method logs the given message to the configured syslog_facility with the configured syslog_options and the given $priority_level.

SEE ALSO ^

HeliosX::ExtLoggerService, HeliosX::Logger

AUTHOR ^

Andrew Johnson, <lajandy at cpan dotorg>

COPYRIGHT AND LICENSE ^

Copyright (C) 2009 by Andrew Johnson

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.0 or, at your option, any later version of Perl 5 you may have available.

WARRANTY ^

This software comes with no warranty of any kind.