You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Lauren Commons <lh...@yahoo.com> on 2002/08/10 15:21:41 UTC

"...Parser does not implement XML Reader"

First of all, I know this question has been covered,
but none of the list archives are available, so I'll
ask again...
I am running RH7.(2 I think?), JDK1.4, Tomcat
4.0.3-LE-jdk14.
I had previously installed (unsuccesfully) cocoon
2.0.2.  I had had the standard problems people have
with the jdk14 installation (mismatched parser
versions, etc.).  I never did get that working...
I just downloaded and installed the binary
cocoon-2.0.3 for jdk1.4.  First of all, I assume that
the install html pages are obsolete since they
indicate that no inaries exist for jdk1.4.  So I
referred to the INSTALL doc in the distribution tar.gz
file, which suggests removing jaxp and parser jars
from tomcat/lib and puting xerces in there (renamed
parser.jar) (and I've removed the work directory...).
When I restart Tomcat and browse /cocoon/ I get the
dreaded classcast exception "SAX 2... Parser does not
implement XML Reader".

Any suggestions?

tia

=====
-------------------------
Mr Lauren Commons
DISCLAIMER: The opinions expressed 
ARE in fact those of my employer.

__________________________________________________
Do You Yahoo!?
HotJobs - Search Thousands of New Jobs
http://www.hotjobs.com

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

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


Can't build 2.0.2, Can build 2.0.3

Posted by Jesse Reynolds <mail.va.com.au>.
Hi folx

Does anyone know about these two build errors? 2.0.3 builds without a 
hitch, but 2.0.2 gives these two errors.

/usr/install/cocoon-2.0.2/build/cocoon/src/org/apache/cocoon/components/source/URLSource.java:232: 
Method setInstanceFollowRedirects(boolean) not found in class 
java.net.HttpURLConnection.
 
((HttpURLConnection)connection).setInstanceFollowRedirects(false);
 
^
/usr/install/cocoon-2.0.2/build/cocoon/src/org/apache/cocoon/components/store/FilesystemStore.java:377: 
Exception java.lang.Exception must be caught, or it must be declared 
in the throws clause of this method.
         return java.net.URLDecoder.decode( filename );
                                          ^

the entire build output is below.

Environment is FreeBSD 4.1.1-RELEASE, Linux (Blackdown) JDK 1.2.2,

Thankyou

Jesse


.........................................................................


bash-2.04# ./build.sh

Apache Cocoon Build System
--------------------------
Buildfile: build.xml

init:
--------------------------------------------------------------
             Apache Cocoon 2.0.2 [1999-2002]
--------------------------------------------------------------
Building with Ant version 1.4.1 compiled on October 11 2001
using build file /usr/install/cocoon-2.0.2/build.xml
--------------------------------------------------------------
Created dir: /usr/install/cocoon-2.0.2/tools/anttasks
Compiling 5 source files to /usr/install/cocoon-2.0.2/tools/anttasks

op-warning:
**********************************************
*
*  Classes of the optional package JFOR are not
*  available. Apache Cocoon builds without them.
*
*  JFOR is required for the fo2rtf serializer.
*
*  Recovery:
*  Get the JFOR package from http://www.jfor.org/ and place the jar 
in the lib/optional dir
*
***********************************************

op-warning:
**********************************************
*
*  Classes of the optional package PHP are not
*  available. Apache Cocoon builds without them.
*
*  PHP is required for the php generator.
*
*  Recovery:
*  Get the PHP servlet (phpsrvlt.jar) from http://www.php.net/ and 
place the jar in the lib/optional dir
*
***********************************************

op-warning:
**********************************************
*
*  Classes of the optional package JNDI are not
*  available. Apache Cocoon builds without them.
*
*  JNDI is required for the ldap generator and the parentcm generator.
*
*  Recovery:
*  Get the jndi.jar from Sun and place the jar in the lib/optional dir
*
***********************************************

prepare:
Created dir: /usr/install/cocoon-2.0.2/build/cocoon

generate-java-code:
Transforming into 
/usr/install/cocoon-2.0.2/build/cocoon/src/org/apache/cocoon/components/browser
Transforming into 
/usr/install/cocoon-2.0.2/build/cocoon/src/org/apache/cocoon/components/browser
Loading stylesheet 
/usr/install/cocoon-2.0.2/src/java/org/apache/cocoon/components/browser/BrowserImpl.xsl

prepare-src-main:
Created dir: /usr/install/cocoon-2.0.2/build/cocoon/classes
Copying 657 files to /usr/install/cocoon-2.0.2/build/cocoon/src
Copied 2 empty directories to /usr/install/cocoon-2.0.2/build/cocoon/src
Created dir: /usr/install/cocoon-2.0.2/build/cocoon/scratchpad/src
Created dir: /usr/install/cocoon-2.0.2/build/cocoon/scratchpad/classes
Copying 141 files to /usr/install/cocoon-2.0.2/build/cocoon/scratchpad/src

compile:
Copying 28 files to /usr/install/cocoon-2.0.2/build/cocoon/classes
Compiling with Java 1.2, debug on, optimize off, deprecation off
Compiling 602 source files to /usr/install/cocoon-2.0.2/build/cocoon/classes
/usr/install/cocoon-2.0.2/build/cocoon/src/org/apache/cocoon/components/source/URLSource.java:232: 
Method setInstanceFollowRedirects(boolean) not found in class 
java.net.HttpURLConnection.
 
((HttpURLConnection)connection).setInstanceFollowRedirects(false);
 
^
/usr/install/cocoon-2.0.2/build/cocoon/src/org/apache/cocoon/components/store/FilesystemStore.java:377: 
Exception java.lang.Exception must be caught, or it must be declared 
in the throws clause of this method.
         return java.net.URLDecoder.decode( filename );
                                          ^
2 errors

BUILD FAILED

/usr/install/cocoon-2.0.2/build.xml:912: Compile failed, messages 
should have been provided.

Total time: 4 minutes 28 seconds
-- 
       Jesse Reynolds - Virtual Artists Pty Ltd - http://www.va.com.au

     Email: jesse (at) va.com.au            > Website Development
     Phone: +61 (0)8 8223 2288              > Web & Email Hosting
       Web: http://jesse.va.com.au          > Streaming Media Hosting
                                            > Telehousing / Colocation

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

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


RE: "...Parser does not implement XML Reader"

Posted by Vadim Gritsenko <va...@verizon.net>.
> From: Lauren Commons [mailto:lhcommons@yahoo.com]
> 
> First of all, I know this question has been covered,
> but none of the list archives are available, so I'll
> ask again...
> I am running RH7.(2 I think?), JDK1.4, Tomcat
> 4.0.3-LE-jdk14.
> I had previously installed (unsuccesfully) cocoon
> 2.0.2.  I had had the standard problems people have
> with the jdk14 installation (mismatched parser
> versions, etc.).  I never did get that working...
> I just downloaded and installed the binary
> cocoon-2.0.3 for jdk1.4.  First of all, I assume that
> the install html pages are obsolete since they
> indicate that no inaries exist for jdk1.4.  So I
> referred to the INSTALL doc in the distribution tar.gz
> file, which suggests removing jaxp and parser jars
> from tomcat/lib and puting xerces in there (renamed
> parser.jar) (and I've removed the work directory...).
> When I restart Tomcat and browse /cocoon/ I get the
> dreaded classcast exception "SAX 2... Parser does not
> implement XML Reader".

Classloading issue.


> Any suggestions?

The easiest way to do this cleanly and with less amount of hassle is to
upgrade to Tomcat 4.0.4, in your case it is LE.

If you don't want to go this route, combine all advices regarding JDK1.4
+ Parsers and Tomcat 4.0.3 + Cocoon, it won't be easy but it is possible
to make this work. Don't remember details though - I'm happy with 4.0.4

Vadim



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

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