[ 
https://issues.apache.org/jira/browse/LOG4PHP-110?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12872139#action_12872139
 ] 

Vladimir Gorej commented on LOG4PHP-110:
----------------------------------------

Hello Christian,

The reason for getting rid of arrays as constructor param is that, i was 
studuying the log4j and log4php and I did not find any reasonable argument why 
arrays should be passed to the ThrowableInformation class as an constructor 
argument. The only throwable representantation in PHP is Exception and all its 
descendants. I see no reason why anybody would want to log arrays as throwables 
(Exception).

My seconds argument concerns - public function Logger::forcedLog($fqcn, 
$caller, $level, $message) 

We can only tell if $caller is throwable (Exception) or not, by testing its 
type..if the $caller is array there is no way to tel if it is some custom user 
array or array that was 
created by conversion from Exception. 

If the caller is of type Exception the worflow is pretty straightforward.

This is the link to original ThrowableInformation class : 
http://svn.apache.org/viewvc/logging/log4j/trunk/src/main/java/org/apache/log4j/spi/ThrowableInformation.java?view=markup
Maybe developers implemented constructor public ThrowableInformation(final 
String[] r) just for testing purposes. I can look at it event deeper if you 
have still some doubts.

> mongo database appender for log4php
> -----------------------------------
>
>                 Key: LOG4PHP-110
>                 URL: https://issues.apache.org/jira/browse/LOG4PHP-110
>             Project: Log4php
>          Issue Type: New Feature
>          Components: Code, Documentation, Tests
>    Affects Versions: 2.0
>         Environment: PHP
>            Reporter: Vladimir Gorej
>            Assignee: Christian Grobmeier
>             Fix For: 2.1
>
>         Attachments: src.tgz, throwable.path
>
>
> mongo database appender for log4php with unit test coverage

-- 
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