Xalan servlet samples on Tomcat 2003-01-29 - By Gary L Peskin
If you have changed SimpleXSLTServlet to not look for trax.xml and it's still looking for trax.xml, you are executing a different version of SimpleXSLTServlet. Your UseStylesheetParamServlet also indicates a CLASSPATH problem and it seems that you are mixing components from different versions of Xerces.
This is really a Tomcat question since you haven't even invoked XalanJ yet.
What jar files are in testapp1/WEB-INF/lib?
Also, please insert the line
(new EnvironmentCheck()).checkEnvironment(yourPrintWriter);
into your servlet after creating a PrintWriter. This will help us see what your environment looks like.
HTH, Gary
> -----Original Message----- > From: Balint Fulop [mailto:fuli42@(protected)] > Sent: Wednesday, January 29, 2003 11:37 AM > To: xalan-j-users@(protected) > Subject: Xalan servlet samples on Tomcat > > > Hello! > > Please could anyone point why my setup is malfunctioning? > Description as > follows. > Thanks everyone in advance. > > > Problem: > I am trying to run the servlet samples that came with Xalan, > but none of > them has given any positive result so far. > > > The setup: > > WinXP Pro, Java SDK 1.3 from IBM, Tomcat 4.1.18 (the full > version), and > Xalan-J 2.4.1 > I have enabled the Invoker Servlet, and Root Context on > Tomcat, turned on > Servlet Reloading, and set the Java_Home path, the casspaths > for the .jar > files that came with Xalan, and the servlet.jar file that > came with Tomcat > (and the current dir (.) and my development dir as well.) > I have succesfully tested the setup with a few simple > servlets, including > ones that use packages and utilities. > > > The webapp: > > I have created a directory called testapp1, which includes > all the dirs, > that the Root has, plus a classes and lib directory in > Web-inf. I have placed the .jar files that came with Xalan in > the lib dir within > testapp1/WEB-INF, compiled the sample java files, and put them in the > classes dir. The xml, and xsl sample files went into the > testapp1 root dir. > > > The errors: > > I am getting all kinds of error messages. The > SimpleXSLTServlet gives an > FileNotFoundException: trax.xml error, even though I have > changed, and > recomplid, and updated the java code, and class and it does > not even has the > term 'trax.xml' in it !! > For the UseStylesheetParamServlet sample I am getting: > java.lang.VerifyError: Class > org/apache/xerces/impl/XMLNSDocumentScannerImpl$NSContentDispa > tcher is > subclass of final class > org/apache/xerces/impl/XMLDocumentScannerImpl$ContentDispatcher > etc. etc. > > > I have went through the maillist archives, goolge, ask.com, > but I could not > resolve the errors. I have practically zero knowledge of > Java, I just want > to use the Xalan samples to do simple transforms, and queries > for my friends > weblog. The samples would more that adequate for the job. > > > Thanks for the help and your time, > > > Balint > > _________________________________________________________________ > MSN 8 helps eliminate e-mail viruses. Get 2 months FREE*. > http://join.msn.com/?page�atures/virus >
|
|