[ 
https://issues.apache.org/jira/browse/LOG4PHP-105?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ivan Habunek updated LOG4PHP-105:
---------------------------------

    Attachment: LoggerMDC.refactor.patch
                LoggerMDCTest.patch

I refactored the LoggerMDC class and created tests (100% code coverage).

Change log for LoggerMDC:
* Moved mappings from a global variable to a private variable within the 
LoggerMDC class
* Removed need for error suppression (@) in get method, error suppression is 
not a best practice in PHP
* Changed access to environment vars from @_ENV['var'] to getenv('var'), 
because $_ENV is not populated on systems where environment variable hashing is 
disabled in php.ini (by ommiting "E" from the variables_order directive). I 
encountered this problem just by using the php.ini-recommended which comes with 
PHP.

> LoggerMDC needs refactoring
> ---------------------------
>
>                 Key: LOG4PHP-105
>                 URL: https://issues.apache.org/jira/browse/LOG4PHP-105
>             Project: Log4php
>          Issue Type: Improvement
>          Components: Code
>    Affects Versions: 2.2
>            Reporter: Christian Grobmeier
>             Fix For: 2.3
>
>         Attachments: LoggerMDC.refactor.patch, LoggerMDCTest.patch
>
>
> http://ci.apache.org/projects/log4php/coverage-report/LoggerMDC.php.html
> This class still has global vars and needs some tweaks in general. Also there 
> are no test cases in the repos at the moment

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to