cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From PLISSON Sébastien (DSIT-XS) <sebastien.plis...@sncf.fr>
Subject RE: Why this doesn't work???
Date Thu, 20 Feb 2003 14:50:02 GMT
I think you should use <map:parameter> to pass parameters to your jsp.

-----Message d'origine-----
De : Eduardo Zurita [mailto:g000039@correo.cajacanarias.es]
Envoyé : jeudi 20 février 2003 15:43
À : cocoon-users@xml.apache.org
Objet : Why this doesn't work???


Hello,
 
    I am confused about this:
 
    The following map runs ok and the file test.jsp exists:
 

<map:match pattern="recsal.html">
  <map:generate type="jsp" src="services/test.jsp"/>
  <map:serialize type="html"/>
</map:match>
 
    But the following doesn't work: (I have just added a parameter in
querystring that does nothing into the .jsp file). (The test.jsp is the same
one).
    
<map:match pattern="recsal.html">
  <map:generate type="jsp" src="services/test.jsp?myparam=hello"/>
  <map:serialize type="html"/>
</map:match>
 
    And the following produces exactly same error that previous map: (And
the file doesn't exists!!!!)
 

<map:match pattern="recsal.html">
  <map:generate type="jsp" src="services/whathappen.jsp"/>
  <map:serialize type="html"/>
</map:match>
 
    And the error produced by the second and third examples is: (replace
test.jsp with whathappen.jsp if you want). (Extracted from core.log):
 
DEBUG   (2003-02-20) 14:27.59:659   [core.manager] (/pec/recsal.html)
Thread-19/JspGenerator: JspGenerator executing
JSP:/services/test.jsp?myparam=hello
DEBUG   (2003-02-20) 14:27.59:728   [core.manager] (/pec/recsal.html)
Thread-19/JspGenerator: SAXException JspGenerator.generate()
org.xml.sax.SAXParseException: Premature end of file.
 at
org.apache.xerces.util.ErrorHandlerWrapper.createSAXParseException(ErrorHand
lerWrapper.java:232)
 at
org.apache.xerces.util.ErrorHandlerWrapper.fatalError(ErrorHandlerWrapper.ja
va:213)
 at
org.apache.xerces.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:36
6)
 at
org.apache.xerces.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:29
6)
 at org.apache.xerces.impl.XMLScanner.reportFatalError(XMLScanner.java:1244)
 at
org.apache.xerces.impl.XMLDocumentScannerImpl$XMLDeclDispatcher.dispatch(XML
DocumentScannerImpl.java:587)
 at
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocume
ntFragmentScannerImpl.java:333)
 at
org.apache.xerces.parsers.StandardParserConfiguration.parse(StandardParserCo
nfiguration.java:525)
 at
org.apache.xerces.parsers.StandardParserConfiguration.parse(StandardParserCo
nfiguration.java:581)
 at org.apache.xerces.parsers.XMLParser.parse(XMLParser.java:147)
 at
org.apache.xerces.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:115
7)
 at org.apache.avalon.excalibur.xml.XercesParser.parse(XercesParser.java:77)
 at org.apache.avalon.excalibur.xml.XercesParser.parse(XercesParser.java:50)
 at
org.apache.cocoon.generation.JspGenerator.generate(JspGenerator.java:129)
 at
org.apache.cocoon.components.pipeline.CachingEventPipeline.process(CachingEv
entPipeline.java:250)
 at
org.apache.cocoon.components.pipeline.CachingStreamPipeline.process(CachingS
treamPipeline.java:395)
 at
org.apache.cocoon.www.sitemap_xmap.matchN4000C5(/usr/local/tomcat/work/Stand
alone/localhost/pec/cocoon-files/org/apache/cocoon/www/sitemap_xmap.java:908
)
 at
org.apache.cocoon.www.sitemap_xmap.process(/usr/local/tomcat/work/Standalone
/localhost/pec/cocoon-files/org/apache/cocoon/www/sitemap_xmap.java:657)
 at
org.apache.cocoon.www.sitemap_xmap.process(/usr/local/tomcat/work/Standalone
/localhost/pec/cocoon-files/org/apache/cocoon/www/sitemap_xmap.java:589)
 at org.apache.cocoon.sitemap.Handler.process(Handler.java:227)
 at org.apache.cocoon.sitemap.Manager.invoke(Manager.java:173)
 at
org.apache.cocoon.sitemap.SitemapManager.process(SitemapManager.java:152)
 at org.apache.cocoon.Cocoon.process(Cocoon.java:579)
 at org.apache.cocoon.servlet.CocoonServlet.service(CocoonServlet.java:1043)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
 at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
FilterChain.java:247)
 at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
ain.java:193)
 at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja
va:260)
 at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
eNext(StandardPipeline.java:643)
 at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
 at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
 at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja
va:191)
 at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
eNext(StandardPipeline.java:643)
 at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
 at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
 at
org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2415)
 at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180
)
 at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
eNext(StandardPipeline.java:643)
 at
org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.
java:170)
 at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
eNext(StandardPipeline.java:641)
 at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:172
)
 at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
eNext(StandardPipeline.java:641)
 at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
 at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
 at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java
:174)
 at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
eNext(StandardPipeline.java:643)
 at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
 at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
 at org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:223)
 at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:261)
 at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:360)
 at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:632)
 at
org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:590)
 at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:707)
 at
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.jav
a:530)
 at java.lang.Thread.run(Thread.java:536)
 
Thanks in advance.
 
Eduardo.


Mime
View raw message