SunQuest
           XML Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming Languages - MoreXML Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Get inside! Sample the range of functionality easily built with JMSL Library for Time Series Data Analysis, Heat Maps, Portfolio Optimization, Monte Carlo Simulation, Stock Price Charting and more. Download Now!
  #1  
Old August 8th, 2003, 04:20 AM
thrybergh thrybergh is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2003
Posts: 2 thrybergh User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Xalan 2.5, Xerces 2.3 and JDK1.4.1

Hello.

I wonder if anyone has any experience of this problem?

I am using JDK1.4.1 and Xalan 2.5.D11. The xalan.jar is in the endorsed directory for Tomcat and I have tested the version number by printing it to the screen. I am confused as to why I get the "NoClassDefFoundError" since the xalan.jar is accessible. Am I getting a combination of the later Xalan version and the version included in JDK1.4?

The webapp is hosted by jsp-servlets.net, so I do not have full access to the Tomcat config.

Any ideas would be appreciated!

I have been checking the versions of Xalan, Xerces and JDK that I am using. My app is seeing the new Xalan version OK. Another important difference is that I compile on Win98 and run on Linux.

#---- BEGIN writeEnvironmentReport($Revision: 1.17 $): Useful stuff found: ----
java.version=1.4.1_01
version.xalan2x=Xalan Java 2.5.D1
version.JAXP=1.1
version.SAX=2.0
version.crimson=present-unknown-version
java.class.path=WARNING: SecurityException thrown accessing system classpath properties
version.ant=not-present
sun.boot.class.path=/home/tomcat41/common/endorsed/xercesImpl.jar
:/home/tomcat41/common/endorsed/xmlParserAPIs.jar
:/home/tomcat41/common/endorsed/xalan.jar
:/opt/j2sdk1.4.1_01/jre/lib/rt.jar
:/opt/j2sdk1.4.1_01/jre/lib/i18n.jar
:/opt/j2sdk1.4.1_01/jre/lib/sunrsasign.jar
:/opt/j2sdk1.4.1_01/jre/lib/jsse.jar
:/opt/j2sdk1.4.1_01/jre/lib/jce.jar
:/opt/j2sdk1.4.1_01/jre/lib/charsets.jar
:/opt/j2sdk1.4.1_01/jre/classes
version.DOM.draftlevel=2.0fd
version.DOM=2.0
version.xalan1=not-present
version.xalan2_2=Xalan Java 2.5.D1
version.xerces2=Xerces-J 2.3.0
version.xerces1=not-present
#----- END writeEnvironmentReport: Useful properties found: -----
# YAHOO! Your environment seems to be OK.


The error is:

java.lang.NoClassDefFoundError
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:140)
at org.apache.xalan.serialize.SerializerFactory.getSerializer(SerializerFactory.java:125)
at org.apache.xalan.transformer.TransformerImpl.createResultContentHandler(TransformerImpl.java:1045)
at org.apache.xalan.transformer.TransformerImpl.createResultContentHandler(TransformerImpl.java:972)
at org.apache.xalan.transformer.TransformerImpl.transform(TransformerImpl.java:1121)
at org.apache.xalan.transformer.TransformerImpl.transform(TransformerImpl.java:1104)
at flan.predictions.servlet.RequestHandler.outputXML(RequestHandler.java:175)


thank you.

Reply With Quote
  #2  
Old October 30th, 2003, 08:49 AM
Winfried Reiss Winfried Reiss is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Oct 2003
Posts: 1 Winfried Reiss User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
This seems to be a sandbox problem. Some class tries to read a ressource but is not allowed to do so. I think, I can give a roundabout though not a solution:
Include in a .jav.policy- file in your home directory lines as follows:

grant codeBase "http://SERVER_ADDRESS_WHERE_THE APPLETCLASS_IS STORED" {
permission java.io.FilePermission "C:\\Program Files\\Java\\j2re1.4.2_02\\lib\\-", "read";
};


(Change the path to the location of your Java-JRE)

This helps with my applet, though I would like to get a solution without a java-policy.

Reply With Quote
  #3  
Old October 30th, 2003, 08:52 AM
thrybergh thrybergh is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2003
Posts: 2 thrybergh User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Thanks for helping.

What I had to do was have permission granted so that my application could read the Xalan.jar file. It was not enough to simply "access" it to run the classes, rather it had to be able to read a .properties file within the jar.

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreXML Programming > Xalan 2.5, Xerces 2.3 and JDK1.4.1


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 5 hosted by Hostway