You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@forrest.apache.org by Ferdinand Soethe <fe...@apache.org> on 2006/01/19 12:08:59 UTC

Forrest 0.7x war throws Execption in Tomcat 4

Today we tried to run our community college application
(www.bildungsverein.de) in a Tomcat-Server planning to do a load and
long term run test.

- Using Forrest 0.7x (current patch) we did
  forrest war
- then placed the application on a Tomcat version 4.0

Unfortunately the test was rather short, after accessing just a few pages the
application hung after and exception

java.lang.NoClassDefFoundError: org/w3c/dom/svg/SVGDocument

(log attached below).

I searched the lists but - to be honest - understood hardly any of
what was discussed, so forgive me if this is a documented problem.

- Is this to be expected?
- Do we need a newer version of Tomcat (I didn't find any doc on
  required version)?
- Any other ideas what we need to do to fix this?

Thanks,
Ferdinand

-----------------

2006-01-19 10:55:14 StandardWrapperValve[Cocoon]: Servlet.service() for
servlet Cocoon threw exception
javax.servlet.ServletException: Servlet execution threw an exception
         at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
         at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193)
         at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:243)
         at 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
         at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
         at 
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
         at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:190)
         at 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
         at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
         at 
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
         at 
org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2343)
         at 
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180)
         at 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
         at 
org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:170)
         at 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
         at 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:170)
         at 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
         at 
org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:468)
         at 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
         at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
         at 
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
         at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:174)
         at 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
         at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
         at 
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
         at 
org.apache.catalina.connector.http.HttpProcessor.process(HttpProcessor.java:1012)
         at 
org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.java:1122)
         at java.lang.Thread.run(Thread.java:534)
----- Root Cause -----
java.lang.NoClassDefFoundError: org/w3c/dom/svg/SVGDocument
         at java.lang.ClassLoader.defineClass0(Native Method)
         at java.lang.ClassLoader.defineClass(ClassLoader.java:539)
         at 
java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123)
         at 
org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:1631)
         at 
org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:926)
         at 
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1360)
         at 
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1243)
         at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302)
         at 
org.apache.batik.dom.svg.SVGDOMImplementation.createDocument(SVGDOMImplementation.java:174)
         at 
org.apache.cocoon.xml.dom.SVGBuilder.startDocument(SVGBuilder.java:88)
         at 
org.apache.xml.serializer.ToSAXHandler.startDocumentInternal(ToSAXHandler.java:93)
         at 
org.apache.xml.serializer.ToSAXHandler.flushPending(ToSAXHandler.java:278)
         at 
org.apache.xml.serializer.ToXMLSAXHandler.startElement(ToXMLSAXHandler.java:644)
         at 
org.apache.xml.serializer.ToXMLSAXHandler.startElement(ToXMLSAXHandler.java:499)
         at 
org.apache.xalan.transformer.ClonerToResultTree.cloneToResultTree(ClonerToResultTree.java:158)
         at org.apache.xalan.templates.ElemCopy.execute(ElemCopy.java:109)
         at 
org.apache.xalan.templates.ElemApplyTemplates.transformSelectedNodes(ElemApplyTemplates.java:396)
         at 
org.apache.xalan.templates.ElemApplyTemplates.execute(ElemApplyTemplates.java:178)
         at 
org.apache.xalan.transformer.TransformerImpl.executeChildTemplates(TransformerImpl.java:2336)
         at 
org.apache.xalan.transformer.TransformerImpl.applyTemplateToNode(TransformerImpl.java:2202)
         at 
org.apache.xalan.transformer.TransformerImpl.transformNode(TransformerImpl.java:1276)
         at 
org.apache.xalan.transformer.TransformerImpl.run(TransformerImpl.java:3383)
         at 
org.apache.xalan.transformer.TransformerHandlerImpl.endDocument(TransformerHandlerImpl.java:389)
         at 
org.apache.cocoon.xml.AbstractXMLPipe.endDocument(AbstractXMLPipe.java:55)
         at 
org.apache.cocoon.transformation.TraxTransformer.endDocument(TraxTransformer.java:562)
         at 
org.apache.xml.serializer.ToXMLSAXHandler.endDocument(ToXMLSAXHandler.java:180)
         at 
org.apache.xalan.transformer.TransformerImpl.transformNode(TransformerImpl.java:1287)
         at 
org.apache.xalan.transformer.TransformerImpl.run(TransformerImpl.java:3383)
         at 
org.apache.xalan.transformer.TransformerHandlerImpl.endDocument(TransformerHandlerImpl.java:389)
         at 
org.apache.cocoon.xml.AbstractXMLPipe.endDocument(AbstractXMLPipe.java:55)
:



--
Ferdinand Soethe


Re: Forrest 0.7x war throws Execption in Tomcat 4

Posted by Ross Gardler <rg...@apache.org>.
Ross Gardler wrote:
> Ferdinand Soethe wrote:
> 
>> Today we tried to run our community college application
>> (www.bildungsverein.de) in a Tomcat-Server planning to do a load and
>> long term run test.
>>
>> - Using Forrest 0.7x (current patch) we did
>>   forrest war
>> - then placed the application on a Tomcat version 4.0
>>
>> Unfortunately the test was rather short, after accessing just a few 
>> pages the
>> application hung after and exception
>>
>> java.lang.NoClassDefFoundError: org/w3c/dom/svg/SVGDocument
>>
> 
> ...
> 
>> - Any other ideas what we need to do to fix this?
> 
> 
> Tomcat can't find one of the Jars. Looking through the log we see:
> 
> org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1243) 
> 
>       at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302)
>       at
> org.apache.batik.dom.svg.SVGDOMImplementation.createDocument(SVGDOMImplementation.java:174) 
> 
> 
> This implies that the missing class may normally reside in the Batik 
> Jar. A quick check of the contents of that jar confirm this to be the case.
> 
> So this tells us that Tomcat is unable to see the batik.jar for some 
> reason.
> 
> First thing to do is to look to see if that jar is being packaged in the 
> WAR. I did a war of our site-author and, as expected, the jar is present 
> in WEB-INF/lib
> 
> Assuming that it is also present in your war file then I'm afraid this 
> is a local installation problem with respect to Tomcat, not a problem 
> with Forrest.

.... although I did my tests with SVN Head - you should verify them with 
  0.7 version you are using.

Ross

Re: Forrest 0.7x war throws Execption in Tomcat 4

Posted by David Crossley <cr...@apache.org>.
Thorsten Scherler wrote:
> Ferdinand Soethe escribi??:
> > 
> > OK. So how can I now test this war-file with jetty to make sure that
> > it is actually a problem with that Tomcat-Server?
> 
> Such errors in tomcat, especially in old versions often have they root
> problem in "endorsed" libs like xalan and xerces. You can try to copy
> the forrest endorsed lib to the tomcat endorsed lib dir (please google
> for this there should be quite a lot of pages describing how to do it).
> 
> Other reason may the java version on the server.
> 
> I never heard nor know how you can use war with jetty, but to find out I
> reckon a mail to jetty-user would be sufficient. ;-) If you know how,
> just let us know. ;-)

Follow the instructions that come with Jetty, before
asking user questions on their list. I have had previous
versions of Jetty (4.2.x) working fine with a Forrest war.
That is how i did the testing for the 0.7 release. However,
i am having trouble with newer versions of Jetty.

> >  And if so, are
> > there any instructions on how to do this (where to put it, how to run
> > jetty etc.)
> 
> I am afraid not yet here in forrest.

It is not up to Forrest to provide such instructions.

-David

Re: Forrest 0.7x war throws Execption in Tomcat 4

Posted by Thorsten Scherler <th...@apache.org>.
El jue, 19-01-2006 a las 18:31 +0100, Ferdinand Soethe escribió:
> Ross Gardler wrote:
> 
> > First thing to do is to look to see if that jar is being packaged in the
> > WAR. I did a war of our site-author and, as expected, the jar is present
> > in WEB-INF/lib
> 
> I checked that. The jar is present and in the jar I found the class
> bvssp.war\WEB-INF\lib\batik-all-1.5.1.jar\org\apache\batik\dom\svg\SVGDOMImplementation.class
> 

...and this is class does extend org/w3c/dom/svg/SVGDocument?

> > Assuming that it is also present in your war file then I'm afraid this
> > is a local installation problem with respect to Tomcat, not a problem 
> > with Forrest.
> 
> OK. So how can I now test this war-file with jetty to make sure that
> it is actually a problem with that Tomcat-Server?

Such errors in tomcat, especially in old versions often have they root
problem in "endorsed" libs like xalan and xerces. You can try to copy
the forrest endorsed lib to the tomcat endorsed lib dir (please google
for this there should be quite a lot of pages describing how to do it).

Other reason may the java version on the server.

I never heard nor know how you can use war with jetty, but to find out I
reckon a mail to jetty-user would be sufficient. ;-) If you know how,
just let us know. ;-)

>  And if so, are
> there any instructions on how to do this (where to put it, how to run
> jetty etc.)

I am afraid not yet here in forrest.

HTH a wee bit

salu2
-- 
thorsten

"Together we stand, divided we fall!" 
Hey you (Pink Floyd)


Re: Forrest 0.7x war throws Execption in Tomcat 4

Posted by Ferdinand Soethe <fe...@apache.org>.
Ross Gardler wrote:

> First thing to do is to look to see if that jar is being packaged in the
> WAR. I did a war of our site-author and, as expected, the jar is present
> in WEB-INF/lib

I checked that. The jar is present and in the jar I found the class
bvssp.war\WEB-INF\lib\batik-all-1.5.1.jar\org\apache\batik\dom\svg\SVGDOMImplementation.class

> Assuming that it is also present in your war file then I'm afraid this
> is a local installation problem with respect to Tomcat, not a problem 
> with Forrest.

OK. So how can I now test this war-file with jetty to make sure that
it is actually a problem with that Tomcat-Server? And if so, are
there any instructions on how to do this (where to put it, how to run
jetty etc.)

Thanks,
Ferdinand Soethe


Re: Forrest 0.7x war throws Execption in Tomcat 4

Posted by Ross Gardler <rg...@apache.org>.
Ferdinand Soethe wrote:
> Today we tried to run our community college application
> (www.bildungsverein.de) in a Tomcat-Server planning to do a load and
> long term run test.
> 
> - Using Forrest 0.7x (current patch) we did
>   forrest war
> - then placed the application on a Tomcat version 4.0
> 
> Unfortunately the test was rather short, after accessing just a few pages the
> application hung after and exception
> 
> java.lang.NoClassDefFoundError: org/w3c/dom/svg/SVGDocument
> 

...

> - Any other ideas what we need to do to fix this?

Tomcat can't find one of the Jars. Looking through the log we see:

org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1243)
       at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302)
       at
org.apache.batik.dom.svg.SVGDOMImplementation.createDocument(SVGDOMImplementation.java:174)

This implies that the missing class may normally reside in the Batik 
Jar. A quick check of the contents of that jar confirm this to be the case.

So this tells us that Tomcat is unable to see the batik.jar for some reason.

First thing to do is to look to see if that jar is being packaged in the 
WAR. I did a war of our site-author and, as expected, the jar is present 
in WEB-INF/lib

Assuming that it is also present in your war file then I'm afraid this 
is a local installation problem with respect to Tomcat, not a problem 
with Forrest.

Ross


Re: Forrest 0.7x war throws Execption in Tomcat 4

Posted by David Crossley <cr...@apache.org>.
Ferdinand Soethe wrote:
> Today we tried to run our community college application
> (www.bildungsverein.de) in a Tomcat-Server planning to do a load and
> long term run test.
> 
> - Using Forrest 0.7x (current patch) we did
>   forrest war
> - then placed the application on a Tomcat version 4.0
> 
> Unfortunately the test was rather short, after accessing just a few pages the
> application hung after and exception
> 
> java.lang.NoClassDefFoundError: org/w3c/dom/svg/SVGDocument

This comment is a wild guess. The fact that Forrest actually
starts and runs is a good sign. Is it possible that the page
that fails has images being converted? 

Yours sounds like a different error, but just in case:
http://forrest.apache.org/docs/dev/faq.html#headless_operation

-David