You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-dev@logging.apache.org by bu...@apache.org on 2007/08/23 18:00:09 UTC
DO NOT REPLY [Bug 43200] New: - Log4JEntityResolver will return null if log4j.dtd resource can not be found
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=43200>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=43200
Summary: Log4JEntityResolver will return null if log4j.dtd
resource can not be found
Product: Log4j
Version: 1.2
Platform: Other
OS/Version: other
Status: NEW
Severity: normal
Priority: P2
Component: Configurator
AssignedTo: log4j-dev@logging.apache.org
ReportedBy: carnold@apache.org
If log4j.dtd can't be found by getResourceAsStream() (likely running in an IDE as described on log4j-dev
on 2007-08-23 by Scott Deboy), Log4JEntityResolver would return null which would result in the parser
attempting to locate the resource using the URL. The change causes Log4JEntityResolver to return an
InputSource backed by an empty ByteArrayInputStream which will prevent the parser from trying to locate
log4j.dtd on its own.
--
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-dev-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-dev-help@logging.apache.org
DO NOT REPLY [Bug 43200] - Log4JEntityResolver will return null if log4j.dtd resource can not be found
Posted by bu...@apache.org.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=43200>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=43200
------- Additional Comments From carnold@apache.org 2007-08-23 11:30 -------
That would be as expected, LogLog.error is still called if the resource could not be found. The thing that
changed was instead of returning null which tells the parser to try to find it on its own, an empty
InputSource is returned which will prevent the parser to try to find it on its own. So hopefully you lost the
exception from the parser when it could not find log4j.dtd. Could downgrade it from a LogLog.error to a
LogLog.warn.
There are two issues here: one is what do in the case that the resource can not be found. Other than
potentially downgrading the message to a LogLog.warn, I think the fix is good. The other is why you can't
find the resource and there isn't enough to go on for me to figure that out and to decide if it is a log4j
issue or a IDE project issue.
--
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-dev-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-dev-help@logging.apache.org
DO NOT REPLY [Bug 43200] - Log4JEntityResolver will return null if log4j.dtd resource can not be found
Posted by bu...@apache.org.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=43200>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=43200
------- Additional Comments From sdeboy@iname.com 2007-08-23 10:26 -------
Just tried the xml-based appender/receivers in Chainsaw in an IDE without log4j
src/main/resources in my classpath - I still get an error:
'log4j:ERROR Could not find [log4j.dtd]. Used
[sun.misc.Launcher$AppClassLoad@...] class loader in the search.
--
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-dev-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-dev-help@logging.apache.org
DO NOT REPLY [Bug 43200] - Log4JEntityResolver will return null if log4j.dtd resource can not be found
Posted by bu...@apache.org.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=43200>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=43200
carnold@apache.org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |FIXED
------- Additional Comments From carnold@apache.org 2007-10-23 11:41 -------
Changes committed rev 569053 and 569147 and released in log4j 1.2.15.
--
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-dev-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-dev-help@logging.apache.org