NAME
Log::Handler::Changes - Changes from 0.38 to 0.45.
WHAT IS NEW, WHAT IS DEPRECATED
More than one output
Since version 0.40 the method "add()" is totaly new. With this method you can add outputs as much as you wish, each with its own level range and different other options. As example you can add a output for the levels 0-4 (emergency-warning) and another output for the levels 4-7 (warning-debug). Each output is handled as a own object.
Outputs
There are different output modules available:
Log::Handler::Output::DBILog::Handler::Output::EmailLog::Handler::Output::FileLog::Handler::Output::ForwardLog::Handler::Output::ScreenLog::Handler::Output::Socket
You can add the outputs on different ways. Take a look to the further documentation of Log::Handler.
Message layout
Placeholders are now available for the message layout in "printf()" style. The old style of <--LEVEL--> is deprecated and you should use %L instead. The layout can be defined with the option "message_layout".
The option "prefix" is deprecated.
Configuration file
Now it's possible to load the configuration from a file. There are 3 configuration plugins available:
Config::GeneralConfig::PropertiesYAML
Take a look into the documentation for Log::Handler::Config.
New options
dateformatprioritymessage_patternprepare_messagefilter_messagefilter_calleralias
Changed options
prefix is now message_layoutdebug is now debug_trace
Kicked options
rewrite_to_stderr
New methods
add() to add new outputsconfig() to load outputs from a configuration fileset_pattern() to create your own placeholderoutput() to get a output object with an aliasflush() to flush all outputs
New level methods
Please take a look to Log::Handler::Levels because the list is very long.
Kicked methods
note()close()get_prefix()set_prefix()
Backward compatibilities
As I re-designed "Log::Handler" it was my wish to support all things from version 0.38.
my $log = Log::Handler->new(filename => 'file.log');
This is still running fine. It creates a "Log::Handler::Simple" object with all features of "Log::Handler" from version 0.38.
Further releases
Extensions and changes are planed. I hope I have enough time to implement my ideas as soon as possible!
AUTHOR
Jonny Schulz <jschulz.cpan(at)bloonix.de>.