This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Running FOP on a Servlet


hi linda,
  i am able to generate pdf through a servlet.  there is no error messges.  i am using the FOPServlet that comes with the distribution of  FOP.  
  try with that code.
cheers!!!!
Rabi






 
--

On Wed, 6 Jun 2001 08:30:24   
 Linda Zammit wrote:
>Hello all,
>
>Has anyone experience a problem like below?  I can't figure out why there is
>a difference when running this code in a Java application vs. a Servlet.
>
>In Java application, the following code runs great.  But, if it's run in a
>Servlet on WebLogic then it errors with the following:
>
>JAVA CODE:
>
>String [] args = { "-d","-xml", "config\\mydomain\\applications
>try{
>CommandLineOptions options = new CommandLineOptions (args);
>Starter starter = options.getStarter();
>if(starter != null)
>out.println("<p>got starter");
>starter.run();
>out.println("<p>after run starter");
>}
>catch(Exception e){
>out.println("Exception" + e.getMessage());
>}
>
>
>ERROR MESSAGE:
>Input mode: xslt transformation
>xml input file:
>config\mydomain\applications\DefaultWebApp_myserver\xml\xslfoRef
>.xml
>xslt stylesheet:
>config\mydomain\applications\DefaultWebApp_myserver\xml\xml2pdf
>.xsl
>Output mode: pdf
>output file:
>config\mydomain\applications\DefaultWebApp_myserver\pdf\test.pdf
>OPTIONS
>no user configuration file is used [default]
>debug mode on
>don't dump configuration [default]
>quiet mode off [default]
>base directory:
>D:\product\bea\wlserver6.0sp1\config\mydomain\applications\Defau
>ltWebApp_myserver\xml
>FOP 0.18.1-DEV
>using SAX parser org.apache.xerces.parsers.SAXParser
>Input mode: xslt transformation
>xml input file:
>config\mydomain\applications\DefaultWebApp_myserver\xml\xslfoRef
>.xml
>xslt stylesheet:
>config\mydomain\applications\DefaultWebApp_myserver\xml\xml2pdf
>.xsl
>Output mode: pdf
>output file:
>config\mydomain\applications\DefaultWebApp_myserver\pdf\test.pdf
>OPTIONS
>no user configuration file is used [default]
>debug mode on
>don't dump configuration [default]
>quiet mode off [default]
>base directory:
>D:\product\bea\wlserver6.0sp1\config\mydomain\applications\Defau
>ltWebApp_myserver\xml
>FOP 0.18.1-DEV
>using SAX parser org.apache.xerces.parsers.SAXParser
>D:\product\bea\wlserver6.0sp1\config\mydomain\applications\DefaultWebApp_mys
>erve
>r\xml\xml2pdf.xsl; Line 0; Column 0
>D:\product\bea\wlserver6.0sp1\config\mydomain\applications\DefaultWebApp_mys
>erve
>r\xml\xml2pdf.xsl; Line 0; Column 0
>
>XSL Error: Could not parse
>
>D:\product\bea\wlserver6.0sp1\config\mydomain\applica
>tions\DefaultWebApp_myserver\xml\xml2pdf.xsl document!
>java.lang.reflect.InvocationTargetException:
>org.apache.xalan.xslt.XSLProcessorE
>xception: File
>"D:\product\bea\wlserver6.0sp1\config\mydomain\applications\Defau
>ltWebApp_myserver\xml\xml2pdf.xsl" not found.
>at
>org.apache.xalan.xslt.XSLTEngineImpl.error(XSLTEngineImpl.java:1710)
>at
>org.apache.xalan.xslt.XSLTEngineImpl.processStylesheet(XSLTEngineImpl
>.java:770)
>at
>org.apache.fop.tools.xslt.Xalan1Transform.getStylesheet(Xalan1Transfo
>rm.java:88)
>at
>org.apache.fop.tools.xslt.Xalan1Transform.transform(Xalan1Transform.j
>ava:142)
>at java.lang.reflect.Method.invoke(Native Method)
>at
>org.apache.fop.tools.xslt.XSLTransform.transform(XSLTransform.java:11
>9)
>at
>org.apache.fop.tools.xslt.XSLTransform.transform(XSLTransform.java:94
>)
>at
>org.apache.fop.apps.XSLTInputHandler.getInputSource(XSLTInputHandler.
>java:60)
>at
>org.apache.fop.apps.CommandLineStarter.run(CommandLineStarter.java:49
>)
>at org.apache.fop.apps.Fop.main(Fop.java:14)
>at com.loggate.servlets.DocServlet.service(DocServlet.java:143)
>at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
>at
>weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubIm
>pl.java:213)
>at
>weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppSe
>rvletContext.java:1265)
>at
>weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestIm
>pl.java:1622)
>at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:137)
>at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)
>(etc.)
>
>
>Linda Zammit
>---
>Outgoing mail is certified Virus Free.
>Checked by AVG anti-virus system (http://www.grisoft.com).
>Version: 6.0.250 / Virus Database: 123 - Release Date: 4/18/2001
>
>
> XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
>
>


Get 250 color business cards for FREE!
http://businesscards.lycos.com/vp/fastpath/

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]