RE: Strange parser behavior from adding log4j

2009-01-10 Thread Mark Thomas
> From: Ken Bowen [mailto:kbo...@als.com]
> 
> Mark,
> 
> I checked out rev 733300 from /tomcat/tc6.0x/trunk, built it and the
> relase, and used an unzipped copy of apache-tomcat-6.0-snapshot.
> Unfortunately,  the same error still happens when I start up my webapp:
> 
> ERROR org.apache.commons.digester.Digester  - Parse Error at line 405
> column 17: The content of element type "struts-config" must match
> "(display-name?,description?,data-sources?,form-beans?,global-
> exceptions?,global-forwards?,action-mappings?,controller?,message-
> resources*,plug-in*)".
> org.xml.sax.SAXParseException: The content of element type "struts-
> config" must match "(display-name?,description?,data-sources?,form-
> beans?,global-exceptions?,global-forwards?,action-
> mappings?,controller?,message-resources*,plug-in*)".
>   at
> org
> .apache
> .xerces.util.ErrorHandlerWrapper.createSAXParseException(Unknown
> Source)
> ..etc...
> 
> Any other thoughts??

Hmm. A couple.

1. Is the XML file it is complaining about valid?

2. Can you build a simple test case? If so, open a bugzilla entry and attach
your test case.

Mark




-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Strange parser behavior from adding log4j

2009-01-10 Thread Ken Bowen

Mark,

I checked out rev 733300 from /tomcat/tc6.0x/trunk, built it and the  
relase, and used an unzipped copy of apache-tomcat-6.0-snapshot.

Unfortunately,  the same error still happens when I start up my webapp:

ERROR org.apache.commons.digester.Digester  - Parse Error at line 405  
column 17: The content of element type "struts-config" must match  
"(display-name?,description?,data-sources?,form-beans?,global- 
exceptions?,global-forwards?,action-mappings?,controller?,message- 
resources*,plug-in*)".
org.xml.sax.SAXParseException: The content of element type "struts- 
config" must match "(display-name?,description?,data-sources?,form- 
beans?,global-exceptions?,global-forwards?,action- 
mappings?,controller?,message-resources*,plug-in*)".
	at  
org 
.apache 
.xerces.util.ErrorHandlerWrapper.createSAXParseException(Unknown Source)

..etc...

Any other thoughts??
Thanks,
Ken

On Jan 9, 2009, at 5:17 AM, Mark Thomas wrote:


From: Ken Bowen [mailto:kbo...@als.com]

[Tomcat 6.0.18, java 1.5.0_16, struts 1.2.8]






Has anyone any thoughts on what might be happening here?


Could be a variation of
https://issues.apache.org/bugzilla/show_bug.cgi?id=45933 Can you try  
testing

with a build from trunk?

Mark



-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org




-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Strange parser behavior from adding log4j

2009-01-09 Thread Ken Bowen

Mark,

I'm more than willing.  Are there nightly jar builds, or do I need to  
set up & do the build myself?

(First time for this).

Thanks
Ken

On Jan 9, 2009, at 5:17 AM, Mark Thomas wrote:


Could be a variation of
https://issues.apache.org/bugzilla/show_bug.cgi?id=45933 Can you try  
testing

with a build from trunk?




RE: Strange parser behavior from adding log4j

2009-01-09 Thread Mark Thomas
> From: Ken Bowen [mailto:kbo...@als.com]
> 
> [Tomcat 6.0.18, java 1.5.0_16, struts 1.2.8]




> Has anyone any thoughts on what might be happening here?

Could be a variation of
https://issues.apache.org/bugzilla/show_bug.cgi?id=45933 Can you try testing
with a build from trunk? 

Mark



-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Strange parser behavior from adding log4j

2009-01-08 Thread Ken Bowen

Hi all,

[Tomcat 6.0.18, java 1.5.0_16, struts 1.2.8]

I have a struts 1.2.8 app [I know, that's antediluvian] which has been  
running fine for some time.
I'm now trying to add log4j logging to it.  I am getting an extremely  
strange side-effect when I
add a log4j.properties file to WEB-INF/classes in my app, even a very  
simple one.
When no log4j.properties file is present, my app starts and runs just  
fine.
But when I add WEB-INF/classes/log4j.properties, even as simple a file  
as


log4j.rootLogger=ERROR, stdout
log4j.appender.stdout=org.apache.log4j.ConsoleAppender
log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
log4j.appender.stdout.layout.ConversionPattern=%-4r [%t] %-5p %c %x -  
%m%n


then what happens when this is present is that I get the following  
error during startup:


4[ContainerBackgroundProcessor[StandardEngine[Catalina]]] ERROR  
org.apache.commons.digester.Digester  - Parse Error at line 405 column  
17: The content of element type "struts-config" must match "(display- 
name?,description?,data-sources?,form-beans?,global-exceptions?,global- 
forwards?,action-mappings?,controller?,message-resources*,plug-in*)".
org.xml.sax.SAXParseException: The content of element type "struts- 
config" must match "(display-name?,description?,data-sources?,form- 
beans?,global-exceptions?,global-forwards?,action- 
mappings?,controller?,message-resources*,plug-in*)".
	at  
org 
.apache 
.xerces.util.ErrorHandlerWrapper.createSAXParseException(Unknown Source)

at org.apache.xerces.util.ErrorHandlerWrapper.error(Unknown Source)
at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
	at  
org.apache.xerces.impl.dtd.XMLDTDValidator.handleEndElement(Unknown  
Source)
	at org.apache.xerces.impl.dtd.XMLDTDValidator.endElement(Unknown  
Source)
	at  
org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanEndElement(Unknown  
Source)
	at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl 
$FragmentContentDispatcher.dispatch(Unknown Source)
	at  
org 
.apache 
.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)

at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
at org.apache.commons.digester.Digester.parse(Digester.java:1745)
	at  
org 
.apache 
.struts.action.ActionServlet.parseModuleConfigFile(ActionServlet.java: 
738)
	at  
org 
.apache 
.struts.action.ActionServlet.initModuleConfig(ActionServlet.java:687)

at org.apache.struts.action.ActionServlet.init(ActionServlet.java:333)
at javax.servlet.GenericServlet.init(GenericServlet.java:212)
	at  
org 
.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java: 
1172)
	at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java: 
992)
	at  
org 
.apache 
.catalina.core.StandardContext.loadOnStartup(StandardContext.java:4058)
	at  
org.apache.catalina.core.StandardContext.start(StandardContext.java: 
4371)
	at  
org.apache.catalina.core.StandardContext.reload(StandardContext.java: 
3099)
	at  
org 
.apache 
.catalina.loader.WebappLoader.backgroundProcess(WebappLoader.java:404)
	at  
org 
.apache 
.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1309)
	at org.apache.catalina.core.ContainerBase 
$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1601)
	at org.apache.catalina.core.ContainerBase 
$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1610)
	at org.apache.catalina.core.ContainerBase 
$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1610)
	at org.apache.catalina.core.ContainerBase 
$ContainerBackgroundProcessor.run(ContainerBase.java:1590)

at java.lang.Thread.run(Thread.java:613)

It would appear that log4j is causing some different parsing tools to  
be loaded when it is present.

Here are the jars in WEB-INF/lib which I believe are x-related:

jaxen-1.1-beta-7.jar
jaxen-full.jar
jaxp-api.jar
sax.jar
saxpath.jar
xalan.jar
xerces-2.6.2.jar
xercesImpl.jar
xml-apis.jar

Has anyone any thoughts on what might be happening here?

Thanks in advance,
Ken


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org