You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by Andrew Milkowski <am...@unicast.com> on 2002/08/08 16:46:52 UTC

Tomcat 3.2 run as NT service with xml parser other than its default (parser.jar)

receiving following exception while running Tomcat as NT service

javax.xml.parsers.FactoryConfigurationError:
com.sun.xml.parser.SAXParserFactoryImpl
	at javax.xml.parsers.SAXParserFactory.newInstance(SAXParserFactory.java:84)
	at org.apache.tomcat.util.xml.XmlMapper.readXml(XmlMapper.java:210)
	at org.apache.tomcat.startup.Tomcat.execute(Tomcat.java:187)
	at org.apache.tomcat.startup.Tomcat.main(Tomcat.java:235)
Exception in thread "main"

following wrapper.properties classpath values were used (note I commented
default xml parser, and replaced with
(xalan & xercesImpl) parser.jar line)

wrapper.class_path=$(wrapper.tomcat_home)\classes
wrapper.class_path=$(wrapper.tomcat_home)\lib\xalan.jar
wrapper.class_path=$(wrapper.tomcat_home)\lib\xercesImpl.jar
wrapper.class_path=$(wrapper.tomcat_home)\lib\jaxp.jar
#wrapper.class_path=$(wrapper.tomcat_home)\lib\parser.jar
wrapper.class_path=$(wrapper.tomcat_home)\lib\webserver.jar
wrapper.class_path=$(wrapper.tomcat_home)\lib\servlet.jar
wrapper.class_path=$(wrapper.tomcat_home)\lib\jasper.jar
wrapper.class_path=$(wrapper.tomcat_home)\lib\logfilewriter.jar

interestingly when running from command line the alternate xml parser xerces
was picked up and Tomcat
started flawlessly..

Any one knows if this

a/ my ignorance, and there is a solution

b/ a real defect

regards

RE: Tomcat 3.2 run as NT service with xml parser other than its default (parser.jar)

Posted by Andrew Milkowski <am...@unicast.com>.
Jean! Thank You very much for your time in this busy world!, your comment on
JVM 1.4 prompted me to switch
to this JVM ver. .1.4.1 (beta) (instead of 1.2 I was using), I did not need
to place any jars in the "ext" directory!
xerces was recognized from the wrapper.properties! hmmmm curious but useless
now problem remains why using JVM 1.2
causes such a problem

Thanks again

-----Original Message-----
From: Jean-francois Arcand [mailto:jeanfrancois.arcand@sun.com]
Sent: Thursday, August 08, 2002 11:01 AM
To: Tomcat Developers List
Subject: Re: Tomcat 3.2 run as NT service with xml parser other than its
default (parser.jar)




Andrew Milkowski wrote:

>receiving following exception while running Tomcat as NT service
>
>javax.xml.parsers.FactoryConfigurationError:
>com.sun.xml.parser.SAXParserFactoryImpl
>	at
javax.xml.parsers.SAXParserFactory.newInstance(SAXParserFactory.java:84)
>	at org.apache.tomcat.util.xml.XmlMapper.readXml(XmlMapper.java:210)
>	at org.apache.tomcat.startup.Tomcat.execute(Tomcat.java:187)
>	at org.apache.tomcat.startup.Tomcat.main(Tomcat.java:235)
>Exception in thread "main"
>
>
>following wrapper.properties classpath values were used (note I commented
>default xml parser, and replaced with
>(xalan & xercesImpl) parser.jar line)
>
>wrapper.class_path=$(wrapper.tomcat_home)\classes
>wrapper.class_path=$(wrapper.tomcat_home)\lib\xalan.jar
>wrapper.class_path=$(wrapper.tomcat_home)\lib\xercesImpl.jar
>wrapper.class_path=$(wrapper.tomcat_home)\lib\jaxp.jar
>#wrapper.class_path=$(wrapper.tomcat_home)\lib\parser.jar
>wrapper.class_path=$(wrapper.tomcat_home)\lib\webserver.jar
>wrapper.class_path=$(wrapper.tomcat_home)\lib\servlet.jar
>wrapper.class_path=$(wrapper.tomcat_home)\lib\jasper.jar
>wrapper.class_path=$(wrapper.tomcat_home)\lib\logfilewriter.jar
>
Not sure it the proper way to replace the parser. You should put your
jar under CATALINA_HOME/common/endorsed or under j2sdkXX/jre/lib/ext (I
recommend the first one). This is the suggested way when you want to use
another parser than the defaut one.

If you use jdk 1.4, see

    http://java.sun.com/j2se/1.4/docs/guide/standards/



-- Jeanfrancois


>
>interestingly when running from command line the alternate xml parser
xerces
>was picked up and Tomcat
>started flawlessly..
>
>Any one knows if this
>
>a/ my ignorance, and there is a solution
>
>b/ a real defect
>
>regards
>
>
>------------------------------------------------------------------------
>
>--
>To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
>For additional commands, e-mail:
<ma...@jakarta.apache.org>
>

--
Jean-Francois Arcand
Java and XML Software, Sun Microsystems
450.224.4753



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


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


Re: Tomcat 3.2 run as NT service with xml parser other than its default (parser.jar)

Posted by Jean-francois Arcand <je...@sun.com>.

Andrew Milkowski wrote:

>receiving following exception while running Tomcat as NT service
>
>javax.xml.parsers.FactoryConfigurationError:
>com.sun.xml.parser.SAXParserFactoryImpl
>	at javax.xml.parsers.SAXParserFactory.newInstance(SAXParserFactory.java:84)
>	at org.apache.tomcat.util.xml.XmlMapper.readXml(XmlMapper.java:210)
>	at org.apache.tomcat.startup.Tomcat.execute(Tomcat.java:187)
>	at org.apache.tomcat.startup.Tomcat.main(Tomcat.java:235)
>Exception in thread "main"
>
>
>following wrapper.properties classpath values were used (note I commented
>default xml parser, and replaced with
>(xalan & xercesImpl) parser.jar line)
>
>wrapper.class_path=$(wrapper.tomcat_home)\classes
>wrapper.class_path=$(wrapper.tomcat_home)\lib\xalan.jar
>wrapper.class_path=$(wrapper.tomcat_home)\lib\xercesImpl.jar
>wrapper.class_path=$(wrapper.tomcat_home)\lib\jaxp.jar
>#wrapper.class_path=$(wrapper.tomcat_home)\lib\parser.jar
>wrapper.class_path=$(wrapper.tomcat_home)\lib\webserver.jar
>wrapper.class_path=$(wrapper.tomcat_home)\lib\servlet.jar
>wrapper.class_path=$(wrapper.tomcat_home)\lib\jasper.jar
>wrapper.class_path=$(wrapper.tomcat_home)\lib\logfilewriter.jar
>
Not sure it the proper way to replace the parser. You should put your 
jar under CATALINA_HOME/common/endorsed or under j2sdkXX/jre/lib/ext (I 
recommend the first one). This is the suggested way when you want to use 
another parser than the defaut one.

If you use jdk 1.4, see

    http://java.sun.com/j2se/1.4/docs/guide/standards/



-- Jeanfrancois


>
>interestingly when running from command line the alternate xml parser xerces
>was picked up and Tomcat
>started flawlessly..
>
>Any one knows if this
>
>a/ my ignorance, and there is a solution
>
>b/ a real defect
>
>regards
>  
>
>------------------------------------------------------------------------
>
>--
>To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
>For additional commands, e-mail: <ma...@jakarta.apache.org>
>

-- 
Jean-Francois Arcand
Java and XML Software, Sun Microsystems 
450.224.4753



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