Hi,

yesterday we had a problem with the configuration: getLogger returned a logger with the configuration of the root-logger:

$logger = array(
        'appenders' => array(
               'default' => array(
                      'class' => 'LoggerAppenderFile',
                      'layout' => array(
                             'class' => 'LoggerLayoutTTCC',
                      ),
                      'params' => array(
                             'file' => 'logs/file.log',
                             'append' => true
                      ),
               ),
               'productManager' => array(
                             'class' => 'LoggerAppenderFile',
                             'layout' => array(
                                           'class' => 'LoggerLayoutTTCC',
                             ),
                             'params' => array(
'file' => 'logs/productManager.log',
                                           'append' => true
                             ),
               ),
        ),
        'rootLogger' => array(
               'appenders' => array('default'),
        ),
        'productManagerLogger' => array(
                      'additivity' => false,
                      'appenders' => array('productManager'),
        ),
);

We have forgot the option 'logger' under 'rootLogger'. It is maybe better to trigger a notice 'you have called an unkown logger', than to return a logger with the configuration of the root-logger. To locate the error would be much easier.


Regards,

Florian

Reply via email to