You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by delmar watkins <de...@merilus.com> on 2001/06/08 02:16:21 UTC

help with a java error

New to list and totally new to Cocoon and JSPs, etc... please be gentle
:-)  The problem is at the end.  I have read the FAQ, been through the
list archives, and I have of yet to get an answer...  I tried installing
cocoon from the instructions that are installed from untarring the
binaries of cocoon....


OK, I am running a Progeny Linux 2.2.19 kernel,  Sun JDK 1.2.2,
jakarta-tomcat 3.2.2, cocoon 1.8.2 a classpath of:
CLASSHPATH=/home/delmar/code/lib/extras/:.
CLASSPATH=:/usr/local/jakarta-tomcat-3.2.2/lib
that is created in my .bashrc (do I have to set it somehwere else??).

in my /usr/local/jakarta-tomcat-3.2.2/lib directory, I have:
ant.jar      bsf.jar         cocoon.jar  fop_0_15_0.jar  jaxp.jar
sax-bugfix.jar  servlet_2_2.jar       test              w3c.jar
xalan_1_2_D02.jar  xml.jar
ant_1_1.jar  bsfengines.jar  fesi.jar    jasper.jar      parser.jar
servlet.jar     stylebook-1.0-b2.jar  turbine-pool.jar  webserver.jar
xerces_1_2.jar     xt.jar

my cocoon.properties is attached.

on start of jakarta-tomcat, I get the following messages:
# ./startup.sh
Guessing TOMCAT_HOME from tomcat.sh to ./..
Setting TOMCAT_HOME to ./..
Using classpath:
./../lib/ant.jar:./../lib/ant_1_1.jar:./../lib/bsf.jar:./../lib/bsfengines.jar:./../lib/cocoon.jar:./../lib/fesi.jar:./../lib/fop_0_15_0.jar:./../lib/jasper.jar:./../lib/jaxp.jar:./../lib/parser.jar:./../lib/sax-bugfix.jar:./../lib/servlet.jar:./../lib/servlet_2_2.jar:./../lib/stylebook-1.0-b2.jar:./../lib/test:./../lib/turbine-pool.jar:./../lib/w3c.jar:./../lib/webserver.jar:./../lib/xalan_1_2_D02.jar:./../lib/xerces_1_2.jar:./../lib/xml.jar:./../lib/xt.jar:/usr/local/jdk1.2.2/bin/../lib/tools.jar::/usr/local/jakarta-tomcat-3.2.2/lib

# 2001-06-07 05:11:43 - ContextManager: Adding context Ctx( /examples )
2001-06-07 05:11:43 - ContextManager: Adding context Ctx( /cocoon )
Starting tomcat. Check logs/tomcat.log for error messages
2001-06-07 05:11:43 - ContextManager: Adding context Ctx( /admin )
2001-06-07 05:11:43 - ContextManager: Adding context Ctx(  )
2001-06-07 05:11:43 - ContextManager: Adding context Ctx( /test )
2001-06-07 05:11:45 - PoolTcpConnector: Starting HttpConnectionHandler
on 8080
2001-06-07 05:11:45 - PoolTcpConnector: Starting Ajp12ConnectionHandler
on 8007

I get the following message when I try to view a page on
http://localhost:8080/cocoon/samples/index.xml

---------------------------------------
                                       Publishing Engine could not be
initialized.

     java.lang.RuntimeException: Exception when creating "
org.apache.cocoon.processor.xsp.XSPProcessor" :
     java.lang.NoSuchMethodError: See
http://xml.apache.org/cocoon/faqs.html#faq-normalize
             at
org.apache.cocoon.framework.Manager.create(Manager.java:124)
             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.tomcat.core.ServletWrapper.doInit(ServletWrapper.java:317)
             at org.apache.tomcat.core.Handler.init(Handler.java:215)
             at
org.apache.tomcat.core.ServletWrapper.init(ServletWrapper.java:296)
             at org.apache.tomcat.core.Handler.service(Handler.java:254)

             at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
             at
org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:797)

             at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
             at
org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectionHandler.java:213)

             at
org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)

             at
org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501)

             at java.lang.Thread.run(Thread.java:479)
-----------------------------------------


What do I need to do to get it running?  I can broswe thorugh the
directory structure, but as soon as I try to get to something dynamic
that touches cocoon, it dies with the error above.

Re: help with a java error

Posted by declan kelly <de...@yahoo.com>.
Hi,

Are you sure you read the faq?

You need to rename xml.jar & parser.jar to something
that will ensure they come at the end of the classpath
or get rid of them.
 It's all explained in the part of the faq that the
error tells you to look at.

--- delmar watkins <de...@merilus.com> wrote:
> New to list and totally new to Cocoon and JSPs,
> etc... please be gentle
> :-)  The problem is at the end.  I have read the
> FAQ, been through the
> list archives, and I have of yet to get an answer...
>  I tried installing
> cocoon from the instructions that are installed from
> untarring the
> binaries of cocoon....
> 
> 
> OK, I am running a Progeny Linux 2.2.19 kernel,  Sun
> JDK 1.2.2,
> jakarta-tomcat 3.2.2, cocoon 1.8.2 a classpath of:
> CLASSHPATH=/home/delmar/code/lib/extras/:.
> CLASSPATH=:/usr/local/jakarta-tomcat-3.2.2/lib
> that is created in my .bashrc (do I have to set it
> somehwere else??).
> 
> in my /usr/local/jakarta-tomcat-3.2.2/lib directory,
> I have:
> ant.jar      bsf.jar         cocoon.jar 
> fop_0_15_0.jar  jaxp.jar
> sax-bugfix.jar  servlet_2_2.jar       test          
>    w3c.jar
> xalan_1_2_D02.jar  xml.jar
> ant_1_1.jar  bsfengines.jar  fesi.jar    jasper.jar 
>     parser.jar
> servlet.jar     stylebook-1.0-b2.jar 
> turbine-pool.jar  webserver.jar
> xerces_1_2.jar     xt.jar
> 
> my cocoon.properties is attached.
> 
> on start of jakarta-tomcat, I get the following
> messages:
> # ./startup.sh
> Guessing TOMCAT_HOME from tomcat.sh to ./..
> Setting TOMCAT_HOME to ./..
> Using classpath:
>
./../lib/ant.jar:./../lib/ant_1_1.jar:./../lib/bsf.jar:./../lib/bsfengines.jar:./../lib/cocoon.jar:./../lib/fesi.jar:./../lib/fop_0_15_0.jar:./../lib/jasper.jar:./../lib/jaxp.jar:./../lib/parser.jar:./../lib/sax-bugfix.jar:./../lib/servlet.jar:./../lib/servlet_2_2.jar:./../lib/stylebook-1.0-b2.jar:./../lib/test:./../lib/turbine-pool.jar:./../lib/w3c.jar:./../lib/webserver.jar:./../lib/xalan_1_2_D02.jar:./../lib/xerces_1_2.jar:./../lib/xml.jar:./../lib/xt.jar:/usr/local/jdk1.2.2/bin/../lib/tools.jar::/usr/local/jakarta-tomcat-3.2.2/lib
> 
> # 2001-06-07 05:11:43 - ContextManager: Adding
> context Ctx( /examples )
> 2001-06-07 05:11:43 - ContextManager: Adding context
> Ctx( /cocoon )
> Starting tomcat. Check logs/tomcat.log for error
> messages
> 2001-06-07 05:11:43 - ContextManager: Adding context
> Ctx( /admin )
> 2001-06-07 05:11:43 - ContextManager: Adding context
> Ctx(  )
> 2001-06-07 05:11:43 - ContextManager: Adding context
> Ctx( /test )
> 2001-06-07 05:11:45 - PoolTcpConnector: Starting
> HttpConnectionHandler
> on 8080
> 2001-06-07 05:11:45 - PoolTcpConnector: Starting
> Ajp12ConnectionHandler
> on 8007
> 
> I get the following message when I try to view a
> page on
> http://localhost:8080/cocoon/samples/index.xml
> 
> ---------------------------------------
>                                        Publishing
> Engine could not be
> initialized.
> 
>      java.lang.RuntimeException: Exception when
> creating "
> org.apache.cocoon.processor.xsp.XSPProcessor" :
>      java.lang.NoSuchMethodError: See
> http://xml.apache.org/cocoon/faqs.html#faq-normalize
>              at
>
org.apache.cocoon.framework.Manager.create(Manager.java:124)
>              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.tomcat.core.ServletWrapper.doInit(ServletWrapper.java:317)
>              at
>
org.apache.tomcat.core.Handler.init(Handler.java:215)
>              at
>
org.apache.tomcat.core.ServletWrapper.init(ServletWrapper.java:296)
>              at
>
org.apache.tomcat.core.Handler.service(Handler.java:254)
> 
>              at
>
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
>              at
>
org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:797)
> 
>              at
>
org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
>              at
>
org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectionHandler.java:213)
> 
>              at
>
org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)
> 
>              at
>
org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501)
> 
>              at
> java.lang.Thread.run(Thread.java:479)
> -----------------------------------------
> 
> 
> What do I need to do to get it running?  I can
> broswe thorugh the
> directory structure, but as soon as I try to get to
> something dynamic
> that touches cocoon, it dies with the error above.
> >
##############################################################################
> #                          Cocoon Configuration file
>                         #
>
##############################################################################
> 
>
##################################################################################
> # IMPORTANT - YOU MUST RESTART YOUR SERVLET ENGINE
> WHENEVER YOU CHANGE THIS FILE #
> #                                                   
>                             #
> #  This is a limitation which is fixed in Cocoon 2. 
>                             #
>
##################################################################################
> 
> 
> ##########################################
> # Global Configurations                  #
> ##########################################
> 
> # Indicates whether or not Cocoon should be visible
> if
> # the requested URI equals the specified one.
> selfservlet.enabled = true
> selfservlet.uri = /Cocoon.xml
> 
> # Indicates whether or not Cocoon should handle
> errors internally
> # and format the error and the exception stack trace
> to the client
> # or return the HTTP error code to the web server
> and let it handle it.
> handle.errors.internally = true
> 
> # Indicates the log severity level
> #log.level = emergency
> #log.level = critical
> log.level = error
> #log.level = warning
> #log.level = info
> #log.level = debug
> 
> 
> 
> ##########################################
> # XML Parsers                            #
> ##########################################
> 
> # Apache Xerces 1.0.1+ (http://xml.apache.com/)
> parser = org.apache.cocoon.parser.XercesParser
> 
> # SUN ProjectX TR2 (http://java.sun.com/xml/)
> #parser = org.apache.cocoon.parser.SunXMLParser
> 
> # Indicate whether the XML file should be validated
> or not
> # this is turned off by default for faster
> operation.
> parser.validate = false
> 
> 
> ##########################################
> # XSLT Transformers                      #
> ##########################################
> 
> # Apache Xalan (http://xml.apache.org/)
> transformer =
> org.apache.cocoon.transformer.XalanTransformer
> 
> # James Clark's XT (http://www.jclark.com/)
> #transformer =
> org.apache.cocoon.transformer.XTTransformer
> 
> 
> 
> ##########################################
> # XML Producers                          #
> ##########################################
> 
> # For example, if you want to produce your XML
> template reading it from
> # the file system, using your producer, you should
> request the URI:
> #  
> http://your.site.com/your_XML_file.xml?producer=file
> 
> # This is the request parameter used to identify the
> producer in the request:
> # (default value is "producer")
> producer.parameter = producer
> 
> # The syntax for this is
> #   producer.type.xxx = full.class.name
> # where "xxx" is the producer indentier used in the
> request
> producer.type.file =
> org.apache.cocoon.producer.ProducerFromFile
> 
> # This is used in the example files
> producer.type.dummy =
> org.apache.cocoon.example.DummyProducer
> 
> # When producer indication is present in the request
> # this configuration allows to map those requests to
> a particular
> # producer indicated here with its type.
> # NOTE: this type must present in the above map.
> producer.default = file
> 
> 
> 
> 
> 
> ##########################################
> # XML Processors                         #
> ##########################################
> 
> # These are used when the <?cocoon-process
> type="xxx"?> PI is present.
> # If no PI of that type is present, no processing is
> performed.
> # The syntax for this is
> #   processor.type.xxx = full.class.name
> 
> # XSL Transformations (XSLT)
> processor.type.xslt =
> org.apache.cocoon.processor.xslt.XSLTProcessor
> 
> # SQL Processor
> processor.type.sql =
> org.apache.cocoon.processor.sql.SQLProcessor
> 
> # LDAP Processor
> # NOTE: you need to have the SUN JDNI API (jndi.jar)
> in your classpath
> # in order for this processor to work. Check the FAQ
> for more information.
> #processor.type.ldap =
> org.apache.cocoon.processor.ldap.LdapProcessor
> 
> # XInclude Processor
> processor.type.xinclude =
>
org.apache.cocoon.processor.xinclude.XIncludeProcessor
> 
> # Link Encoding Processor which encodes all links
> using response.encodeUrl()
> processor.type.linkencode =
> org.apache.cocoon.processor.LinkEncodingProcessor
> 
> ##########################################
> # XSP Processor                          #
> ##########################################
> 
> # eXtensible Server Pages Processor (XSP)
> processor.type.xsp =
> org.apache.cocoon.processor.xsp.XSPProcessor
> 
> # supported languages
> processor.xsp.languages = java
> 
> # Default encoding to be used for code generation
> and compilation
> # If omitted, the platform's default encoding will
> be used
> # This encoding should also be used in:
> #   - The XSP document <?xml?> declaration
> #   - The "encoding" configuration property of the
> formatter to be used
> # Example: Russian uses "Cp1251"
> # processor.xsp.encoding = Cp1251
> 
> # support for the java language
> processor.xsp.java.processor =
>
org.apache.cocoon.processor.xsp.language.java.XSPJavaProcessor
> processor.xsp.java.processor.compiler =
>
org.apache.cocoon.processor.xsp.language.java.SunJavaCompiler
> 
> # NOTE: If you enable the Jikes compiler, you must
> put rt.jar (for JDK >1.1) or classes.zip (for JDK
> 1.1)
> # on your CLASSPATH
> #processor.xsp.java.processor.compiler =
>
org.apache.cocoon.processor.xsp.language.java.JikesJavaCompiler
> processor.xsp.java.logicsheet = xsp-java.xsl
> processor.xsp.java.preprocessor =
>
org.apache.cocoon.processor.xsp.language.java.XSPJavaPreprocessor
> 
> 
> # sets the repository where the compiled pages are
> stored.
> # NOTE: make sure the directory is readable. This
> directory is usually
> # relative to the web server's or to the servlet
> engine's. In case you're not
> # sure, use an absolute location.
> # WARNING: since this repository may contain
> information you want to remain
> # secret, we highly suggest that you protect the
> repository from untrusted
> # access, even read-only. Only Cocoon and the system
> administrators should
> # have access here.
> 
=== message truncated ===

> ATTACHMENT part 2 application/x-pkcs7-signature
name=smime.p7s



__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail - only $35 
a year!  http://personal.mail.yahoo.com/

---------------------------------------------------------------------
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: help with a java error

Posted by fo...@neonics.com.

Remove parser.jar and jaxp.jar from the tomcat lib dir,
and rename the xalan-x.jar/xerces-x.jar to 1xalan-x.jar/1xerces-x.jar.
Then restart tomcat.

On Thu, 7 Jun 2001, delmar watkins wrote:

> New to list and totally new to Cocoon and JSPs, etc... please be gentle
> :-)  The problem is at the end.  I have read the FAQ, been through the
> list archives, and I have of yet to get an answer...  I tried installing
> cocoon from the instructions that are installed from untarring the
> binaries of cocoon....
> 
> 
> OK, I am running a Progeny Linux 2.2.19 kernel,  Sun JDK 1.2.2,
> jakarta-tomcat 3.2.2, cocoon 1.8.2 a classpath of:
> CLASSHPATH=/home/delmar/code/lib/extras/:.
> CLASSPATH=:/usr/local/jakarta-tomcat-3.2.2/lib
> that is created in my .bashrc (do I have to set it somehwere else??).
> 
> in my /usr/local/jakarta-tomcat-3.2.2/lib directory, I have:
> ant.jar      bsf.jar         cocoon.jar  fop_0_15_0.jar  jaxp.jar
> sax-bugfix.jar  servlet_2_2.jar       test              w3c.jar
> xalan_1_2_D02.jar  xml.jar
> ant_1_1.jar  bsfengines.jar  fesi.jar    jasper.jar      parser.jar
> servlet.jar     stylebook-1.0-b2.jar  turbine-pool.jar  webserver.jar
> xerces_1_2.jar     xt.jar
> 
> my cocoon.properties is attached.
> 
> on start of jakarta-tomcat, I get the following messages:
> # ./startup.sh
> Guessing TOMCAT_HOME from tomcat.sh to ./..
> Setting TOMCAT_HOME to ./..
> Using classpath:
> ./../lib/ant.jar:./../lib/ant_1_1.jar:./../lib/bsf.jar:./../lib/bsfengines.jar:./../lib/cocoon.jar:./../lib/fesi.jar:./../lib/fop_0_15_0.jar:./../lib/jasper.jar:./../lib/jaxp.jar:./../lib/parser.jar:./../lib/sax-bugfix.jar:./../lib/servlet.jar:./../lib/servlet_2_2.jar:./../lib/stylebook-1.0-b2.jar:./../lib/test:./../lib/turbine-pool.jar:./../lib/w3c.jar:./../lib/webserver.jar:./../lib/xalan_1_2_D02.jar:./../lib/xerces_1_2.jar:./../lib/xml.jar:./../lib/xt.jar:/usr/local/jdk1.2.2/bin/../lib/tools.jar::/usr/local/jakarta-tomcat-3.2.2/lib
> 
> # 2001-06-07 05:11:43 - ContextManager: Adding context Ctx( /examples )
> 2001-06-07 05:11:43 - ContextManager: Adding context Ctx( /cocoon )
> Starting tomcat. Check logs/tomcat.log for error messages
> 2001-06-07 05:11:43 - ContextManager: Adding context Ctx( /admin )
> 2001-06-07 05:11:43 - ContextManager: Adding context Ctx(  )
> 2001-06-07 05:11:43 - ContextManager: Adding context Ctx( /test )
> 2001-06-07 05:11:45 - PoolTcpConnector: Starting HttpConnectionHandler
> on 8080
> 2001-06-07 05:11:45 - PoolTcpConnector: Starting Ajp12ConnectionHandler
> on 8007
> 
> I get the following message when I try to view a page on
> http://localhost:8080/cocoon/samples/index.xml
> 
> ---------------------------------------
>                                        Publishing Engine could not be
> initialized.
> 
>      java.lang.RuntimeException: Exception when creating "
> org.apache.cocoon.processor.xsp.XSPProcessor" :
>      java.lang.NoSuchMethodError: See
> http://xml.apache.org/cocoon/faqs.html#faq-normalize
>              at
> org.apache.cocoon.framework.Manager.create(Manager.java:124)
>              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.tomcat.core.ServletWrapper.doInit(ServletWrapper.java:317)
>              at org.apache.tomcat.core.Handler.init(Handler.java:215)
>              at
> org.apache.tomcat.core.ServletWrapper.init(ServletWrapper.java:296)
>              at org.apache.tomcat.core.Handler.service(Handler.java:254)
> 
>              at
> org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
>              at
> org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:797)
> 
>              at
> org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
>              at
> org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectionHandler.java:213)
> 
>              at
> org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)
> 
>              at
> org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501)
> 
>              at java.lang.Thread.run(Thread.java:479)
> -----------------------------------------
> 
> 
> What do I need to do to get it running?  I can broswe thorugh the
> directory structure, but as soon as I try to get to something dynamic
> that touches cocoon, it dies with the error above.
> 


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