NAME
HPCI::Logger - This role gives the consumer a simple logger attribute
DESCRIPTION
Defines a log attribute which handles the logging methods (debug, info, warn, error, fatal). If a log attribute (of type Log::Log4perl::Logger) is not provided, one will be created automatically.
Also allows specifying the directory/file that will be used for the automatically-created log (if not log was provided), and the level of message that will be logged.
Attributes
log - A Log::Log4perl object
Used to log all cluster-control activities of HPCI.
If log is not provided, one will be created, using the log_dir and log_file attributes, or the log_path attribute to specify the file location where the log will be written.
If a log is provided, then HPCI log messages can be put into the same log as other logged aspects of the calling program.
log_path - path to file where the log will be written
Optional, only used if no log was explicitly provided. If this attribute is not provided, the following two attributes are used.
log_dir - directory where the log will be written
Optional, only used if no log was explicitly provided. Default value is group_dir
log_file - filename where the log will be written
Optional, only used if no log was explicitly provided. Default value is: "group.log"
log_level - set the log level
Accepts a Log4perl log level value, or a string which can be converted to such a value. the default is "info"