You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Erik Tennant <li...@webpd.com> on 2001/03/21 04:14:33 UTC

Cocoon and Tomcat 4.0

I am installing Cocoon 1.8.2 on Linux (Redhat 7.0) with Tomcat 4.0b1 and 
jdk1.3.

First I want to say thanks to the Cocoon team for creating such thorough 
installation instructions.. It was extremely helpful (the last time I 
installed Cocoon was about a year and a half ago, and I remember struggling 
a lot more with it..).

But.. I am having two problems..

1) When I put the w3c.jar in the {$TOMCAT_HOME}/lib directory, I get the 
following error when I start (or try to stop) Tomcat:
Exception in thread "main" java.lang.IllegalArgumentException: 
addRepositoryInternal: java.lang.NullPointerException
         at 
org.apache.catalina.loader.StandardClassLoader.addRepositoryInternal(StandardClassLoader.java:1073)
         at 
org.apache.catalina.loader.StandardClassLoader.<init>(StandardClassLoader.java:166)
         at 
org.apache.catalina.startup.Bootstrap.createSharedLoader(Bootstrap.java:324)
         at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:122)

2) If I remove w3c.jar from the lib directory, Tomcat will start.. but then 
when I try to access the sample Cocoon files, I get the following message:

java.lang.RuntimeException: Error loading logicsheet at 
resource://org/apache/cocoon/processor/xsp/library/java/util.xsl due to 
java.lang.Exception: Resource not found or retrieving error.
	at org.apache.cocoon.processor.xsp.XSPProcessor.init(XSPProcessor.java:302)
	at org.apache.cocoon.framework.Manager.create(Manager.java:109)
	at org.apache.cocoon.framework.Router.init(Router.java:80)
	at org.apache.cocoon.framework.Manager.create(Manager.java:109)
	at org.apache.cocoon.Engine.<init>(Engine.java:179)
	at org.apache.cocoon.Engine.getInstance(Engine.java:232)
	at org.apache.cocoon.Cocoon.init(Cocoon.java:157)
	at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:755)
	at org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:544)
	at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:227)
	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:977)
	at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:196)
	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:977)
	at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2041)
	at 
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:161)
	at org.apache.catalina.valves.ValveBase.invokeNext(ValveBase.java:242)
	at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:414)
	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:975)
	at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:159)
	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:977)
	at 
org.apache.catalina.connector.http.HttpProcessor.process(HttpProcessor.java:818)
	at 
org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.java:897)
	at java.lang.Thread.run(Thread.java:484)

Although cocoon.jar is in the TOMCAT/lib directory, and it does in fact 
contain the resource util.xsl.  I saw a previous post in the archives 
suggesting to set the jar files in the system classpath, which I tried, but 
to no avail.

I have tried reordering any xml related jar files in my lib directory (by 
renaming them), and even removing some, but I was never able to get either 
error to go away.. Does anyone have any other ideas?  Am I missing 
something really obvious? Should I go back to Tomcat 3.2? Here are all the 
files in my lib directory:
cocoon.jar   fop_0_15_0.jar  jaxp.jar           tools.jar 
xalan_1_2_D02.jar
crimson.jar  jasper.jar      namingfactory.jar  turbine-pool.jar 
xerces_1_2.jar

Also, on a side note, the installation instructions indicate to add the 
following to the server.xml file:
<Context path="/cocoon" docBase="webapps/cocoon" debug="0" 
reloadable="true" > </Context>

I found that to get Tomcat 4.0 running, I in fact had to add the following 
line instead:
<Context path="/cocoon" docBase="cocoon" debug="0" reloadable="true" > 
</Context> (leaving out webapps/).. It might be useful to others to add 
that note to the installation page on the web site.

Thanks,

Erik


---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <co...@xml.apache.org>
For additional commands, e-mail: <co...@xml.apache.org>


RE: Cocoon and Tomcat 4.0

Posted by Jon Brisbin <br...@ipa.net>.
I also got this same message when trying to install cocoon with the
jboss/jetty or jboss/tomcat packages...this issue must be the same one in
tomcat 4 because of the container/webapp visible classpaths...

c2 works fine under jboss/jetty running in the same vm, but i couldn't ever
get c1.8.2 working on it...always got the following error...

jb

blah> [snip]
blah> > 2) If I remove w3c.jar from the lib directory, Tomcat will
blah> start.. but then
blah> > when I try to access the sample Cocoon files, I get the
blah> following message:
blah> >
blah> > java.lang.RuntimeException: Error loading logicsheet at
blah> >
blah> resource://org/apache/cocoon/processor/xsp/library/java/util.x
blah> sl due to
blah> > java.lang.Exception: Resource not found or retrieving error.
blah> > 	at
blah> org.apache.cocoon.processor.xsp.XSPProcessor.init(XSPProcessor
blah> .java:302)
blah> > 	at
blah> org.apache.cocoon.framework.Manager.create(Manager.java:109)
blah> > 	at org.apache.cocoon.framework.Router.init(Router.java:80)
blah> > 	at
blah> org.apache.cocoon.framework.Manager.create(Manager.java:109)
blah> > 	at org.apache.cocoon.Engine.<init>(Engine.java:179)
blah> > 	at org.apache.cocoon.Engine.getInstance(Engine.java:232)
blah> > 	at org.apache.cocoon.Cocoon.init(Cocoon.java:157)
blah> >
blah> > Although cocoon.jar is in the TOMCAT/lib directory, and it
blah> does in fact
blah> > contain the resource util.xsl.  I saw a previous post in
blah> the archives
blah> > suggesting to set the jar files in the system classpath,
blah> which I tried, but
blah> > to no avail.
blah>
blah> The fact that the exception includes org.apache.cocoon
blah> entries suggests that
blah> the jar is being found.
blah>
blah> Btw, are you using the official 1.8.2 distribution, or did
blah> you build a jar from
blah> CVS? At one stage, building from CVS would get you a jar with
blah> no .xsl files.
blah>
blah>
blah> --Jeff
blah>
blah> > I have tried reordering any xml related jar files in my lib
blah> directory (by
blah> > renaming them), and even removing some, but I was never
blah> able to get either
blah> > error to go away.. Does anyone have any other ideas?  Am I missing
blah> > something really obvious? Should I go back to Tomcat 3.2?
blah> Here are all the
blah> > files in my lib directory:
blah> > cocoon.jar   fop_0_15_0.jar  jaxp.jar           tools.jar
blah> > xalan_1_2_D02.jar
blah> > crimson.jar  jasper.jar      namingfactory.jar  turbine-pool.jar
blah> > xerces_1_2.jar
blah> >
blah> > Also, on a side note, the installation instructions
blah> indicate to add the
blah> > following to the server.xml file:
blah> > <Context path="/cocoon" docBase="webapps/cocoon" debug="0"
blah> > reloadable="true" > </Context>
blah> >
blah> > I found that to get Tomcat 4.0 running, I in fact had to
blah> add the following
blah> > line instead:
blah> > <Context path="/cocoon" docBase="cocoon" debug="0"
blah> reloadable="true" >
blah> > </Context> (leaving out webapps/).. It might be useful to
blah> others to add
blah> > that note to the installation page on the web site.
blah> >
blah> > Thanks,
blah> >
blah> > Erik
blah> >
blah> >
blah> >
blah> ---------------------------------------------------------------------
blah> > Please check that your question has not already been answered in the
blah> > FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>
blah> >
blah> > To unsubscribe, e-mail: <co...@xml.apache.org>
blah> > For additional commands, e-mail: <co...@xml.apache.org>
blah>
blah> ---------------------------------------------------------------------
blah> Please check that your question has not already been answered in the
blah> FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>
blah>
blah> To unsubscribe, e-mail: <co...@xml.apache.org>
blah> For additional commands, e-mail: <co...@xml.apache.org>
blah>


---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <co...@xml.apache.org>
For additional commands, e-mail: <co...@xml.apache.org>


Re: Cocoon and Tomcat 4.0

Posted by Jeff Turner <je...@socialchange.net.au>.
Hi Erik,

FYI, there's a second beta of Tomcat 4.0 coming out this thursday night (22/3).

On Tue, Mar 20, 2001 at 09:14:33PM -0600, Erik Tennant wrote:
> I am installing Cocoon 1.8.2 on Linux (Redhat 7.0) with Tomcat 4.0b1 and 
> jdk1.3.
> 
> First I want to say thanks to the Cocoon team for creating such thorough 
> installation instructions.. It was extremely helpful (the last time I 
> installed Cocoon was about a year and a half ago, and I remember struggling 
> a lot more with it..).
>
> But.. I am having two problems..
> 
> 1) When I put the w3c.jar in the {$TOMCAT_HOME}/lib directory, I get the 
> following error when I start (or try to stop) Tomcat:

Are you *sure* that's still where jars are meant to go? Tomcat4.0 and 3.3 make
the distinction between container-visible jars and webapp-visible jars.

[snip] 
> 2) If I remove w3c.jar from the lib directory, Tomcat will start.. but then 
> when I try to access the sample Cocoon files, I get the following message:
> 
> java.lang.RuntimeException: Error loading logicsheet at 
> resource://org/apache/cocoon/processor/xsp/library/java/util.xsl due to 
> java.lang.Exception: Resource not found or retrieving error.
> 	at org.apache.cocoon.processor.xsp.XSPProcessor.init(XSPProcessor.java:302)
> 	at org.apache.cocoon.framework.Manager.create(Manager.java:109)
> 	at org.apache.cocoon.framework.Router.init(Router.java:80)
> 	at org.apache.cocoon.framework.Manager.create(Manager.java:109)
> 	at org.apache.cocoon.Engine.<init>(Engine.java:179)
> 	at org.apache.cocoon.Engine.getInstance(Engine.java:232)
> 	at org.apache.cocoon.Cocoon.init(Cocoon.java:157)
> 
> Although cocoon.jar is in the TOMCAT/lib directory, and it does in fact 
> contain the resource util.xsl.  I saw a previous post in the archives 
> suggesting to set the jar files in the system classpath, which I tried, but 
> to no avail.

The fact that the exception includes org.apache.cocoon entries suggests that
the jar is being found.

Btw, are you using the official 1.8.2 distribution, or did you build a jar from
CVS? At one stage, building from CVS would get you a jar with no .xsl files.


--Jeff

> I have tried reordering any xml related jar files in my lib directory (by 
> renaming them), and even removing some, but I was never able to get either 
> error to go away.. Does anyone have any other ideas?  Am I missing 
> something really obvious? Should I go back to Tomcat 3.2? Here are all the 
> files in my lib directory:
> cocoon.jar   fop_0_15_0.jar  jaxp.jar           tools.jar 
> xalan_1_2_D02.jar
> crimson.jar  jasper.jar      namingfactory.jar  turbine-pool.jar 
> xerces_1_2.jar
> 
> Also, on a side note, the installation instructions indicate to add the 
> following to the server.xml file:
> <Context path="/cocoon" docBase="webapps/cocoon" debug="0" 
> reloadable="true" > </Context>
> 
> I found that to get Tomcat 4.0 running, I in fact had to add the following 
> line instead:
> <Context path="/cocoon" docBase="cocoon" debug="0" reloadable="true" > 
> </Context> (leaving out webapps/).. It might be useful to others to add 
> that note to the installation page on the web site.
> 
> Thanks,
> 
> Erik
> 
> 
> ---------------------------------------------------------------------
> Please check that your question has not already been answered in the
> FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>
> 
> To unsubscribe, e-mail: <co...@xml.apache.org>
> For additional commands, e-mail: <co...@xml.apache.org>

---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <co...@xml.apache.org>
For additional commands, e-mail: <co...@xml.apache.org>