ORA-00911: invalid character
Title: ORA-00911: invalid character Hello comunity, i have one problem with execute of SQL-statement. I use Oracle 8.1.7, Tomcat 4.0.1 and Cocoon I have added nls_charset12.jar to my CLASSPATH and changed a xsp file: ?xml version=1.0 encoding=UTF-8? !-- ISO-8859-1 -- . . . esql:execute-query !-- esql:queryupdate products set product = 'xsp-request:get-parameter name=product/', description = 'xsp-request:get-parameter name=description/', information = 'xsp-request:get-parameter name=information/' where product_key = xsp:exprproductKey/xsp:expr;/esql:query -- esql:queryxsp:exprupdate products set product = ' + xsp-request:get-parameter name=product/ + ', description = ' + xsp-request:get-parameter name=description/ + ', information = ' + xsp-request:get-parameter name=information/ + ' where product_key = + xsp:exprproductKey/xsp:expr+ ;/xsp:expr/esql:query esql:results esql:row-results parahello/para /esql:row-results esql:error-results parabr/updating: the following error occured: esql:get-message//para /esql:error-results /esql:results /esql:execute-query . . . I got allways this exception: ERROR (2003-01-20) 09:35.41:119 [sitemap] (/prod/admin/article/add.html) HttpProcessor[8080][4]/sitemap_xmap: Sitemap org.apache.cocoon.ProcessingException: Exception in ServerPagesGenerator.generate(): java.lang.RuntimeException: Error executing statement: update products set product = 'uuu', description = '', information = 'zz' where product_key = 46;: java.sql.SQLException: ORA-00911: invalid character at org.apache.cocoon.generation.ServerPagesGenerator.generate(ServerPagesGenerator.java:270) at org.apache.cocoon.components.pipeline.CachingEventPipeline.process(CachingEventPipeline.java:250) at org.apache.cocoon.components.source.SitemapSource.toSAX(SitemapSource.java:353) at org.apache.cocoon.sitemap.ContentAggregator.generate(ContentAggregator.java:148) at org.apache.cocoon.components.pipeline.CachingEventPipeline.process(CachingEventPipeline.java:250) at org.apache.cocoon.components.pipeline.CachingStreamPipeline.process(CachingStreamPipeline.java:399) at org.apache.cocoon.www.sitemap_xmap.matchN10388(/appl/tomcat/4.0.1/work/localhost/prod/cocoon-files/org/apache/cocoon/www/sitemap_xmap.java:3312) at org.apache.cocoon.www.sitemap_xmap.process(/appl/tomcat/4.0.1/work/localhost/prod/cocoon-files/org/apache/cocoon/www/sitemap_xmap.java:2340) at org.apache.cocoon.www.sitemap_xmap.process(/appl/tomcat/4.0.1/work/localhost/prod/cocoon-files/org/apache/cocoon/www/sitemap_xmap.java:2223) at org.apache.cocoon.sitemap.Handler.process(Handler.java:224) at org.apache.cocoon.sitemap.Manager.invoke(Manager.java:179) at org.apache.cocoon.sitemap.SitemapManager.process(SitemapManager.java:154) at org.apache.cocoon.Cocoon.process(Cocoon.java:575) at org.apache.cocoon.servlet.CocoonServlet.service(CocoonServlet.java:999) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:243) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:201) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:518) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2344) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:164) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566) at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:170) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:170) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:462) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at
[XMLForm] initialization of the model
Hi all, I'm trying to initialize the model of a XMLForm app each time I call this app. This app is launching from the Cocoon portal, in an authenticated environment. I have followed the solution coming from the posts in this list (thank you for that). The solution was to override the getFormModel() method in the Action class to initialize the model inside. I've done this but I still have a problem: the initialization is proceeded only the first time I call the app (the action) and not each time. What should I do for doing this? Is there maybe a session problem? Any help would be greatly appreciated. Thank you Sylvain - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Portal - NullPointerException Error
Hello, What have you modified? Regards Sylvain -Message d'origine- De: Richard Reyes [mailto:[EMAIL PROTECTED]] Date: lundi, 20. janvier 2003 06:39 À: cocoon-users Objet: Portal - NullPointerException Error Hi Guys, I've been trying to modify the cocoon portal configurations to suit my needs, when i accidentally stumbled into this nullpointerexception error... Original exception : java.lang.NullPointerException at org.apache.cocoon.webapps.portal.components.PortalManager.showPortal(PortalManager.java:740) at org.apache.cocoon.webapps.portal.generation.PortalGenerator.generate(PortalGenerator.java:82) at org.apache.cocoon.components.pipeline.AbstractProcessingPipeline.processXMLPipeline(AbstractProcessingPipeline.java:537) at org.apache.cocoon.components.pipeline.impl.AbstractCachingProcessingPipeline.processXMLPipeline(AbstractCachingProcessingPipeline.java:213) at org.apache.cocoon.components.pipeline.AbstractProcessingPipeline.process(AbstractProcessingPipeline.java:481) at org.apache.cocoon.components.treeprocessor.sitemap.SerializeNode.invoke(SerializeNode.java:148) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:84) at org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatchNode.invoke(PreparableMatchNode.java:164) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:108) at org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(PipelineNode.java:153) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:108) at org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(PipelinesNode.java:143) at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcessor.java:317) at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcessor.java:299) at org.apache.cocoon.components.treeprocessor.sitemap.MountNode.invoke(MountNode.java:134) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:84) at org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatchNode.invoke(PreparableMatchNode.java:164) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:108) at org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(PipelineNode.java:153) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:108) at org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(PipelinesNode.java:143) at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcessor.java:317) at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcessor.java:299) at org.apache.cocoon.Cocoon.process(Cocoon.java:600) at org.apache.cocoon.servlet.CocoonServlet.service(CocoonServlet.java:1104) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:260) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(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.java:191) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(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.invokeNext(StandardPipeline.java:643) at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:170) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:172) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) at
Re: Portal - NullPointerException Error
mainly naming conventions, ( yet ). i would like to just remove the sunspotdemo word. anything you need to help you help me?? - Original Message - From: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, January 20, 2003 4:38 PM Subject: RE: Portal - NullPointerException Error Hello, What have you modified? Regards Sylvain -Message d'origine- De: Richard Reyes [mailto:[EMAIL PROTECTED]] Date: lundi, 20. janvier 2003 06:39 À: cocoon-users Objet: Portal - NullPointerException Error Hi Guys, I've been trying to modify the cocoon portal configurations to suit my needs, when i accidentally stumbled into this nullpointerexception error... Original exception : java.lang.NullPointerException at org.apache.cocoon.webapps.portal.components.PortalManager.showPortal(PortalM anager.java:740) at org.apache.cocoon.webapps.portal.generation.PortalGenerator.generate(PortalG enerator.java:82) at org.apache.cocoon.components.pipeline.AbstractProcessingPipeline.processXMLP ipeline(AbstractProcessingPipeline.java:537) at org.apache.cocoon.components.pipeline.impl.AbstractCachingProcessingPipeline .processXMLPipeline(AbstractCachingProcessingPipeline.java:213) at org.apache.cocoon.components.pipeline.AbstractProcessingPipeline.process(Abs tractProcessingPipeline.java:481) at org.apache.cocoon.components.treeprocessor.sitemap.SerializeNode.invoke(Seri alizeNode.java:148) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo keNodes(AbstractParentProcessingNode.java:84) at org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatchNode.invok e(PreparableMatchNode.java:164) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo keNodes(AbstractParentProcessingNode.java:108) at org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(Pipel ineNode.java:153) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo keNodes(AbstractParentProcessingNode.java:108) at org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(Pipe linesNode.java:143) at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcess or.java:317) at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcess or.java:299) at org.apache.cocoon.components.treeprocessor.sitemap.MountNode.invoke(MountNod e.java:134) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo keNodes(AbstractParentProcessingNode.java:84) at org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatchNode.invok e(PreparableMatchNode.java:164) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo keNodes(AbstractParentProcessingNode.java:108) at org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(Pipel ineNode.java:153) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo keNodes(AbstractParentProcessingNode.java:108) at org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(Pipe linesNode.java:143) at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcess or.java:317) at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcess or.java:299) at org.apache.cocoon.Cocoon.process(Cocoon.java:600) at org.apache.cocoon.servlet.CocoonServlet.service(CocoonServlet.java:1104) 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
RE: Portal - NullPointerException Error
Hi Richard, You have to modify: -sitemap -views (in resources\ directory) -stylessheets (in styles\ directory) -coplets configuration (Portal Management in the portal) Search for the word in each one. Regards Sylvain -Message d'origine- De: Richard Reyes [mailto:[EMAIL PROTECTED]] Date: lundi, 20. janvier 2003 10:36 À: [EMAIL PROTECTED] Objet: Re: Portal - NullPointerException Error mainly naming conventions, ( yet ). i would like to just remove the sunspotdemo word. anything you need to help you help me?? - Original Message - From: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, January 20, 2003 4:38 PM Subject: RE: Portal - NullPointerException Error Hello, What have you modified? Regards Sylvain -Message d'origine- De: Richard Reyes [mailto:[EMAIL PROTECTED]] Date: lundi, 20. janvier 2003 06:39 À: cocoon-users Objet: Portal - NullPointerException Error Hi Guys, I've been trying to modify the cocoon portal configurations to suit my needs, when i accidentally stumbled into this nullpointerexception error... Original exception : java.lang.NullPointerException at org.apache.cocoon.webapps.portal.components.PortalManager.showPortal(PortalM anager.java:740) at org.apache.cocoon.webapps.portal.generation.PortalGenerator.generate(PortalG enerator.java:82) at org.apache.cocoon.components.pipeline.AbstractProcessingPipeline.processXMLP ipeline(AbstractProcessingPipeline.java:537) at org.apache.cocoon.components.pipeline.impl.AbstractCachingProcessingPipeline .processXMLPipeline(AbstractCachingProcessingPipeline.java:213) at org.apache.cocoon.components.pipeline.AbstractProcessingPipeline.process(Abs tractProcessingPipeline.java:481) at org.apache.cocoon.components.treeprocessor.sitemap.SerializeNode.invoke(Seri alizeNode.java:148) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo keNodes(AbstractParentProcessingNode.java:84) at org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatchNode.invok e(PreparableMatchNode.java:164) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo keNodes(AbstractParentProcessingNode.java:108) at org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(Pipel ineNode.java:153) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo keNodes(AbstractParentProcessingNode.java:108) at org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(Pipe linesNode.java:143) at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcess or.java:317) at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcess or.java:299) at org.apache.cocoon.components.treeprocessor.sitemap.MountNode.invoke(MountNod e.java:134) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo keNodes(AbstractParentProcessingNode.java:84) at org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatchNode.invok e(PreparableMatchNode.java:164) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo keNodes(AbstractParentProcessingNode.java:108) at org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(Pipel ineNode.java:153) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo keNodes(AbstractParentProcessingNode.java:108) at org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(Pipe linesNode.java:143) at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcess or.java:317) at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcess or.java:299) at org.apache.cocoon.Cocoon.process(Cocoon.java:600) at org.apache.cocoon.servlet.CocoonServlet.service(CocoonServlet.java:1104) 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
Re: Portal - NullPointerException Error
Thanks but I did all that... thats why I cant locate my error because I think that I have modifed them all completely and hopefully correctly. But im still checking... thanks anyway any other ideas? - Original Message - From: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, January 20, 2003 5:39 PM Subject: RE: Portal - NullPointerException Error Hi Richard, You have to modify: -sitemap -views (in resources\ directory) -stylessheets (in styles\ directory) -coplets configuration (Portal Management in the portal) Search for the word in each one. Regards Sylvain -Message d'origine- De: Richard Reyes [mailto:[EMAIL PROTECTED]] Date: lundi, 20. janvier 2003 10:36 À: [EMAIL PROTECTED] Objet: Re: Portal - NullPointerException Error mainly naming conventions, ( yet ). i would like to just remove the sunspotdemo word. anything you need to help you help me?? - Original Message - From: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, January 20, 2003 4:38 PM Subject: RE: Portal - NullPointerException Error Hello, What have you modified? Regards Sylvain -Message d'origine- De: Richard Reyes [mailto:[EMAIL PROTECTED]] Date: lundi, 20. janvier 2003 06:39 À: cocoon-users Objet: Portal - NullPointerException Error Hi Guys, I've been trying to modify the cocoon portal configurations to suit my needs, when i accidentally stumbled into this nullpointerexception error... Original exception : java.lang.NullPointerException at org.apache.cocoon.webapps.portal.components.PortalManager.showPortal(PortalM anager.java:740) at org.apache.cocoon.webapps.portal.generation.PortalGenerator.generate(PortalG enerator.java:82) at org.apache.cocoon.components.pipeline.AbstractProcessingPipeline.processXMLP ipeline(AbstractProcessingPipeline.java:537) at org.apache.cocoon.components.pipeline.impl.AbstractCachingProcessingPipeline .processXMLPipeline(AbstractCachingProcessingPipeline.java:213) at org.apache.cocoon.components.pipeline.AbstractProcessingPipeline.process(Abs tractProcessingPipeline.java:481) at org.apache.cocoon.components.treeprocessor.sitemap.SerializeNode.invoke(Seri alizeNode.java:148) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo keNodes(AbstractParentProcessingNode.java:84) at org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatchNode.invok e(PreparableMatchNode.java:164) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo keNodes(AbstractParentProcessingNode.java:108) at org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(Pipel ineNode.java:153) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo keNodes(AbstractParentProcessingNode.java:108) at org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(Pipe linesNode.java:143) at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcess or.java:317) at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcess or.java:299) at org.apache.cocoon.components.treeprocessor.sitemap.MountNode.invoke(MountNod e.java:134) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo keNodes(AbstractParentProcessingNode.java:84) at org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatchNode.invok e(PreparableMatchNode.java:164) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo keNodes(AbstractParentProcessingNode.java:108) at org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(Pipel ineNode.java:153) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo keNodes(AbstractParentProcessingNode.java:108) at org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(Pipe linesNode.java:143) at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcess or.java:317) at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcess or.java:299) at org.apache.cocoon.Cocoon.process(Cocoon.java:600) at org.apache.cocoon.servlet.CocoonServlet.service(CocoonServlet.java:1104) 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
10 basic survival tips for cocoon users (was: Logicsheet problems- global XSLT variables)
Mark Horgan wrote: Also, do others find working with Cocoon very frustrating? When you make a change it takes forever for the web-app to reload and re-compile the java class, espcially when it takes up so much memory. Also even when using the logs its very hard to track down bugs in ones code especially logicsheets. But generally I like Cocoon though I wish it was more straight-forward to develop with it. Thx in advance, Mark Hy, When i started with cocoon i got really mad with hunting errors and understanding, how all this fits together. But after about three months of working with the beast, i built up some survival strategies. It is how I do it. It may help as a guide, but it does not claim to be the best approach: 1.) Instead of restarting the whole container, i only restart the cocoon app, when needed. This takes a few seconds with tomcat 4.1.* (~300 MHz sparc dual processor, solaris 2.8) 2.) During development i use tomcat and i set the reloadable=true within the Context/ of my webapp. By this any changes in the classpath causes an automatic webapp restart. 3.) use released versions if possible (cocoon-2.0.4 seems quite mature) 4.) Proceed in baby steps when changing things in your cocoon app 5.) follow KISS (keep it simple, stupid) i keep as much as possible with the basics of cocoon and don't use (yet) the more fancy stuff. 6.) Separate your app into subsitemaps and subdirs with related issues 7.) use the cocoon-wiki Especially the search function unhides interesting docs 8.) I started using the coocon developers handbook It's written from Lajos Moczar and some other active cocoon developers... Here are two of my personal favorites. I have documented this in our company wiki: 9.) For XSLT processing i have added Saxon-6.5.2. It's not straight forward to install, but sometimes it can be utilised with less pain, than xalan (just a matter of taste) Look into cocoon wiki for a quick description or look at http://www.saxess.com/JSPWiki/Wiki.jsp?page=Install for a quickinstall step by step instruction. 10.)use entity resolver wherever possible. look at the cocoon docs for the basics or at http://www.saxess.com/JSPWiki/Wiki.jsp?page=EntityResolver for a quickinstall description. hope, that helps someone ... regards, hussayn -- Dr. Hussayn Dabbous SAXESS Software Design GmbH Neuenhöfer Allee 125 50935 Köln Telefon: +49-221-56011-0 Fax: +49-221-56011-20 E-Mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: 10 basic survival tips for cocoon users (was: Logicsheetproblems- global XSLT variables)
Hussayn These tips would be useful on the Cocoon Wiki too! One question - just *how* do you restart only the cocoon app without restarting tomcat (and do you delete the work files somewhere in that process as well?) Thanks Derek [EMAIL PROTECTED] 20/01/2003 12:50:26 Mark Horgan wrote: Also, do others find working with Cocoon very frustrating? When you make a change it takes forever for the web-app to reload and re-compile the java class, espcially when it takes up so much memory. Also even when using the logs its very hard to track down bugs in ones code especially logicsheets. But generally I like Cocoon though I wish it was more straight-forward to develop with it. Thx in advance, Mark Hy,When i started with cocoon i got really mad with hunting errorsand understanding, how all this fits together. But after aboutthree months of working with the beast, i built up somesurvival strategies. It is how I do it. It may help as a guide,but it does not claim to be the "best approach":1.) Instead of restarting the whole container, i only restart the cocoon app, when needed. This takes a few seconds with tomcat 4.1.* (~300 MHz sparc dual processor, solaris 2.8)2.) During development i use tomcat and i set the reloadable="true" within the Context/ of my webapp. By this any changes in the classpath causes an automatic webapp restart.3.) use released versions if possible (cocoon-2.0.4 seems quite mature)4.) Proceed in "baby steps" when changing things in your cocoon app5.) follow KISS (keep it simple, stupid) i keep as much as possible with the basics of cocoon and don't use (yet) the more fancy stuff.6.) Separate your app into subsitemaps and subdirs with related issues7.) use the cocoon-wiki Especially the search function unhides interesting docs8.) I started using the "coocon developers handbook" It's written from Lajos Moczar and some other active cocoon developers...Here are two of my personal favorites. I have documented this inour company wiki:9.) For XSLT processing i have added Saxon-6.5.2. It's not straight forward to install, but sometimes it can be utilised with less pain, than xalan (just a matter of taste) Look into cocoon wiki for a quick description or look at http://www.saxess.com/JSPWiki/Wiki.jsp?page=Install for a quickinstall step by step instruction.10.)use entity resolver wherever possible. look at the cocoon docs for the basics or at http://www.saxess.com/JSPWiki/Wiki.jsp?page=EntityResolver for a quickinstall description.hope, that helps someone ...regards, hussayn-- Dr. Hussayn DabbousSAXESS Software Design GmbHNeuenhöfer Allee 12550935 KölnTelefon: +49-221-56011-0Fax: +49-221-56011-20E-Mail: [EMAIL PROTECTED]-Please check that your question has not already been answered in theFAQ before posting. http://xml.apache.org/cocoon/faq/index.htmlTo unsubscribe, e-mail: [EMAIL PROTECTED]For additional commands, e-mail: [EMAIL PROTECTED]-- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. "The CSIR exercises no editorial control over E-mail messages and/or attachments thereto/links referred to therein originating in the organisation and the views in this message/attachments thereto are therefore not necessarily those of the CSIR and/or its employees. The sender of this e-mail is, moreover, in terms of the CSIR's Conditions of Service, subject to compliance with the CSIR's internal E-mail and Internet Policy."
Re: 10 basic survival tips for cocoon users (was: Logicsheet problems-global XSLT variables)
I use the following tomcat definition for a cocoon based webapp that restarts automatically, when classes or jars change: Context path=/mywebapp docBase=/opt/cocoon/develop reloadable=true debug=0 Resources className=org.apache.naming.resources.FileDirContext allowLinking=true/ /Context /Context interpretation: docbasepoints to where the cocoon app resides reloadable tells tomcat to restart on changes in webapp the Resources tag is only needed, if your webapp directory contains symbolic links or the docbase itself is a symbolic link. NOT NOTE NOTE!!! caveat: Your webapp MUST NOT BE DEPLOYED WITHIN THE webapps Directory, if you use this approach. Otherwise your cocoon app would be started twice !!! Just another hint: Befoire cocoon-2.0.4 the sitemap reloading had a bug, that crashed cocoon under certain circumstances. This bug has been fixed with cocoon-2.0.4. regards, hussayn Derek Hohls wrote: Hussayn These tips would be useful on the Cocoon Wiki too! One question - just *how* do you restart only the cocoon app without restarting tomcat (and do you delete the work files somewhere in that process as well?) Thanks Derek [EMAIL PROTECTED] 20/01/2003 12:50:26 Mark Horgan wrote: Also, do others find working with Cocoon very frustrating? When you make a change it takes forever for the web-app to reload and re-compile the java class, espcially when it takes up so much memory. Also even when using the logs its very hard to track down bugs in ones code especially logicsheets. But generally I like Cocoon though I wish it was more straight-forward to develop with it. Thx in advance, Mark Hy, When i started with cocoon i got really mad with hunting errors and understanding, how all this fits together. But after about three months of working with the beast, i built up some survival strategies. It is how I do it. It may help as a guide, but it does not claim to be the best approach: 1.) Instead of restarting the whole container, i only restart the cocoon app, when needed. This takes a few seconds with tomcat 4.1.* (~300 MHz sparc dual processor, solaris 2.8) 2.) During development i use tomcat and i set the reloadable=true within the Context/ of my webapp. By this any changes in the classpath causes an automatic webapp restart. 3.) use released versions if possible (cocoon-2.0.4 seems quite mature) 4.) Proceed in baby steps when changing things in your cocoon app 5.) follow KISS (keep it simple, stupid) i keep as much as possible with the basics of cocoon and don't use (yet) the more fancy stuff. 6.) Separate your app into subsitemaps and subdirs with related issues 7.) use the cocoon-wiki Especially the search function unhides interesting docs 8.) I started using the coocon developers handbook It's written from Lajos Moczar and some other active cocoon developers... Here are two of my personal favorites. I have documented this in our company wiki: 9.) For XSLT processing i have added Saxon-6.5.2. It's not straight forward to install, but sometimes it can be utilised with less pain, than xalan (just a matter of taste) Look into cocoon wiki for a quick description or look at http://www.saxess.com/JSPWiki/Wiki.jsp?page=Install for a quickinstall step by step instruction. 10.)use entity resolver wherever possible. look at the cocoon docs for the basics or at http://www.saxess.com/JSPWiki/Wiki.jsp?page=EntityResolver for a quickinstall description. hope, that helps someone ... regards, hussayn -- Dr. Hussayn Dabbous SAXESS Software Design GmbH Neuenhöfer Allee 125 50935 Köln Telefon: +49-221-56011-0 Fax: +49-221-56011-20 E-Mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- This message has been scanned for viruses and dangerous content by *MailScanner* http://www.mailscanner.info/, and is believed to be clean. The CSIR exercises no editorial control over E-mail messages and/or attachments thereto/links referred to therein originating in the organisation and the views in this message/attachments thereto are therefore not necessarily those of the CSIR and/or its employees. The sender of this e-mail is, moreover, in terms of the CSIR's Conditions of Service, subject to compliance with the CSIR's internal E-mail and Internet Policy. -- Dr. Hussayn Dabbous SAXESS Software Design GmbH Neuenhöfer Allee 125 50935 Köln Telefon: +49-221-56011-0 Fax: +49-221-56011-20 E-Mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in
new wiki-page: SurvivalTips for cocoon users
Hy; I added my list of survivalTips to the bestPractices page on cocoon wiki: http://wiki.cocoondev.org/Wiki.jsp?page=SurvivalTips Please feel free to modify/move it as appropriate. regards, hussayn -- Dr. Hussayn Dabbous SAXESS Software Design GmbH Neuenhöfer Allee 125 50935 Köln Telefon: +49-221-56011-0 Fax: +49-221-56011-20 E-Mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
serializing inside a transformer
Hi, I would like toserializeSAX events to a file inside a transformer, so that I can validate the file with the parser. The problem is that I don't how to set theserializer in order to make it able to receive the SAX events which the transformer is receiving from the previous component (a generator or another transformer). Here is a code snippet that shows what I'm trying to do: public class MyValidationTransformer extends AbstractSAXTransformer { XMLSerializer serializer = (XMLSerializer) this.manager.lookup(XMLSerializer.ROLE); FileOutputStream fos=new FileOutputStream(/tmp/tmp.xml); serializer.setOutputStream(fos); /*??? HOW TO SEND THE SAX EVENTS THE TRANSFORMER IS RECEIVING TO THE SERIALIZER *???/ FileInputStream fis=new FileInputStream(/tmp/tmp.xml); InputSource is=new InputSource(fis); Parser parser = (Parser)this.manager.lookup(Parser.ROLE); boolean validation = parameters.getParameterAsBoolean("validation", false); parser.myParse(this.inputSource, super.xmlConsumer, validation); } Oskar
Automatically generated linefeed before ?xml ...? in the JSP causes SAXException
Hello, I have found that my JSP generator always prints a LineFeed automatically before ?xml.? causing the SAXException. I have examined the generated source and yes, there is a generated "out.write("\r\n");" just before my code. How can I resolve this? Thanks. Eduardo.
Re: serializing inside a transformer
On Mon, Jan 20, 2003 at 01:00:41PM +0100, Oskar Casquero wrote: Hi, I would like to serialize SAX events to a file inside a transformer, so that I can validate the file with the parser. The problem is that I don't how to set the serializer in order to make it able to receive the SAX events which the transformer is receiving from the previous component (a generator or another transformer). How about inheriting from DOMTransformer, and then (if possible) validate the DOM directly, or use o.a.c.xml.XMLUtils#serializeNode() to get a String which you can validate? It's a nasty hack though. Best way would be to write a ValidatorTransformer that validates SAX events as they go past: http://iso-relax.sourceforge.net/JARV/JARV.html#use_42 --Jeff ... Oskar - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: xinclude performance issues,
On Thu, Jan 16, 2003 at 03:11:37PM -0800, icewind wrote: Let me describe what I am doing: I have a directory that contains .xml files. In my sitemap, I have a pipeline that starts with a DirectoryGenerator on this directory. I then have a transformation that takes the directorygenerator's output and puts some xi:include tags with xpointers to some tags in the xml files I am interested in. I then run the xinclude transformation and serialize to html. You could try the XPathDirectoryGenerator in Cocoon CVS. It lets you specify nodes in each file to include in the directory listing. For instance, to generate a page listing Ant scripts and their descriptions: http://aft.sourceforge.net/examples/index.html I used: map:generate type=xpathdirectory src=content/xdocs/examples#/project/description/ --Jeff - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Handling Internal Cocoon Exceptions
Is there a way to catch the internal cocoon errors e.g. Resource not found and handle them ?? I would like to produce a more elegant method of reporting back to the user by being able to customise the xsl to provide a more project specfic report and user friendly page. I searched around the 'documentation' and Wiki etc and can handle other pipeline errors with the map:handle-errors directive but this does not appear to work for internal cocoon errors such as that mentioned above. Thanks in advance, Paul Any e-mail message from the European Central Bank (ECB) is sent in good faith but shall neither be binding nor construed as constituting a commitment by the ECB except where provided for in a written agreement. This e-mail is intended only for the use of the recipient(s) named above. Any unauthorised disclosure, use or dissemination, either in whole or in part, is prohibited. If you have received this e-mail in error, please notify the sender immediately via e-mail and delete this e-mail from your system. - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
No more DTM IDs are available
Hi there Sometimes when I modify my huge sitemap - 54Kb (especially when I add some parameters for actions or XSLT transformer) I got a strange message which tells me nothing. Maybe someone of you can give me some hints what could be wrong and how to correct sucha problem. Regards SG. java.lang.RuntimeException: Errors in XSLT transformation: Warning: File jar:file:/C:/Javasoft/Tomcat 4.1/webapps/insert/WEB- INF/lib/cocoon - 2.0.4.jar!/org/apache/cocoon/components/language/markup/sitemap/java/sitemap.xs l; Line 1822; Column 33; The use of redirect-to resource=dynamic-page/ is deprecated. Please use call resource=dynamic-page/ instead. Warning: File jar:file:/C:/Javasoft/Tomcat 4.1/webapps/insert/WEB- INF/lib/cocoon - 2.0.4.jar!/org/apache/cocoon/components/language/markup/sitemap/java/sitemap.xs l; Line 1822; Column 33; The use of redirect-to resource=dynamic-page/ is deprecated. Please use call resource=dynamic-page/ instead. Fatal: org.apache.xml.dtm.DTMException: No more DTM IDs are available at org.apache.xalan.transformer.TransformerImpl.run(TransformerImpl.java :3170) at java.lang.Thread.run(Thread.java:536) -- Keep on rolling mailto: [EMAIL PROTECTED] http://create.e-informatyka.pl - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: No more DTM IDs are available
Hi there Got this one some time ago - I guess some gurus might have a better answer than me, but here goes: You probably have an old Xalan in your JDK shadowing the Xalan in Cocoon. This is due to Java 2 Class Loading. Solution is to add xalan and xerces to the endorsed lib of your JDK (I am assuming some type of JDK 1.4 here). See how on: http://xml.apache.org/cocoon/installing under the subtitle Java 1.4 Configuration. Servlet 2.3 Class Loading is another feature that will help you - but let's leave that for a while since this probably requires editing the servlet container configuration. We tried different versions of System.out.println (org.apache.xalan.processor.XSLProcessorVersion.S_VERSION) in an xsp page to see what version cocoon really ended up using :-) But No more DTM ID's we got rid of by putting the proper xalan and xerces in the endorsed libs ... Jakob Dalsgaard Udvikler e-mail: [EMAIL PROTECTED] Vesterbrogade 149 1620 København V Tlf.: 70 25 80 30 Fax.: 70 25 80 31 Sebastian Gil [EMAIL PROTECTED] 01/20/03 01:53 PM Please respond to cocoon-users To: [EMAIL PROTECTED] cc: Subject:No more DTM IDs are available Hi there Sometimes when I modify my huge sitemap - 54Kb (especially when I add some parameters for actions or XSLT transformer) I got a strange message which tells me nothing. Maybe someone of you can give me some hints what could be wrong and how to correct sucha problem. Regards SG. java.lang.RuntimeException: Errors in XSLT transformation: Warning: File jar:file:/C:/Javasoft/Tomcat 4.1/webapps/insert/WEB- INF/lib/cocoon - 2.0.4.jar!/org/apache/cocoon/components/language/markup/sitemap/java/sitemap.xs l; Line 1822; Column 33; The use of redirect-to resource=dynamic-page/ is deprecated. Please use call resource=dynamic-page/ instead. Warning: File jar:file:/C:/Javasoft/Tomcat 4.1/webapps/insert/WEB- INF/lib/cocoon - 2.0.4.jar!/org/apache/cocoon/components/language/markup/sitemap/java/sitemap.xs l; Line 1822; Column 33; The use of redirect-to resource=dynamic-page/ is deprecated. Please use call resource=dynamic-page/ instead. Fatal: org.apache.xml.dtm.DTMException: No more DTM IDs are available at org.apache.xalan.transformer.TransformerImpl.run(TransformerImpl.java :3170) at java.lang.Thread.run(Thread.java:536) -- Keep on rolling mailto: [EMAIL PROTECTED] http://create.e-informatyka.pl - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Automatically generated linefeed before ?xml ...? in the JSP causes SAXException
If the JSP samples work then this is probably a problem somewhere in your XML. How does your sitemap look like (the relevant part)? Konstantin - Original Message - From: Eduardo Zurita To: [EMAIL PROTECTED] Sent: Monday, January 20, 2003 16:05 Subject: Automatically generated linefeed before ?xml ...? in the JSP causes SAXException Hello, I have found that my JSP generator always prints a LineFeed automatically before ?xml.? causing the SAXException. I have examined the generated source and yes, there is a generated out.write(\r\n); just before my code. How can I resolve this? Thanks. Eduardo. - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: XSP : control structures
There is nothing like that in XSP. I'm sure most people here will tell you to use transformers, actions, or better yet flow from 2.1. Since I had XSPs left over from 1.x version and I like having data access, logic and error handling in the same place (the XSP) I developed my own logicsheet to that has several control structures. There quite specific (in error handling) to our product so it would take some work to make them generic. Also don't know if the dev people would accept it since: XSP should at most be used to transfer data from request attributes into to the SAX stream. Also you should be able to use the xslt control structues in your XSP (with its xsl: namespace and declaration in xsp:page) but I haven't tried this. Artur... -Original Message- From: Pierrick Brihaye [mailto:[EMAIL PROTECTED]] Sent: January 18, 2003 4:31 AM To: [EMAIL PROTECTED] Subject: XSP : control structures Hi, Are there control structures in XSP ? Here is what I mean (taken from http://xml.apache.org/cocoon/userdocs/xsp/logicsheet.html) : xsp:page xmlns:xsp=http://apache.org/xsp; !-- replacement for : xsp:logic String msg = Hello, world!; /xsp:logic -- xsp:variable name=msgHello, world!/xsp:variable !-- actually *not* a control structure :-) -- !-- replacement for : xsp:logic if (msg != null) { /xsp:logic -- xsp:if select=$msg greeting xsp:exprxsp:value-of select=$msg //xsp:expr /greeting !-- replacement for : xsp:logic } /xsp:logic -- /xsp:if /xsp:page Got it ? The like for xsp:choose / xsp:when, xsp:for-each... Such things would be useful, wouldn't hey ? Cheers, p.b. - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [XMLForm] initialization of the model
Try the overriding reset() - Original Message - From: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, January 20, 2003 2:53 AM Subject: [XMLForm] initialization of the model Hi all, I'm trying to initialize the model of a XMLForm app each time I call this app. This app is launching from the Cocoon portal, in an authenticated environment. I have followed the solution coming from the posts in this list (thank you for that). The solution was to override the getFormModel() method in the Action class to initialize the model inside. I've done this but I still have a problem: the initialization is proceeded only the first time I call the app (the action) and not each time. What should I do for doing this? Is there maybe a session problem? Any help would be greatly appreciated. Thank you Sylvain - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: No more DTM IDs are available
You probably have an old Xalan in your JDK shadowing the Xalan in Cocoon. This is due to Java 2 Class Loading. Solution is to add xalan and xerces to the endorsed lib of your JDK (I am assuming some type of JDK 1.4 here). But note that if you use Tomcat, it overrides the jdk endorsed directory and you should use $TOMCAT_HOME/common/endorsed instead. And you realize that the first part of the error message is warning you that you are using deprecated items by using redirect-to instead of call? IIUC, redirect-to now only deals with sending client-side redirects and call is used for resource reuse within cocoon. Geoff Howard - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: [XMLForm] initialization of the model
Hi Ivelin, I have tried to put these lines in the prepare() method and it works: code Form.remove(getObjectModel(), getFormId()); getForm().addFormListener(this); code But to understand this thing could you tell me: - the getFormModel() method is called the first time you call the app, right? - is the getFormModel() method called before or after the prepare() method? - the prepare() method is called each time you call the app, right? Thank you Regards Sylvain -Message d'origine- De: Ivelin Ivanov [mailto:[EMAIL PROTECTED]] Date: lundi, 20. janvier 2003 15:18 À: [EMAIL PROTECTED] Objet: Re: [XMLForm] initialization of the model Try the overriding reset() - Original Message - From: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, January 20, 2003 2:53 AM Subject: [XMLForm] initialization of the model Hi all, I'm trying to initialize the model of a XMLForm app each time I call this app. This app is launching from the Cocoon portal, in an authenticated environment. I have followed the solution coming from the posts in this list (thank you for that). The solution was to override the getFormModel() method in the Action class to initialize the model inside. I've done this but I still have a problem: the initialization is proceeded only the first time I call the app (the action) and not each time. What should I do for doing this? Is there maybe a session problem? Any help would be greatly appreciated. Thank you Sylvain - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Newbie questions about Actions
Hello, I've read through userdocs/concepts/actions.html, but still I dont't get the following (and the docs do not explain this): I've got Java code of an action. HOW do I compile this and WHERE should I put the resulting .class file after this. -- Lenya Khachaturov mailto:[EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
AW: Newbie questions about Actions
hi lenya, you compile the java Action code like any other java code, i.e. via javac, IDE, etc. if you package the resulting classes as JAR this has to be in WEB-INF/lib of your cocoon. otherwise the classes go to WEB-INF/classes of you cocoon. note that the package structure has to be reflected in the directory hierarchy, i.e. if your class 'bar' is in package 'foo', the class would have to be in WEB-INF/classes/foo/bar.class. -Ursprungliche Nachricht- Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]Im Auftrag von Lenya L. Khachaturov Gesendet: Montag, 20. Januar 2003 17:34 An: [EMAIL PROTECTED] Betreff: Newbie questions about Actions Hello, I've read through userdocs/concepts/actions.html, but still I dont't get the following (and the docs do not explain this): I've got Java code of an action. HOW do I compile this and WHERE should I put the resulting .class file after this. -- Lenya Khachaturov mailto:[EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Documentation - Forrest Base/Wiki - Plead
Thanks to those people who had made a valiant effort to make the Documentation more understandable. My plead to you authors is to make these document fit into one viewable page including the left side navigation menu. I do find it very distracting to scroll horizontally right to left back and forth as I easily lost track which line I was on. I am hoping this suggestion is not overly difficult to accomplish. Less motion translate to lesser stress on the arm and avoid that repetitive stress syndrome (carpal tunnel?). What do you think? Thank you, enio __ Do you Yahoo!? Yahoo! Mail Plus - Powerful. Affordable. Sign up now. http://mailplus.yahoo.com - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: 10 basic survival tips for cocoon users (was: Logicsheet problems - global XSLT variables)
SAXESS - Hussayn Dabbous dijo: Mark Horgan wrote: Also, do others find working with Cocoon very frustrating? When you make a change it takes forever for the web-app to reload and re-compile the java class, espcially when it takes up so much memory. Also even when using the logs its very hard to track down bugs in ones code especially logicsheets. But generally I like Cocoon though I wish it was more straight-forward to develop with it. Thx in advance, Mark Hy, When i started with cocoon i got really mad with hunting errors and understanding, how all this fits together. But after about three months of working with the beast, i built up some survival strategies. It is how I do it. It may help as a guide, but it does not claim to be the best approach: 1.) Instead of restarting the whole container, i only restart the cocoon app, when needed. This takes a few seconds with tomcat 4.1.* (~300 MHz sparc dual processor, solaris 2.8) 2.) During development i use tomcat and i set the reloadable=true within the Context/ of my webapp. By this any changes in the classpath causes an automatic webapp restart. 3.) use released versions if possible (cocoon-2.0.4 seems quite mature) 4.) Proceed in baby steps when changing things in your cocoon app 5.) follow KISS (keep it simple, stupid) i keep as much as possible with the basics of cocoon and don't use (yet) the more fancy stuff. 6.) Separate your app into subsitemaps and subdirs with related issues 7.) use the cocoon-wiki Especially the search function unhides interesting docs 8.) I started using the coocon developers handbook It's written from Lajos Moczar and some other active cocoon developers... Here are two of my personal favorites. I have documented this in our company wiki: 9.) For XSLT processing i have added Saxon-6.5.2. It's not straight forward to install, but sometimes it can be utilised with less pain, than xalan (just a matter of taste) Look into cocoon wiki for a quick description or look at http://www.saxess.com/JSPWiki/Wiki.jsp?page=Install for a quickinstall step by step instruction. 9.01) I use jEdit.org to all my development in Cocoon. jEdit has a plugins called XML and XSLT. The XML plugin helps writing XML stuff checking the tags. The XSLT pluging helps to see the results of applying 1 or more Stylesheets to a page. This is useful to check what are the stylesheets doing. comment I think it will be fine to write a survival guide in wiki. :-) /comment Antonio Gallardo 10.)use entity resolver wherever possible. look at the cocoon docs for the basics or at http://www.saxess.com/JSPWiki/Wiki.jsp?page=EntityResolver for a quickinstall description. hope, that helps someone ... regards, hussayn -- Dr. Hussayn Dabbous SAXESS Software Design GmbH Neuenhöfer Allee 125 50935 Köln Telefon: +49-221-56011-0 Fax: +49-221-56011-20 E-Mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: XSP : control structures
XSP should at most be used to transfer data from request attributes into to the SAX stream. Artur... Good point! I do the same too. Antonio Gallardo. - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: serializing inside a transformer
hi: I am not a pro in Cocoon. How do this the log transformer? check the sources of org.apache.cocoon.transformation.LogTransformer And maybe there you can found your answer. Antonio Gallardo. Oskar Casquero dijo: Hi, I would like to serialize SAX events to a file inside a transformer, so that I can validate the file with the parser. The problem is that I don't how to set the serializer in order to make it able to receive the SAX events which the transformer is receiving from the previous component (a generator or another transformer). Here is a code snippet that shows what I'm trying to do: public class MyValidationTransformer extends AbstractSAXTransformer { XMLSerializer serializer = (XMLSerializer) this.manager.lookup(XMLSerializer.ROLE); FileOutputStream fos = new FileOutputStream(/tmp/tmp.xml); serializer.setOutputStream(fos); /*??? HOW TO SEND THE SAX EVENTS THE TRANSFORMER IS RECEIVING TO THE SERIALIZER *???/ FileInputStream fis = new FileInputStream(/tmp/tmp.xml); InputSource is = new InputSource(fis); Parser parser = (Parser)this.manager.lookup(Parser.ROLE); boolean validation = parameters.getParameterAsBoolean(validation, false); parser.myParse(this.inputSource, super.xmlConsumer, validation); } Oskar - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Documentation - Forrest Base/Wiki - Plead
e nio wrote: Thanks to those people who had made a valiant effort to make the Documentation more understandable. My plead to you authors is to make these document fit into one viewable page including the left side navigation menu. I do find it very distracting to scroll horizontally right to left back and forth as I easily lost track which line I was on. I am hoping this suggestion is not overly difficult to accomplish. Less motion translate to lesser stress on the arm and avoid that repetitive stress syndrome (carpal tunnel?). What do you think? enio, if you are talking about the Wiki docs, please don't forget you can just hit 'edit page' and correct these accessibility issues yourself! cheers, /Steven -- Steven Noelshttp://outerthought.org/ Outerthought - Open Source, Java XML Competence Support Center Read my weblog athttp://blogs.cocoondev.org/stevenn/ stevenn at outerthought.orgstevenn at apache.org - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: serializing inside a transformer
I agree with you. I thought that using a serializer would be useful to get an input source for the parser. But now I see that it would be much better to use JARV to develop the transformer based only in SAX events (use 4_2 of JARV), as you suggested. I have another question, which is the same I did before: how do I set the VerifierHandler of JARV in order to send to it the SAX events the transformer is receiving from the previous component? With super.setContentHandler(verifierHandler), perhaps? public class ValidationTransformer extends AbstractSAXTransformer { ... super.setContentHandler(verifierHandler); ... } Thank you Oskar - Original Message - From: Jeff Turner [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, January 20, 2003 1:22 PM Subject: Re: serializing inside a transformer On Mon, Jan 20, 2003 at 01:00:41PM +0100, Oskar Casquero wrote: Hi, I would like to serialize SAX events to a file inside a transformer, so that I can validate the file with the parser. The problem is that I don't how to set the serializer in order to make it able to receive the SAX events which the transformer is receiving from the previous component (a generator or another transformer). How about inheriting from DOMTransformer, and then (if possible) validate the DOM directly, or use o.a.c.xml.XMLUtils#serializeNode() to get a String which you can validate? It's a nasty hack though. Best way would be to write a ValidatorTransformer that validates SAX events as they go past: http://iso-relax.sourceforge.net/JARV/JARV.html#use_42 --Jeff ... Oskar - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Not loading the HSQLDB?
Sorry you never got an answer here - I don't have much to add but the following: 1) I don't think HSQLDB is necessary for proper internal working of cocoon. 2) I'm pretty sure I managed to disable it by modifying cocoon.xconf (and maybe something else). Unfortunately, I don't have time to track down what I did. If you provide more information on what's happening when cocoon does not work properly that may help me/others figure out what's happening. For instance, if you've removed the jar from WEB-INF/lib but failed to remove the reference to the hsqldb class in web.xml you may have problems right there. HTH, Geoff Howard -Original Message- From: Mark Horgan [mailto:[EMAIL PROTECTED]] Sent: Wednesday, January 15, 2003 10:13 AM To: [EMAIL PROTECTED] Subject: Not loading the HSQLDB? Hi there, I'm trying to not load the HSQLDB on startup to save memory. I've tried commenting the hsqldb-server tag in cocoon.xconf but it still loads and causes cocoon not to work properly. Is HSQLDB required for proper/internal working of cocoon and if not how does one not load it? Mark - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Not loading the HSQLDB?
On Mon, 20 Jan 2003, Geoff Howard wrote: Sorry you never got an answer here - I don't have much to add but the following: 1) I don't think HSQLDB is necessary for proper internal working of cocoon. 2) I'm pretty sure I managed to disable it by modifying cocoon.xconf (and maybe something else). Unfortunately, I don't have time to track down what I did. If you provide more information on what's happening when cocoon does not work properly that may help me/others figure out what's happening. For instance, if you've removed the jar from WEB-INF/lib but failed to remove the reference to the hsqldb class in web.xml you may have problems right there. HTH, Geoff Howard -Original Message- From: Mark Horgan [mailto:[EMAIL PROTECTED]] Sent: Wednesday, January 15, 2003 10:13 AM To: [EMAIL PROTECTED] Subject: Not loading the HSQLDB? Hi there, I'm trying to not load the HSQLDB on startup to save memory. I've tried commenting the hsqldb-server tag in cocoon.xconf but it still loads and causes cocoon not to work properly. Is HSQLDB required for proper/internal working of cocoon and if not how does one not load it? Do you also removed the entry in web.xml? Stephan. - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Not loading the HSQLDB?
Stephan Michels dijo: On Mon, 20 Jan 2003, Geoff Howard wrote: Sorry you never got an answer here - I don't have much to add but the following: 1) I don't think HSQLDB is necessary for proper internal working of cocoon. 2) I'm pretty sure I managed to disable it by modifying cocoon.xconf (and maybe something else). Unfortunately, I don't have time to track down what I did. If you provide more information on what's happening when cocoon does not work properly that may help me/others figure out what's happening. For instance, if you've removed the jar from WEB-INF/lib but failed to remove the reference to the hsqldb class in web.xml you may have problems right there. HTH, Geoff Howard -Original Message- From: Mark Horgan [mailto:[EMAIL PROTECTED]] Sent: Wednesday, January 15, 2003 10:13 AM To: [EMAIL PROTECTED] Subject: Not loading the HSQLDB? Hi there, I'm trying to not load the HSQLDB on startup to save memory. I've tried commenting the hsqldb-server tag in cocoon.xconf but it still loads and causes cocoon not to work properly. Is HSQLDB required for proper/internal working of cocoon and if not how does one not load it? Do you also removed the entry in web.xml? Stephan. And after that you can remove the .jar from the WEB-LIB. Antonio Gallardo - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: 10 basic survival tips for cocoon users (was: Logicsheet problems- global XSLT variables)
hy Antonio; What about adding your contrib directly to http://wiki.cocoondev.org/Wiki.jsp?page=SurvivalTips or related pages ;-) ? Maybe you could contrib a link to jEdit.org ? Maybe it is even worthwhile to add a new wikipage for XML-authoring tools ... What do you mean ? regards, hussayn 9.01) I use jEdit.org to all my development in Cocoon. jEdit has a plugins called XML and XSLT. The XML plugin helps writing XML stuff checking the tags. The XSLT pluging helps to see the results of applying 1 or more Stylesheets to a page. This is useful to check what are the stylesheets doing. comment I think it will be fine to write a survival guide in wiki. :-) /comment Antonio Gallardo -- Dr. Hussayn Dabbous SAXESS Software Design GmbH Neuenhöfer Allee 125 50935 Köln Telefon: +49-221-56011-0 Fax: +49-221-56011-20 E-Mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: 10 basic survival tips for cocoon users (was: Logicsheet problems - global XSLT variables)
Its. OK. Start an XML-authoring tools. Antonio Gallardo SAXESS - Hussayn Dabbous dijo: hy Antonio; What about adding your contrib directly to http://wiki.cocoondev.org/Wiki.jsp?page=SurvivalTips or related pages ;-) ? Maybe you could contrib a link to jEdit.org ? Maybe it is even worthwhile to add a new wikipage for XML-authoring tools ... What do you mean ? regards, hussayn 9.01) I use jEdit.org to all my development in Cocoon. jEdit has a plugins called XML and XSLT. The XML plugin helps writing XML stuff checking the tags. The XSLT pluging helps to see the results of applying 1 or more Stylesheets to a page. This is useful to check what are the stylesheets doing. comment I think it will be fine to write a survival guide in wiki. :-) /comment Antonio Gallardo -- Dr. Hussayn Dabbous SAXESS Software Design GmbH Neuenhöfer Allee 125 50935 Köln Telefon: +49-221-56011-0 Fax: +49-221-56011-20 E-Mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Running instrumentation-client....
Hi. Can someone help me to make run again the instrumentation client? I had it running before the lastest CVS updates (end of dic-2002). I downloaded the new excalibur CVS, because the once that is in Cocoon CVS run for me, but does not connect to the servlet. Also it does not write nothing on the output console. Just said: [Not Connected] I have configured the web.xml: init-param param-nameenable-instrumentation/param-name param-valuetrue/param-value /init-param init-param param-nameinstrumentation-config/param-name param-value/WEB-INF/instrumentation.xconf/param-value /init-param And of course the default instrumentation.xconf file is placed it this place. What can be my fault? I am using: Red Hat Linux 8.0 (full patched). Tomcat 4.1.18 Java 1.4.1_01 Cocoon 2.1 CVS (lastest). Thanks in advance, Antonio Gallardo. - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Running instrumentation-client....
Hi Antonio, On Mon, Jan 20, 2003 at 02:19:22PM -0600, Antonio Gallardo wrote: Hi. Can someone help me to make run again the instrumentation client? Yes, I'll help you get it running. :) I had it running before the lastest CVS updates (end of dic-2002). I downloaded the new excalibur CVS, because the once that is in Cocoon CVS run for me, but does not connect to the servlet. Your configuration looks ok, but according to the avalon-dev archives, you'll need to run the instrumentation client from the Cocoon CVS in tools/instrumentation when connecting to the Cocoon webapp. The issue lies in the altrmi jars. According to the archives the -common.jar needs to be the same on both the server and client, which is the change I made recently (and an update to the latest code). Does the instrumentation client work correctly when you run the runclient.sh script from tools/instrumentation/bin in Cocoon CVS ? Cheers, Marcus -- . ,,$, Marcus Crafter ;$' ':Computer Systems Engineer $: : ManageSoft GmbH $ o_)$$$: 82-84 Mainzer Landstrasse ;$,_/\ :' 60327 Frankfurt Germany ' /( \_' . : - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
sunRise logout - context cleaning
Hi, I try to use the sunRise logout action and the logout action itself works fine redirecting me to some page i stated to redirect to. But as I see it doesn't clear the context, the user is still logged in (after calling a protected resource I get access to it instantly) .. I think that I should call some context clearing action, perhaps some xsp or sth ? any ideas what to do about it? the action is defined in the main project dir as : map:action name=sunRise-auth src=org.apache.cocoon.sunshine.sunrise.acting.AuthAction handlers handler name=Einformatyka xmlns:map=http://apache.org/cocoon/sitemap/1.0; xmlns:sunshine=http://sunshine.sundn.de/sunshine/1.0; redirect-to uri=account/login/ authentication uri=cocoon://account/login-check/ /handler /handlers /map:action map:action name=sunRise-login src=org.apache.cocoon.sunshine.sunrise.acting.LoginAction/ map:action name=sunRise-logout src=org.apache.cocoon.sunshine.sunrise.acting.LogoutAction/ map:action name=sunRise-loggedIn src=org.apache.cocoon.sunshine.sunrise.acting.LoggedInAction/ and the resource itself is defined in the account subdir sitemap as map:match pattern=logout map:act type=sunRise-logout map:parameter name=handler value=Einformatyka/ /map:act map:redirect-to uri=login/ /map:match so loggin in, error-handling works fine, only this last thing .. it redirects to login but doesn't logout the user, doesn't clear the context any ideas ? -- Bye, ilfrin mailto:[EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Parsing multipart form data
Hi, I'm trying to figure out the best way to parse multi-part form data. I have a page which submits to a certain URI which invokes an action. This action needs to parse the multi-part form data (in the request object I believe) and then pass that data off to my j2ee backend for processing. My problem is that I do not see a way for me to create this MultipartParser or what not. The Cocoon request object does not as I understand it, provide a way for me to get the necessary data to create this parser (i.e. I need a HttpServletRequest), and since my editor does not implement the servlet interface, it does not receive the Request object from the servlet container as a parameter (i.e. doAction, etc). I feel like I am possibly barking up the wrong tree here. Is the action the appropriate place to do this? Should I instead implement a matcher to find this request object? thanks, Collin Collin VanDyckAOL: djtclYahoo: webcollin
RE: Parsing multipart form data
Have you seen this document yet? http://wiki.cocoondev.org/Wiki.jsp?page=FileUploadsWithCocoon. I'm sorry if it's not written very clearly - I wrote it late at night sort of spontaneously. That gives some basic information on how cocoon handles things behind the scenes. The important part in your case is that you don't need to do the multipart parsing - it's already done for you by the time your action gets on the scene. You can then use the FilePart object to get the contents of the file via an InputStream and do whatever you want with it. If that doesn't help, give more of an idea of what you need to do on the backend. Geoff Howard -Original Message- From: Collin VanDyck [mailto:[EMAIL PROTECTED]] Sent: Monday, January 20, 2003 3:36 PM To: [EMAIL PROTECTED] Subject: Parsing multipart form data Hi, I'm trying to figure out the best way to parse multi-part form data. I have a page which submits to a certain URI which invokes an action. This action needs to parse the multi-part form data (in the request object I believe) and then pass that data off to my j2ee backend for processing. My problem is that I do not see a way for me to create this MultipartParser or what not. The Cocoon request object does not as I understand it, provide a way for me to get the necessary data to create this parser (i.e. I need a HttpServletRequest), and since my editor does not implement the servlet interface, it does not receive the Request object from the servlet container as a parameter (i.e. doAction, etc). I feel like I am possibly barking up the wrong tree here. Is the action the appropriate place to do this? Should I instead implement a matcher to find this request object? thanks, Collin Collin VanDyck AOL: djtcl Yahoo: webcollin - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Running instrumentation-client....
Really I dont know what happened but after reading your mail and starting Tomcat I runned again the CVS version and it works! I dont know why yesterday it does not work. I think Java sometimes retain the jars on memory and this cause some errors. Antonio Gallardo. Marcus Crafter dijo: Hi Antonio, On Mon, Jan 20, 2003 at 02:19:22PM -0600, Antonio Gallardo wrote: Hi. Can someone help me to make run again the instrumentation client? Yes, I'll help you get it running. :) I had it running before the lastest CVS updates (end of dic-2002). I downloaded the new excalibur CVS, because the once that is in Cocoon CVS run for me, but does not connect to the servlet. Your configuration looks ok, but according to the avalon-dev archives, you'll need to run the instrumentation client from the Cocoon CVS in tools/instrumentation when connecting to the Cocoon webapp. The issue lies in the altrmi jars. According to the archives the -common.jar needs to be the same on both the server and client, which is the change I made recently (and an update to the latest code). Does the instrumentation client work correctly when you run the runclient.sh script from tools/instrumentation/bin in Cocoon CVS ? Cheers, Marcus -- . ,,$, Marcus Crafter ;$' ':Computer Systems Engineer $: : ManageSoft GmbH $ o_)$$$: 82-84 Mainzer Landstrasse ;$,_/\ :' 60327 Frankfurt Germany ' /( \_' . : - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
newbie: creating a cocoon action using AbstractMultiAction
Hi all, I am currently trying to create my own action for cocoon 2. Moreover, I am trying to use the AbstractMultiAction class so I can call methods on the action via a http post form field. Unfortunately I have been able to compile it, but get a Class Not Found Exception when I try access the URL that points to the sitemap with the mounted action. I am not trying to use the action, I just have the action mounted. Below is my java action code and I have attached my stack trace/sitemap as one text file. Any help would be appreciated. I am using red hat 8.0, j2sdk 1.4, and a cocoon 2.x build from about a month ago. Thanks in Advance *ACTION JAVA CODE** /* * TaskAction.java * * Created on January 14, 2003, 12:16 PM */ package org.apache.cocoon.acting; /** * * @author Julian */ import org.apache.avalon.framework.context.Context; import org.apache.avalon.framework.context.ContextException; import org.apache.avalon.framework.context.Contextualizable; import org.apache.avalon.framework.parameters.ParameterException; import org.apache.avalon.framework.parameters.Parameters; import org.apache.avalon.framework.thread.ThreadSafe; import org.apache.cocoon.Constants; import org.apache.cocoon.ProcessingException; import org.apache.cocoon.acting.AbstractMultiAction; import org.apache.cocoon.environment.ObjectModelHelper; import org.apache.cocoon.environment.Redirector; import org.apache.cocoon.environment.Request; import org.apache.cocoon.environment.SourceResolver; import java.util.Map; import com.ethidium.wEMR.classes.Task; import com.ethidium.wEMR.classes.TaskManager; import com.ethidium.wEMR.classes.TaskGroup; public class TaskAction extends AbstractMultiAction implements ThreadSafe { public static final String TASK_ACTION = task-action; public static final String SUBJECT_NODE = task-subject-node; public static final String CATEGORY = task-category; public static final String DEST_CATEGORY = task-dest-category; public static final String DEST_SUBJECT_NODE = task-dest-subject-node; public static final String TASK_TITLE = task-title; public static final String TASK_DESCRIPTION = task-description; public static final String TASK_DUE_DATE = task-due-date; public static final String TASK_PRIORITY = task-priority; public static final String TASK_STATUS = task-status; public static final String TASK_URI = task-uri; public static final String TASK_OWNER = task-owner; /*public Map act (Redirector redirector, SourceResolver resolver, Map objectModel, String source, Parameters params) { Map sitemapParams = new HashMap(); sitemapParams.put(world, hello); Request request = ObjectModelHelper.getRequest(objectModel); action = request.getAttribute(action); return sitemapParams; }*/ public Map doCreateTask(Redirector redirector, SourceResolver resolver, Map objectModel, String src, Parameters parameters) throws Exception { Request request = ObjectModelHelper.getRequest(objectModel); //determine dest of task to be created String subjectNode = parameters.getParameter(SUBJECT_NODE, request.getParameter(SUBJECT_NODE)); String category = parameters.getParameter(CATEGORY, request.getParameter(CATEGORY)); //get task values String taskTitle = parameters.getParameter(TASK_TITLE, request.getParameter(TASK_TITLE)); String taskDescription = parameters.getParameter(TASK_DESCRIPTION, request.getParameter(TASK_DESCRIPTION)); String taskDueDate = parameters.getParameter(TASK_DUE_DATE, request.getParameter(TASK_DUE_DATE)); String taskPriority = parameters.getParameter(TASK_PRIORITY, request.getParameter(TASK_PRIORITY)); String taskStatus = parameters.getParameter(TASK_STATUS, request.getParameter(TASK_STATUS)); String taskURI = parameters.getParameter(TASK_URI, request.getParameter(TASK_URI)); String taskOwner = parameters.getParameter(TASK_OWNER, request.getParameter(TASK_OWNER)); getLogger().info(create task +taskTitle+ at +subjectNode+/+category); TaskManager taskManager = new TaskManager(); Task task = new Task(taskOwner, taskTitle, taskDescription, taskURI, taskDueDate, taskPriority, taskStatus); taskManager.storeTask(subjectNode, category, task); return EMPTY_MAP; } } __ Do you Yahoo!? Yahoo! Mail Plus - Powerful. Affordable. Sign up now. http://mailplus.yahoo.com
Re: Running instrumentation-client....
On Mon, Jan 20, 2003 at 03:04:43PM -0600, Antonio Gallardo wrote: Really I dont know what happened but after reading your mail and starting Tomcat I runned again the CVS version and it works! Great :) I dont know why yesterday it does not work. I think Java sometimes retain the jars on memory and this cause some errors. hmm.. strange. I have had problems in the past, but as in my previous post, after finding out about the altrmi common jar it's been working ok for me ever since. Glad that it's now working fine for you. Cheers, Marcus -- . ,,$, Marcus Crafter ;$' ':Computer Systems Engineer $: : ManageSoft GmbH $ o_)$$$: 82-84 Mainzer Landstrasse ;$,_/\ :' 60327 Frankfurt Germany ' /( \_' . : - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: newbie: creating a cocoon action using AbstractMultiAction
Hi Julian, Not sure what the problem is exactly, but your source file has your action in the package 'org.apache.cocoon.acting', whereas your sitemap.xmap file says that is under 'com.ethidium.cocoon.action'. Perhaps that's causing things to go a bit pear shaped. Hope that helps. Cheers, Marcus On Mon, Jan 20, 2003 at 01:06:09PM -0800, Julian Klein wrote: *ACTION JAVA CODE** /* * TaskAction.java * * Created on January 14, 2003, 12:16 PM */ package org.apache.cocoon.acting; ...snip/... ***SITEMAP ...snip/... map:actions map:action name=eTask src=com.ethidium.cocoon.action.TaskAction/ -- . ,,$, Marcus Crafter ;$' ':Computer Systems Engineer $: : ManageSoft GmbH $ o_)$$$: 82-84 Mainzer Landstrasse ;$,_/\ :' 60327 Frankfurt Germany ' /( \_' . : - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: newbie: creating a cocoon action using AbstractMultiAction
Hey Marcus, Yeah I'm sorry, but I had fixed that (I jsut sent the old sitemap DUH). You see I tried it in the original package of com.ethidium, but then thought my class should be in the cocoon dev jar so I moved it to org.apache.cocoon.acting and changed the sitemap. Unfortunately neither worked eventhough the sitemap matched the location of the class. I know it is accessing the class since it is looking for the AbstractMultiAction class (it's superclass). I am running also the slide sample from the scratchpad which has actions that use the AbstractMultiAction class as well...but they works fine. I am boggled about this...could it have something to do with Thread safety from the Avalon framework or some funny classloading issue? Thanks Again, Julian --- Marcus Crafter [EMAIL PROTECTED] wrote: Hi Julian, Not sure what the problem is exactly, but your source file has your action in the package 'org.apache.cocoon.acting', whereas your sitemap.xmap file says that is under 'com.ethidium.cocoon.action'. Perhaps that's causing things to go a bit pear shaped. Hope that helps. Cheers, Marcus On Mon, Jan 20, 2003 at 01:06:09PM -0800, Julian Klein wrote: *ACTION JAVA CODE** /* * TaskAction.java * * Created on January 14, 2003, 12:16 PM */ package org.apache.cocoon.acting; ...snip/... ***SITEMAP ...snip/... map:actions map:action name=eTask src=com.ethidium.cocoon.action.TaskAction/ -- . ,,$, Marcus Crafter ;$' ':Computer Systems Engineer $: : ManageSoft GmbH $ o_)$$$: 82-84 Mainzer Landstrasse ;$,_/\ :' 60327 Frankfurt Germany ' /( \_' . : - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] = Live simply so others may simply live. -Ghandi Pluralitas non est ponenda sine neccesitate. Entities should not be multiplied unneccesarily -William of Occam __ Do you Yahoo!? Yahoo! Mail Plus - Powerful. Affordable. Sign up now. http://mailplus.yahoo.com - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Parsing multipart form data
Thanks Geoff Well, yes, I actually started going thru the mail lists and found your link below. It is helpful, but I cannot get some of the features to work. I DO have the FilePartFile bit working, though I would not like to store such files on the disk. I gave these two init params: init-param param-nameautosave-uploads/param-name param-valuefalse/param-value /init-param init-param param-nameoverwrite-uploads/param-name param-valueallow/param-value /init-param I basically want to keep them in memory, and then use a FilePartArray to save the file contents into the database, but I am having trouble with that. Cocoon does not seem to be recognizing these parameters. Incidentally, I am using 2.0.4, and I built it under java1.4. I put the init-params with the other init-params in web.xml, but strangely did not see any places for it in the web.xml file as it existed. I thouight there would be placeholders for it, but I could not find them. Anyways, I might be missing something. My main problem now is that when I submit a file multiple times, it keeps renaming the file 0_[filename], 1_[filename], etc.. I think my workaround will be to just delete the file once I am done with it, but I would like to keep it in memory if at all possible. Thanks very much for your help! Collin - Original Message - From: Geoff Howard [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, January 20, 2003 4:01 PM Subject: RE: Parsing multipart form data Have you seen this document yet? http://wiki.cocoondev.org/Wiki.jsp?page=FileUploadsWithCocoon. I'm sorry if it's not written very clearly - I wrote it late at night sort of spontaneously. That gives some basic information on how cocoon handles things behind the scenes. The important part in your case is that you don't need to do the multipart parsing - it's already done for you by the time your action gets on the scene. You can then use the FilePart object to get the contents of the file via an InputStream and do whatever you want with it. If that doesn't help, give more of an idea of what you need to do on the backend. Geoff Howard -Original Message- From: Collin VanDyck [mailto:[EMAIL PROTECTED]] Sent: Monday, January 20, 2003 3:36 PM To: [EMAIL PROTECTED] Subject: Parsing multipart form data Hi, I'm trying to figure out the best way to parse multi-part form data. I have a page which submits to a certain URI which invokes an action. This action needs to parse the multi-part form data (in the request object I believe) and then pass that data off to my j2ee backend for processing. My problem is that I do not see a way for me to create this MultipartParser or what not. The Cocoon request object does not as I understand it, provide a way for me to get the necessary data to create this parser (i.e. I need a HttpServletRequest), and since my editor does not implement the servlet interface, it does not receive the Request object from the servlet container as a parameter (i.e. doAction, etc). I feel like I am possibly barking up the wrong tree here. Is the action the appropriate place to do this? Should I instead implement a matcher to find this request object? thanks, Collin Collin VanDyck AOL: djtcl Yahoo: webcollin - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
AW: newbie: creating a cocoon action using AbstractMultiAction
the stacktrace says that the AbstractMultiAction can't be found. make sure that this class is in the classpath (it should be in the cocoon JAR, but you better check that out). -Ursprungliche Nachricht- Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]Im Auftrag von Julian Klein Gesendet: Montag, 20. Januar 2003 22:27 An: [EMAIL PROTECTED] Betreff: Re: newbie: creating a cocoon action using AbstractMultiAction Hey Marcus, Yeah I'm sorry, but I had fixed that (I jsut sent the old sitemap DUH). You see I tried it in the original package of com.ethidium, but then thought my class should be in the cocoon dev jar so I moved it to org.apache.cocoon.acting and changed the sitemap. Unfortunately neither worked eventhough the sitemap matched the location of the class. I know it is accessing the class since it is looking for the AbstractMultiAction class (it's superclass). I am running also the slide sample from the scratchpad which has actions that use the AbstractMultiAction class as well...but they works fine. I am boggled about this...could it have something to do with Thread safety from the Avalon framework or some funny classloading issue? Thanks Again, Julian --- Marcus Crafter [EMAIL PROTECTED] wrote: Hi Julian, Not sure what the problem is exactly, but your source file has your action in the package 'org.apache.cocoon.acting', whereas your sitemap.xmap file says that is under 'com.ethidium.cocoon.action'. Perhaps that's causing things to go a bit pear shaped. Hope that helps. Cheers, Marcus On Mon, Jan 20, 2003 at 01:06:09PM -0800, Julian Klein wrote: *ACTION JAVA CODE** /* * TaskAction.java * * Created on January 14, 2003, 12:16 PM */ package org.apache.cocoon.acting; ...snip/... ***SITEMAP** ** ...snip/... map:actions map:action name=eTask src=com.ethidium.cocoon.action.TaskAction/ -- . ,,$, Marcus Crafter ;$' ':Computer Systems Engineer $: : ManageSoft GmbH $ o_)$$$: 82-84 Mainzer Landstrasse ;$,_/\ :' 60327 Frankfurt Germany ' /( \_' . : - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] = Live simply so others may simply live. -Ghandi Pluralitas non est ponenda sine neccesitate. Entities should not be multiplied unneccesarily -William of Occam __ Do you Yahoo!? Yahoo! Mail Plus - Powerful. Affordable. Sign up now. http://mailplus.yahoo.com - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: AW: newbie: creating a cocoon action using AbstractMultiAction
Thanks, but the class is in the cocoon-2.1-dev.jar under $TOMCAT_HOME/webapps/cocoon/WEB-INF/lib. I tried moving it into $TOMCAT_HOME/common/lib, but after that Cocoon would not even start...so based on that result I did not put it on the machine's CLASSPATH and just let TOMCAT load the classes from the jar. Thanks, Julian --- Marco Rolappe [EMAIL PROTECTED] wrote: the stacktrace says that the AbstractMultiAction can't be found. make sure that this class is in the classpath (it should be in the cocoon JAR, but you better check that out). -Ursprungliche Nachricht- Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]Im Auftrag von Julian Klein Gesendet: Montag, 20. Januar 2003 22:27 An: [EMAIL PROTECTED] Betreff: Re: newbie: creating a cocoon action using AbstractMultiAction Hey Marcus, Yeah I'm sorry, but I had fixed that (I jsut sent the old sitemap DUH). You see I tried it in the original package of com.ethidium, but then thought my class should be in the cocoon dev jar so I moved it to org.apache.cocoon.acting and changed the sitemap. Unfortunately neither worked eventhough the sitemap matched the location of the class. I know it is accessing the class since it is looking for the AbstractMultiAction class (it's superclass). I am running also the slide sample from the scratchpad which has actions that use the AbstractMultiAction class as well...but they works fine. I am boggled about this...could it have something to do with Thread safety from the Avalon framework or some funny classloading issue? Thanks Again, Julian --- Marcus Crafter [EMAIL PROTECTED] wrote: Hi Julian, Not sure what the problem is exactly, but your source file has your action in the package 'org.apache.cocoon.acting', whereas your sitemap.xmap file says that is under 'com.ethidium.cocoon.action'. Perhaps that's causing things to go a bit pear shaped. Hope that helps. Cheers, Marcus On Mon, Jan 20, 2003 at 01:06:09PM -0800, Julian Klein wrote: *ACTION JAVA CODE** /* * TaskAction.java * * Created on January 14, 2003, 12:16 PM */ package org.apache.cocoon.acting; ...snip/... ***SITEMAP** ** ...snip/... map:actions map:action name=eTask src=com.ethidium.cocoon.action.TaskAction/ -- . ,,$, Marcus Crafter ;$' ':Computer Systems Engineer $: : ManageSoft GmbH $ o_)$$$: 82-84 Mainzer Landstrasse ;$,_/\ :' 60327 Frankfurt Germany ' /( \_' . : - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] = Live simply so others may simply live. -Ghandi Pluralitas non est ponenda sine neccesitate. Entities should not be multiplied unneccesarily -William of Occam __ Do you Yahoo!? Yahoo! Mail Plus - Powerful. Affordable. Sign up now. http://mailplus.yahoo.com - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] = Live simply so others may simply live. -Ghandi Pluralitas non est ponenda sine neccesitate. Entities should not be multiplied unneccesarily -William of Occam __ Do you Yahoo!? Yahoo! Mail Plus - Powerful. Affordable. Sign up now. http://mailplus.yahoo.com - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Parsing multipart form data
Here is my web.xml file. (It's long, so an apology in advance). I hope this helps, and I really do appreciate everyone's help in this list. I commented out overwrite-uploads and set the autosave-uploads to false, but I still get a FilePartFile instead of a FilePartArray. thanks, Collin ?xml version=1.0 encoding=UTF-8? !DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN http://java.sun.com/dtd/web-app_2_3.dtd; web-app display-nameContentXML web app/display-name descriptionProvides the administration interface to the ContentXML System/description servlet servlet-nameCocoon2/servlet-name display-nameCocoon2/display-name descriptionThe main Cocoon2 servlet/description !-- In cases you're facing class loader problems you can alternatively use the following servlet-class instead of the normal one servlet-classorg.apache.cocoon.servlet.ParanoidCocoonServlet/servlet-clas s -- servlet-classorg.apache.cocoon.servlet.CocoonServlet/servlet-class !-- This parameter points to the main configuration file for Cocoon. Note that the path is specified in absolute notation but it will be resolved relative to the servlets webapp context path -- init-param param-nameconfigurations/param-name param-value/WEB-INF/cocoon.xconf/param-value /init-param !-- This parameter tells cocoon to set the thread's context classloader to its own classloader. If you experience strange classloader issues, try setting this parameter to true or using ParanoidCocoonServlet. -- init-param param-nameinit-classloader/param-name param-valuefalse/param-value /init-param !-- This parameter indicates the configuration file of the LogKit management -- init-param param-namelogkit-config/param-name param-value/WEB-INF/logkit.xconf/param-value /init-param !-- This parameter indicates the category id of the logger from the LogKit configuration used by the CocoonServlet. -- init-param param-nameservlet-logger/param-name param-valueaccess/param-value /init-param !-- This parameter indicates the category id of the logger from the LogKit management configuration for the Cocoon engine. This logger is used for all components described in the cocoon.xconf and sitemap.xmap file not having specified a logger with the logger=... attribute in the component configuration file. -- init-param param-namecocoon-logger/param-name param-valuecore/param-value /init-param !-- This parameter indicates the log level to use throughout startup of the system. As soon as the logkit.xconf the setting of the logkit.xconf configuration is used instead! Only for startup and if the logkit.xconf is not readable/available this log level is of importance. Available levels are: DEBUG: prints all level of log messages. INFO: prints all level of log messages except DEBUG ones. WARN: prints all level of log messages except DEBUG and INFO ones. ERROR: prints all level of log messages except DEBUG, INFO and WARN ones. FATAL_ERROR: prints only log messages of this level -- init-param param-namelog-level/param-name param-valueINFO/param-value /init-param !-- Allow reinstantiating (reloading) of the cocoon instance. If this is set to yes or true, a new cocoon instance can be created using the request parameter cocoon-reload. -- init-param param-nameallow-reload/param-name param-valueyes/param-value /init-param !-- This parameter is used to list classes that should be loaded at initialization time of the servlet. Usually this classes are JDBC Drivers used -- init-param param-nameload-class/param-name param-value !-- For IBM WebSphere: com.ibm.servlet.classloader.Handler -- !-- For Database Driver: -- org.hsqldb.jdbcDriver !-- For parent ComponentManager sample: org.apache.cocoon.samples.parentcm.Configurator -- /param-value /init-param !-- This parameter allows to specify where Cocoon should put uploaded files. The path specified can be either absolute or relative to the context path of the servlet. On windows platform, absolute directory must start with volume: C:\Path\To\Upload\Directory The default directory is upload-dir in the work-directory init-param param-nameupload-directory/param-name param-valueWEB-INF/work/upload-dir/param-value /init-param -- !-- Causes all files in multipart requests to be saved to upload-dir. Default is true. Unsupported values will be interpreted as false. -- init-param param-nameautosave-uploads/param-name param-valuefalse/param-value /init-param !-- Specify handling of name conflicts when saving uploaded files to disk. Acceptable values are deny, allow, rename (default). Files are renamed x_filename where x is an integer value incremented to make the new filename unique. init-param param-nameoverwrite-uploads/param-name param-valueallow/param-value /init-param -- !-- Specify maximum allowed size of the upload. Defaults to 10 Mb. init-param param-nameupload-max-size/param-name param-value1000/param-value /init-param -- !-- This parameter allows to specify where Cocoon should create its page and other objects cache. The path specified
RE: Parsing multipart form data
sounds to me like something is wrong with your web.xml (more below): Thanks Geoff Well, yes, I actually started going thru the mail lists and found your link below. It is helpful, but I cannot get some of the features to work. I DO have the FilePartFile bit working, though I would not like to store such files on the disk. I gave these two init params: init-param param-nameautosave-uploads/param-name param-valuefalse/param-value /init-param init-param param-nameoverwrite-uploads/param-name param-valueallow/param-value /init-param That looks fine... where did you put them? I basically want to keep them in memory, and then use a FilePartArray to save the file contents into the database, but I am having trouble with that. Cocoon does not seem to be recognizing these parameters. Incidentally, I am using 2.0.4, and I built it under java1.4. Ok, you should not have problems then. I put the init-params with the other init-params in web.xml, but strangely did not see any places for it in the web.xml file as it existed. I thouight there would be placeholders for it, but I could not find them. That's what I find weird. They're all in web.xml as you can see here: http://cvs.apache.org/viewcvs.cgi/*checkout*/xml-cocoon2/src/webapp/WEB-INF/ web.xml?rev=1.8.2.5only_with_tag=cocoon_2_0_4 Sanity check: - You did modify the web.xml in cocoon/WEB-INF/ right? (not the one the one in the servlet container/Tomcat conf directory?) - Did you do a search for them using an editor? If searching for the string autosave-uploads is not turning anything up, something's wrong. - Did you restart the servlet container/cocoon? - How did you obtain 2.0.4? (you're sure it's not 2.0.3?) Anyways, I might be missing something. My main problem now is that when I submit a file multiple times, it keeps renaming the file 0_[filename], 1_[filename], You are seeing the (what used to be) default behavior - uploads are autosaved to disk, and filename conflicts are renamed (bad race condition there at one point so beware). This makes me think you're using 2.0.3? etc.. I think my workaround will be to just delete the file once I am done with it, but I would like to keep it in memory if at all possible. That works as well (actually I'd love to see a third option for autosave-uploads: temp which would delete the file after the servlet finishes processing. Haven't been able to look into it yet (any volunteers?) Thanks very much for your help! Collin No problem. Geoff - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Parsing multipart form data
ah, that brings to mind another idea - send a snippet of your action that deals with getting the FilePart... Geoff -Original Message- From: Collin VanDyck [mailto:[EMAIL PROTECTED]] Sent: Monday, January 20, 2003 5:02 PM To: [EMAIL PROTECTED] Subject: Re: Parsing multipart form data Here is my web.xml file. (It's long, so an apology in advance). I hope this helps, and I really do appreciate everyone's help in this list. I commented out overwrite-uploads and set the autosave-uploads to false, but I still get a FilePartFile instead of a FilePartArray. thanks, Collin ?xml version=1.0 encoding=UTF-8? !DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN http://java.sun.com/dtd/web-app_2_3.dtd; web-app display-nameContentXML web app/display-name descriptionProvides the administration interface to the ContentXML System/description servlet servlet-nameCocoon2/servlet-name display-nameCocoon2/display-name descriptionThe main Cocoon2 servlet/description !-- In cases you're facing class loader problems you can alternatively use the following servlet-class instead of the normal one servlet-classorg.apache.cocoon.servlet.ParanoidCocoonServlet/se rvlet-clas s -- servlet-classorg.apache.cocoon.servlet.CocoonServlet/servlet-class !-- This parameter points to the main configuration file for Cocoon. Note that the path is specified in absolute notation but it will be resolved relative to the servlets webapp context path -- init-param param-nameconfigurations/param-name param-value/WEB-INF/cocoon.xconf/param-value /init-param !-- This parameter tells cocoon to set the thread's context classloader to its own classloader. If you experience strange classloader issues, try setting this parameter to true or using ParanoidCocoonServlet. -- init-param param-nameinit-classloader/param-name param-valuefalse/param-value /init-param !-- This parameter indicates the configuration file of the LogKit management -- init-param param-namelogkit-config/param-name param-value/WEB-INF/logkit.xconf/param-value /init-param !-- This parameter indicates the category id of the logger from the LogKit configuration used by the CocoonServlet. -- init-param param-nameservlet-logger/param-name param-valueaccess/param-value /init-param !-- This parameter indicates the category id of the logger from the LogKit management configuration for the Cocoon engine. This logger is used for all components described in the cocoon.xconf and sitemap.xmap file not having specified a logger with the logger=... attribute in the component configuration file. -- init-param param-namecocoon-logger/param-name param-valuecore/param-value /init-param !-- This parameter indicates the log level to use throughout startup of the system. As soon as the logkit.xconf the setting of the logkit.xconf configuration is used instead! Only for startup and if the logkit.xconf is not readable/available this log level is of importance. Available levels are: DEBUG: prints all level of log messages. INFO: prints all level of log messages except DEBUG ones. WARN: prints all level of log messages except DEBUG and INFO ones. ERROR: prints all level of log messages except DEBUG, INFO and WARN ones. FATAL_ERROR: prints only log messages of this level -- init-param param-namelog-level/param-name param-valueINFO/param-value /init-param !-- Allow reinstantiating (reloading) of the cocoon instance. If this is set to yes or true, a new cocoon instance can be created using the request parameter cocoon-reload. -- init-param param-nameallow-reload/param-name param-valueyes/param-value /init-param !-- This parameter is used to list classes that should be loaded at initialization time of the servlet. Usually this classes are JDBC Drivers used -- init-param param-nameload-class/param-name param-value !-- For IBM WebSphere: com.ibm.servlet.classloader.Handler -- !-- For Database Driver: -- org.hsqldb.jdbcDriver !-- For parent ComponentManager sample: org.apache.cocoon.samples.parentcm.Configurator -- /param-value /init-param !-- This parameter allows to specify where Cocoon should put uploaded files. The path specified can be either absolute or relative to the context path of the servlet. On windows platform, absolute directory must start with volume: C:\Path\To\Upload\Directory The default directory is upload-dir in the work-directory init-param param-nameupload-directory/param-name param-valueWEB-INF/work/upload-dir/param-value /init-param -- !-- Causes all files in multipart requests to be saved to upload-dir. Default is true. Unsupported values will be interpreted as false. -- init-param param-nameautosave-uploads/param-name param-valuefalse/param-value /init-param !-- Specify handling of name conflicts when saving uploaded files to disk. Acceptable values are deny, allow, rename (default). Files are renamed x_filename where
Re: Parsing multipart form data
Hi Geoff. Here's really the only thing I'm doing with it right now. FilePartFile fpf = (FilePartFile)request.get(file_content); log.info(received file of name: + fpf.getFileName()); thanks,-- Collin - Original Message - From: Geoff Howard [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, January 20, 2003 5:32 PM Subject: RE: Parsing multipart form data ah, that brings to mind another idea - send a snippet of your action that deals with getting the FilePart... Geoff -Original Message- From: Collin VanDyck [mailto:[EMAIL PROTECTED]] Sent: Monday, January 20, 2003 5:02 PM To: [EMAIL PROTECTED] Subject: Re: Parsing multipart form data Here is my web.xml file. (It's long, so an apology in advance). I hope this helps, and I really do appreciate everyone's help in this list. I commented out overwrite-uploads and set the autosave-uploads to false, but I still get a FilePartFile instead of a FilePartArray. thanks, Collin ?xml version=1.0 encoding=UTF-8? !DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN http://java.sun.com/dtd/web-app_2_3.dtd; web-app display-nameContentXML web app/display-name descriptionProvides the administration interface to the ContentXML System/description servlet servlet-nameCocoon2/servlet-name display-nameCocoon2/display-name descriptionThe main Cocoon2 servlet/description !-- In cases you're facing class loader problems you can alternatively use the following servlet-class instead of the normal one servlet-classorg.apache.cocoon.servlet.ParanoidCocoonServlet/se rvlet-clas s -- servlet-classorg.apache.cocoon.servlet.CocoonServlet/servlet-class !-- This parameter points to the main configuration file for Cocoon. Note that the path is specified in absolute notation but it will be resolved relative to the servlets webapp context path -- init-param param-nameconfigurations/param-name param-value/WEB-INF/cocoon.xconf/param-value /init-param !-- This parameter tells cocoon to set the thread's context classloader to its own classloader. If you experience strange classloader issues, try setting this parameter to true or using ParanoidCocoonServlet. -- init-param param-nameinit-classloader/param-name param-valuefalse/param-value /init-param !-- This parameter indicates the configuration file of the LogKit management -- init-param param-namelogkit-config/param-name param-value/WEB-INF/logkit.xconf/param-value /init-param !-- This parameter indicates the category id of the logger from the LogKit configuration used by the CocoonServlet. -- init-param param-nameservlet-logger/param-name param-valueaccess/param-value /init-param !-- This parameter indicates the category id of the logger from the LogKit management configuration for the Cocoon engine. This logger is used for all components described in the cocoon.xconf and sitemap.xmap file not having specified a logger with the logger=... attribute in the component configuration file. -- init-param param-namecocoon-logger/param-name param-valuecore/param-value /init-param !-- This parameter indicates the log level to use throughout startup of the system. As soon as the logkit.xconf the setting of the logkit.xconf configuration is used instead! Only for startup and if the logkit.xconf is not readable/available this log level is of importance. Available levels are: DEBUG: prints all level of log messages. INFO: prints all level of log messages except DEBUG ones. WARN: prints all level of log messages except DEBUG and INFO ones. ERROR: prints all level of log messages except DEBUG, INFO and WARN ones. FATAL_ERROR: prints only log messages of this level -- init-param param-namelog-level/param-name param-valueINFO/param-value /init-param !-- Allow reinstantiating (reloading) of the cocoon instance. If this is set to yes or true, a new cocoon instance can be created using the request parameter cocoon-reload. -- init-param param-nameallow-reload/param-name param-valueyes/param-value /init-param !-- This parameter is used to list classes that should be loaded at initialization time of the servlet. Usually this classes are JDBC Drivers used -- init-param param-nameload-class/param-name param-value !-- For IBM WebSphere: com.ibm.servlet.classloader.Handler -- !-- For Database Driver: -- org.hsqldb.jdbcDriver !-- For parent ComponentManager sample: org.apache.cocoon.samples.parentcm.Configurator -- /param-value /init-param !-- This parameter allows to specify where Cocoon should put uploaded files. The path specified can be either absolute or relative to the context path of the servlet. On windows platform, absolute directory must start with volume: C:\Path\To\Upload\Directory The default directory is upload-dir in the work-directory
Re: Parsing multipart form data
Well, with regards to which web.xml file we are using. I am not sure why this is the way it is, but we have three WAR files, right now exploded, so they aren't archived (read: easy to modify).. Each of the WARs has its own web.xml file with a web-app tag that deals with Cocoon for that web application. Does that sound reasonable? Or would it be looking for the web.xml in the cocoon[something].jar? Collin - Original Message - From: Geoff Howard [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, January 20, 2003 5:32 PM Subject: RE: Parsing multipart form data sounds to me like something is wrong with your web.xml (more below): Thanks Geoff Well, yes, I actually started going thru the mail lists and found your link below. It is helpful, but I cannot get some of the features to work. I DO have the FilePartFile bit working, though I would not like to store such files on the disk. I gave these two init params: init-param param-nameautosave-uploads/param-name param-valuefalse/param-value /init-param init-param param-nameoverwrite-uploads/param-name param-valueallow/param-value /init-param That looks fine... where did you put them? I basically want to keep them in memory, and then use a FilePartArray to save the file contents into the database, but I am having trouble with that. Cocoon does not seem to be recognizing these parameters. Incidentally, I am using 2.0.4, and I built it under java1.4. Ok, you should not have problems then. I put the init-params with the other init-params in web.xml, but strangely did not see any places for it in the web.xml file as it existed. I thouight there would be placeholders for it, but I could not find them. That's what I find weird. They're all in web.xml as you can see here: http://cvs.apache.org/viewcvs.cgi/*checkout*/xml-cocoon2/src/webapp/WEB-INF/ web.xml?rev=1.8.2.5only_with_tag=cocoon_2_0_4 Sanity check: - You did modify the web.xml in cocoon/WEB-INF/ right? (not the one the one in the servlet container/Tomcat conf directory?) - Did you do a search for them using an editor? If searching for the string autosave-uploads is not turning anything up, something's wrong. - Did you restart the servlet container/cocoon? - How did you obtain 2.0.4? (you're sure it's not 2.0.3?) Anyways, I might be missing something. My main problem now is that when I submit a file multiple times, it keeps renaming the file 0_[filename], 1_[filename], You are seeing the (what used to be) default behavior - uploads are autosaved to disk, and filename conflicts are renamed (bad race condition there at one point so beware). This makes me think you're using 2.0.3? etc.. I think my workaround will be to just delete the file once I am done with it, but I would like to keep it in memory if at all possible. That works as well (actually I'd love to see a third option for autosave-uploads: temp which would delete the file after the servlet finishes processing. Haven't been able to look into it yet (any volunteers?) Thanks very much for your help! Collin No problem. Geoff - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Parsing multipart form data
There you go - you've cast to FilePartFile - cast to FilePart (or directly to FilePartArray) and you're set. We need another example at the Wiki (assuming that's where you got the concept from?) showing FilePartArray. Should have thought of that first, Geoff -Original Message- From: Collin VanDyck [mailto:[EMAIL PROTECTED]] Sent: Monday, January 20, 2003 5:22 PM To: [EMAIL PROTECTED] Subject: Re: Parsing multipart form data Hi Geoff. Here's really the only thing I'm doing with it right now. FilePartFile fpf = (FilePartFile)request.get(file_content); log.info(received file of name: + fpf.getFileName()); thanks,-- Collin - Original Message - From: Geoff Howard [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, January 20, 2003 5:32 PM Subject: RE: Parsing multipart form data ah, that brings to mind another idea - send a snippet of your action that deals with getting the FilePart... Geoff -Original Message- From: Collin VanDyck [mailto:[EMAIL PROTECTED]] Sent: Monday, January 20, 2003 5:02 PM To: [EMAIL PROTECTED] Subject: Re: Parsing multipart form data Here is my web.xml file. (It's long, so an apology in advance). I hope this helps, and I really do appreciate everyone's help in this list. I commented out overwrite-uploads and set the autosave-uploads to false, but I still get a FilePartFile instead of a FilePartArray. thanks, Collin ?xml version=1.0 encoding=UTF-8? !DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN http://java.sun.com/dtd/web-app_2_3.dtd; web-app display-nameContentXML web app/display-name descriptionProvides the administration interface to the ContentXML System/description servlet servlet-nameCocoon2/servlet-name display-nameCocoon2/display-name descriptionThe main Cocoon2 servlet/description !-- In cases you're facing class loader problems you can alternatively use the following servlet-class instead of the normal one servlet-classorg.apache.cocoon.servlet.ParanoidCocoonServlet/se rvlet-clas s -- servlet-classorg.apache.cocoon.servlet.CocoonServlet/servlet-class !-- This parameter points to the main configuration file for Cocoon. Note that the path is specified in absolute notation but it will be resolved relative to the servlets webapp context path -- init-param param-nameconfigurations/param-name param-value/WEB-INF/cocoon.xconf/param-value /init-param !-- This parameter tells cocoon to set the thread's context classloader to its own classloader. If you experience strange classloader issues, try setting this parameter to true or using ParanoidCocoonServlet. -- init-param param-nameinit-classloader/param-name param-valuefalse/param-value /init-param !-- This parameter indicates the configuration file of the LogKit management -- init-param param-namelogkit-config/param-name param-value/WEB-INF/logkit.xconf/param-value /init-param !-- This parameter indicates the category id of the logger from the LogKit configuration used by the CocoonServlet. -- init-param param-nameservlet-logger/param-name param-valueaccess/param-value /init-param !-- This parameter indicates the category id of the logger from the LogKit management configuration for the Cocoon engine. This logger is used for all components described in the cocoon.xconf and sitemap.xmap file not having specified a logger with the logger=... attribute in the component configuration file. -- init-param param-namecocoon-logger/param-name param-valuecore/param-value /init-param !-- This parameter indicates the log level to use throughout startup of the system. As soon as the logkit.xconf the setting of the logkit.xconf configuration is used instead! Only for startup and if the logkit.xconf is not readable/available this log level is of importance. Available levels are: DEBUG: prints all level of log messages. INFO: prints all level of log messages except DEBUG ones. WARN: prints all level of log messages except DEBUG and INFO ones. ERROR: prints all level of log messages except DEBUG, INFO and WARN ones. FATAL_ERROR: prints only log messages of this level -- init-param param-namelog-level/param-name param-valueINFO/param-value /init-param !-- Allow reinstantiating (reloading) of the cocoon instance. If this is set to yes or true, a new cocoon instance can be created using the request parameter cocoon-reload. -- init-param param-nameallow-reload/param-name param-valueyes/param-value /init-param !-- This parameter is used to list classes that should be loaded at initialization time of the servlet. Usually this classes are JDBC Drivers used -- init-param param-nameload-class/param-name
Re: Parsing multipart form data
Hi Geoff, When I cast directly to FilePartArray I get a ClassCastException, which I thought was due to Cocoon not receiving the init-param correctly. Is that normal? Collin - Original Message - From: Geoff Howard [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, January 20, 2003 5:37 PM Subject: RE: Parsing multipart form data There you go - you've cast to FilePartFile - cast to FilePart (or directly to FilePartArray) and you're set. We need another example at the Wiki (assuming that's where you got the concept from?) showing FilePartArray. Should have thought of that first, Geoff -Original Message- From: Collin VanDyck [mailto:[EMAIL PROTECTED]] Sent: Monday, January 20, 2003 5:22 PM To: [EMAIL PROTECTED] Subject: Re: Parsing multipart form data Hi Geoff. Here's really the only thing I'm doing with it right now. FilePartFile fpf = (FilePartFile)request.get(file_content); log.info(received file of name: + fpf.getFileName()); thanks,-- Collin - Original Message - From: Geoff Howard [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, January 20, 2003 5:32 PM Subject: RE: Parsing multipart form data ah, that brings to mind another idea - send a snippet of your action that deals with getting the FilePart... Geoff -Original Message- From: Collin VanDyck [mailto:[EMAIL PROTECTED]] Sent: Monday, January 20, 2003 5:02 PM To: [EMAIL PROTECTED] Subject: Re: Parsing multipart form data Here is my web.xml file. (It's long, so an apology in advance). I hope this helps, and I really do appreciate everyone's help in this list. I commented out overwrite-uploads and set the autosave-uploads to false, but I still get a FilePartFile instead of a FilePartArray. thanks, Collin ?xml version=1.0 encoding=UTF-8? !DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN http://java.sun.com/dtd/web-app_2_3.dtd; web-app display-nameContentXML web app/display-name descriptionProvides the administration interface to the ContentXML System/description servlet servlet-nameCocoon2/servlet-name display-nameCocoon2/display-name descriptionThe main Cocoon2 servlet/description !-- In cases you're facing class loader problems you can alternatively use the following servlet-class instead of the normal one servlet-classorg.apache.cocoon.servlet.ParanoidCocoonServlet/se rvlet-clas s -- servlet-classorg.apache.cocoon.servlet.CocoonServlet/servlet-class !-- This parameter points to the main configuration file for Cocoon. Note that the path is specified in absolute notation but it will be resolved relative to the servlets webapp context path -- init-param param-nameconfigurations/param-name param-value/WEB-INF/cocoon.xconf/param-value /init-param !-- This parameter tells cocoon to set the thread's context classloader to its own classloader. If you experience strange classloader issues, try setting this parameter to true or using ParanoidCocoonServlet. -- init-param param-nameinit-classloader/param-name param-valuefalse/param-value /init-param !-- This parameter indicates the configuration file of the LogKit management -- init-param param-namelogkit-config/param-name param-value/WEB-INF/logkit.xconf/param-value /init-param !-- This parameter indicates the category id of the logger from the LogKit configuration used by the CocoonServlet. -- init-param param-nameservlet-logger/param-name param-valueaccess/param-value /init-param !-- This parameter indicates the category id of the logger from the LogKit management configuration for the Cocoon engine. This logger is used for all components described in the cocoon.xconf and sitemap.xmap file not having specified a logger with the logger=... attribute in the component configuration file. -- init-param param-namecocoon-logger/param-name param-valuecore/param-value /init-param !-- This parameter indicates the log level to use throughout startup of the system. As soon as the logkit.xconf the setting of the logkit.xconf configuration is used instead! Only for startup and if the logkit.xconf is not readable/available this log level is of importance. Available levels are: DEBUG: prints all level of log messages. INFO: prints all level of log messages except DEBUG ones. WARN: prints all level of log messages except DEBUG and INFO ones. ERROR: prints all level of log messages except DEBUG, INFO and WARN ones. FATAL_ERROR: prints only log messages of this level -- init-param param-namelog-level/param-name param-valueINFO/param-value /init-param !--
XSP Redirection HELP!!!
Hi, I am using cocoon 2.0.3 with tomcat 4.1. In my xsl form submit I call an action that generates an xsp. The xsp writes the form data to sql; After this I need an auto redirect to the home page. How do I do this? Thanks for the help. Raj _ The new MSN 8: smart spam protection and 2 months FREE* http://join.msn.com/?page=features/junkmail - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: XSP Redirection HELP!!!
Rajasekhar Atchutuni dijo: Hi, I am using cocoon 2.0.3 with tomcat 4.1. In my xsl form submit I call an action that generates an xsp. The xsp writes the form data to sql; After this I need an auto redirect to the home page. How do I do this? Thanks for the help. Raj Hi: I understand that you generate a request that use the XSP Generator. (Please, dont get me wrong here. I am just trying to explain what I understanded from your mail). If this is true You can change the pipeline to make the update to the SQL database using Database Actions (there are two flavors) and after sucessfull update, you redirect the page where you need it. Any Action is executed inmediately as they are readed from the sitemap. Please read between lines: before the selected pipeline is executed. For more info about Database Actions see: http://wiki.cocoondev.org/Wiki.jsp?page=DatabaseActions By the way, If you can, update to 2.0.4 that is more stable... Note: I dont know if Modular Database Actions works in 2.03 I think no, but check for some examples if this flavor of DB Actions are included or not. Original Database Actions are fine too. I hope It will helps you. Best Regards, Antonio Gallardo. _ The new MSN 8: smart spam protection and 2 months FREE* http://join.msn.com/?page=features/junkmail - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: XSP Redirection HELP!!!
Hi, I am sorry I framed my question wrong. I am already successfully saving my form data to oracle using esql:query in my xsp page. What I need to know is how I can send/redirect the user to the home page, after I close the esql:connection. Thanks Raj Original Message Follows From: Antonio Gallardo [EMAIL PROTECTED] Reply-To: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: Re: XSP Redirection HELP!!! Date: Mon, 20 Jan 2003 17:31:19 -0600 (CST) MIME-Version: 1.0 Received: from apache.org ([63.251.56.142]) by mc6-f24.law1.hotmail.com with Microsoft SMTPSVC(5.0.2195.5600); Mon, 20 Jan 2003 15:29:37 -0800 Received: (qmail 48698 invoked by uid 500); 20 Jan 2003 23:29:25 - Received: (qmail 48685 invoked from network); 20 Jan 2003 23:29:23 - Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm Precedence: bulk list-help: mailto:[EMAIL PROTECTED] list-unsubscribe: mailto:[EMAIL PROTECTED] list-post: mailto:[EMAIL PROTECTED] Delivered-To: mailing list [EMAIL PROTECTED] X-Authentication-Warning: ags01.agsoftware.dnsalias.com: apache set sender to [EMAIL PROTECTED] using -f Message-ID: [EMAIL PROTECTED] In-Reply-To: [EMAIL PROTECTED] References: [EMAIL PROTECTED] X-Priority: 3 Importance: Normal X-Mailer: SquirrelMail (version 1.2.9) X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N Return-Path: [EMAIL PROTECTED] X-OriginalArrivalTime: 20 Jan 2003 23:29:37.0819 (UTC) FILETIME=[CC537EB0:01C2C0DB] Rajasekhar Atchutuni dijo: Hi, I am using cocoon 2.0.3 with tomcat 4.1. In my xsl form submit I call an action that generates an xsp. The xsp writes the form data to sql; After this I need an auto redirect to the home page. How do I do this? Thanks for the help. Raj Hi: I understand that you generate a request that use the XSP Generator. (Please, dont get me wrong here. I am just trying to explain what I understanded from your mail). If this is true You can change the pipeline to make the update to the SQL database using Database Actions (there are two flavors) and after sucessfull update, you redirect the page where you need it. Any Action is executed inmediately as they are readed from the sitemap. Please read between lines: before the selected pipeline is executed. For more info about Database Actions see: http://wiki.cocoondev.org/Wiki.jsp?page=DatabaseActions By the way, If you can, update to 2.0.4 that is more stable... Note: I dont know if Modular Database Actions works in 2.03 I think no, but check for some examples if this flavor of DB Actions are included or not. Original Database Actions are fine too. I hope It will helps you. Best Regards, Antonio Gallardo. _ The new MSN 8: smart spam protection and 2 months FREE* http://join.msn.com/?page=features/junkmail - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ The new MSN 8: smart spam protection and 2 months FREE* http://join.msn.com/?page=features/junkmail - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: serializing inside a transformer
On Mon, Jan 20, 2003 at 07:52:24PM +0100, Oskar Casquero wrote: I agree with you. I thought that using a serializer would be useful to get an input source for the parser. But now I see that it would be much better to use JARV to develop the transformer based only in SAX events (use 4_2 of JARV), as you suggested. I have another question, which is the same I did before: how do I set the VerifierHandler of JARV in order to send to it the SAX events the transformer is receiving from the previous component? With super.setContentHandler(verifierHandler), perhaps? public class ValidationTransformer extends AbstractSAXTransformer { ... super.setContentHandler(verifierHandler); ... } Yes I think so. As an example of this, have a look at how AbstractSAXTransformer handles 'recorders'. --Jeff Thank you Oskar - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: XSP Redirection HELP!!!
Rajasekhar Atchutuni dijo: Hi, I am sorry I framed my question wrong. I am already successfully saving my form data to oracle using esql:query in my xsp page. What I need to know is how I can send/redirect the user to the home page, after I close the esql:connection. Thanks Raj Hi again! Yes, but in order to do that you need to use and action. Can you send the snip of your code? It is still dont clear to me. There are 2 approach: A- One page: ** 1 page that is always called and show the data (edit mode). B- more pages: ** 1 for show a clean form (insert) ** 1 for show the data in a filled form (edit mode) ** 1 for confirm Can you tell me what approach are you using? Antonio Gallardo Original Message Follows From: Antonio Gallardo [EMAIL PROTECTED] Reply-To: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: Re: XSP Redirection HELP!!! Date: Mon, 20 Jan 2003 17:31:19 -0600 (CST) MIME-Version: 1.0 Received: from apache.org ([63.251.56.142]) by mc6-f24.law1.hotmail.com with Microsoft SMTPSVC(5.0.2195.5600); Mon, 20 Jan 2003 15:29:37 -0800 Received: (qmail 48698 invoked by uid 500); 20 Jan 2003 23:29:25 - Received: (qmail 48685 invoked from network); 20 Jan 2003 23:29:23 - Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm Precedence: bulk list-help: mailto:[EMAIL PROTECTED] list-unsubscribe: mailto:[EMAIL PROTECTED] list-post: mailto:[EMAIL PROTECTED] Delivered-To: mailing list [EMAIL PROTECTED] X-Authentication-Warning: ags01.agsoftware.dnsalias.com: apache set sender to [EMAIL PROTECTED] using -f Message-ID: [EMAIL PROTECTED] In-Reply-To: [EMAIL PROTECTED] References: [EMAIL PROTECTED] X-Priority: 3 Importance: Normal X-Mailer: SquirrelMail (version 1.2.9) X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N Return-Path: [EMAIL PROTECTED] X-OriginalArrivalTime: 20 Jan 2003 23:29:37.0819 (UTC) FILETIME=[CC537EB0:01C2C0DB] Rajasekhar Atchutuni dijo: Hi, I am using cocoon 2.0.3 with tomcat 4.1. In my xsl form submit I call an action that generates an xsp. The xsp writes the form data to sql; After this I need an auto redirect to the home page. How do I do this? Thanks for the help. Raj Hi: I understand that you generate a request that use the XSP Generator. (Please, dont get me wrong here. I am just trying to explain what I understanded from your mail). If this is true You can change the pipeline to make the update to the SQL database using Database Actions (there are two flavors) and after sucessfull update, you redirect the page where you need it. Any Action is executed inmediately as they are readed from the sitemap. Please read between lines: before the selected pipeline is executed. For more info about Database Actions see: http://wiki.cocoondev.org/Wiki.jsp?page=DatabaseActions By the way, If you can, update to 2.0.4 that is more stable... Note: I dont know if Modular Database Actions works in 2.03 I think no, but check for some examples if this flavor of DB Actions are included or not. Original Database Actions are fine too. I hope It will helps you. Best Regards, Antonio Gallardo. _ The new MSN 8: smart spam protection and 2 months FREE* http://join.msn.com/?page=features/junkmail - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ The new MSN 8: smart spam protection and 2 months FREE* http://join.msn.com/?page=features/junkmail - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
about instrumentation client.
Hi Marcus! Thanks again! I am back for some advise from the instruments guru. ;-) Where I can find some explaination about the aditional info in the instrument manager? For example the authentication manager has: authentication-manager pool - The pool of the manager blocks - ? creates - Create() a component in the pool decommissions - Destroy() components in the pool gets- Already created and getted? puts- Already in the pool and returned? ready-size - ? size- ? in KB or number of components? gets - ? puts - ? references- Sum of the calls to manager.lock(auth-manager.ROLE) in the code. I know that the components must be declared as instrumentable. But I think currently there are no many components declared as needed. Best Regards, Antonio Gallardo - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Parsing multipart form data
Hi Geoff, When I cast directly to FilePartArray I get a ClassCastException, which I thought was due to Cocoon not receiving the init-param correctly. Is that normal? Collin That sounds right. Change it back to FilePartArray of course. So, back to web.xml/cocoon version for the culprit? - Since you have three web.xml files (one per webapp), make sure you're changing the same one you're testing on (or all three). - Make sure you restart after modifying web.xml. - Confirm what version of cocoon you're using - how did you get 2.0.4? What is the date of the main cocoon jar? Geoff - Original Message - From: Geoff Howard [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, January 20, 2003 5:37 PM Subject: RE: Parsing multipart form data There you go - you've cast to FilePartFile - cast to FilePart (or directly to FilePartArray) and you're set. We need another example at the Wiki (assuming that's where you got the concept from?) showing FilePartArray. Should have thought of that first, Geoff -Original Message- From: Collin VanDyck [mailto:[EMAIL PROTECTED]] Sent: Monday, January 20, 2003 5:22 PM To: [EMAIL PROTECTED] Subject: Re: Parsing multipart form data Hi Geoff. Here's really the only thing I'm doing with it right now. FilePartFile fpf = (FilePartFile)request.get(file_content); log.info(received file of name: + fpf.getFileName()); thanks,-- Collin - Original Message - From: Geoff Howard [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, January 20, 2003 5:32 PM Subject: RE: Parsing multipart form data ah, that brings to mind another idea - send a snippet of your action that deals with getting the FilePart... Geoff -Original Message- From: Collin VanDyck [mailto:[EMAIL PROTECTED]] Sent: Monday, January 20, 2003 5:02 PM To: [EMAIL PROTECTED] Subject: Re: Parsing multipart form data Here is my web.xml file. (It's long, so an apology in advance). I hope this helps, and I really do appreciate everyone's help in this list. I commented out overwrite-uploads and set the autosave-uploads to false, but I still get a FilePartFile instead of a FilePartArray. thanks, Collin ?xml version=1.0 encoding=UTF-8? !DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN http://java.sun.com/dtd/web-app_2_3.dtd; web-app display-nameContentXML web app/display-name descriptionProvides the administration interface to the ContentXML System/description servlet servlet-nameCocoon2/servlet-name display-nameCocoon2/display-name descriptionThe main Cocoon2 servlet/description !-- In cases you're facing class loader problems you can alternatively use the following servlet-class instead of the normal one servlet-classorg.apache.cocoon.servlet.ParanoidCocoonServlet/se rvlet-clas s -- servlet-classorg.apache.cocoon.servlet.CocoonServlet/servlet-class !-- This parameter points to the main configuration file for Cocoon. Note that the path is specified in absolute notation but it will be resolved relative to the servlets webapp context path -- init-param param-nameconfigurations/param-name param-value/WEB-INF/cocoon.xconf/param-value /init-param !-- This parameter tells cocoon to set the thread's context classloader to its own classloader. If you experience strange classloader issues, try setting this parameter to true or using ParanoidCocoonServlet. -- init-param param-nameinit-classloader/param-name param-valuefalse/param-value /init-param !-- This parameter indicates the configuration file of the LogKit management -- init-param param-namelogkit-config/param-name param-value/WEB-INF/logkit.xconf/param-value /init-param !-- This parameter indicates the category id of the logger from the LogKit configuration used by the CocoonServlet. -- init-param param-nameservlet-logger/param-name param-valueaccess/param-value /init-param !-- This parameter indicates the category id of the logger from the LogKit management configuration for the Cocoon engine. This logger is used for all components described in the cocoon.xconf and sitemap.xmap file not having specified a logger with the logger=... attribute in the component configuration file. -- init-param param-namecocoon-logger/param-name param-valuecore/param-value /init-param !-- This parameter indicates the log level to use throughout startup of the system. As soon as the logkit.xconf the setting of the logkit.xconf configuration is used
AW: XSP Redirection HELP!!!
are you using your xsp as an action via ServerPagesAction? are you using your xsp as the target for the form action? like this: form action=save-form-data ... in your sitemap: map:match pattern=save-form-data map:generate type=serverpages src=save-form-data.xsp/ ... /map:match you could redirect after the generation step via map:redirect-to but this is kind of ugly. another alternative would be to use your xsp via the already mentioned ServerPagesAction (if you must use xsp): form action=save-form-data ... in your sitemap: map:match pattern=save-form-data map:act type=serverpages src=save-form-data.xsp/ ... /map:match for this, you must have the serverpages action declared in the sitemap. then you can redirect via map:redirect-to in the sitemap or you can redirect from within the xsp via action:redirect-to (action logicsheet). third alternative would be to directly code the action, invoke it in your 'save-form-data' pipeline, after which you redirect. -Ursprüngliche Nachricht- Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]Im Auftrag von Rajasekhar Atchutuni Gesendet: Dienstag, 21. Januar 2003 00:44 An: [EMAIL PROTECTED] Betreff: Re: XSP Redirection HELP!!! Hi, I am sorry I framed my question wrong. I am already successfully saving my form data to oracle using esql:query in my xsp page. What I need to know is how I can send/redirect the user to the home page, after I close the esql:connection. Thanks Raj - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[OT]--Happy MLK day all.
Very off topic. Happy MLK day all. Only writing this here because I've enjoyed so seeing persons from all cultures working together. In peace. Daniel US _ MSN 8: advanced junk mail protection and 2 months FREE*. http://join.msn.com/?page=features/junkmail - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Non-string sitemap custom parameters
Hello, I need to pass an object of arbitrary type from one action down to another alonga sitemap pipeline, but unfortunately it seems that they are all cast to String. This is an example: map:match pattern="myHello2.html" map:act type="ObjectRetriever" map:act type="CheckParamType" map:parameter name="objParam" value="{objParam}"/ map:generate src=""/ map:transform src="" map:parameter name="zzz" value="20"/ map:parameter name="objParam" value="{objParam}"/ /map:transform map:serialize type="html"/ /map:act /map:act /map:match "ObjectRetriever" puts an object into its return hashmap, with key "objParam". It is passed to "CheckParamType" with the same name. Unfortunately, tracing code in "CheckParamType" logs the fact that objParam is of type java.lang.String, when it should be something else (like a Vector, for instance). Any ideas how I could do that? Thanks, Julio Lerm Chicago, IL
Re: AW: XSP Redirection HELP!!!
Marco Rolappe dijo: are you using your xsp as an action via ServerPagesAction? are you using your xsp as the target for the form action? like this: form action=save-form-data ... in your sitemap: map:match pattern=save-form-data map:generate type=serverpages src=save-form-data.xsp/ ... /map:match you could redirect after the generation step via map:redirect-to but this is kind of ugly. This will does not work because you have one generator in the pipeline. A strict rule in any version af Cocoon told: Just ONE generator for pipeline then the another generator on the target of the redirection will not be loaded. I think it will throw a Exception. (Gurus, please shine us and tell us what will happen). I never tried to do somethig like this. See more comments down. another alternative would be to use your xsp via the already mentioned ServerPagesAction (if you must use xsp): form action=save-form-data ... in your sitemap: map:match pattern=save-form-data map:act type=serverpages src=save-form-data.xsp/ ... /map:match for this, you must have the serverpages action declared in the sitemap. then you can redirect via map:redirect-to in the sitemap or you can redirect from within the xsp via action:redirect-to (action logicsheet). third alternative would be to directly code the action, invoke it in your 'save-form-data' pipeline, after which you redirect. I think this is a good aproach too. But I dont see why to waste a XSP when any flavor of Database Action (Original or Modular) can do this for you. Listen: If you think you need your special XSP page because you need to validate the form data that you received from the user request. The answer is: Why reinvent the cool water? There is another fine action that can do this for you, please check the following snip from my sitemap: !-- catalog of Table -- map:match pattern=*-table.html !-- Create -- map:match type=request-parameter pattern=cocoon-action-Create map:act action=crear type=form-validator map:parameter name=descriptor value=docs/{../1}-form.xml/ map:parameter name=validate-set value=add/ !-- Here data are safely validated -- map:act type=dbAdd map:parameter name=descriptor value=docs/{../../1}-form.xml/ !-- At this point the data are already stored in the database -- map:redirect-to uri=where_ever_you want/ /map:act !-- Here was wa problem. Data are not into the database, but validated -- /map:act !-- Here Data are not passed the validation check -- !-- You can let it empty, since if no other pipeline match it, the handle error will take care of what happened -- /map:match For more info about form Validation Action, please check: http://wiki.cocoondev.org/Wiki.jsp?page=FormValidationUsingCocoon I hope it will help you. ;-) Antonio Gallardo -Ursprüngliche Nachricht- Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]Im Auftrag von Rajasekhar Atchutuni Gesendet: Dienstag, 21. Januar 2003 00:44 An: [EMAIL PROTECTED] Betreff: Re: XSP Redirection HELP!!! Hi, I am sorry I framed my question wrong. I am already successfully saving my form data to oracle using esql:query in my xsp page. What I need to know is how I can send/redirect the user to the home page, after I close the esql:connection. Thanks Raj - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
AW: Non-string sitemap custom parameters
hi, as you may know, actions get parameters via avalon Parameters. if you look at the API you see that the parameters in the end can only contain strings. so you have no direct way to pass objects of other type. but you could pass your objects e.g. via request/session attributes. have a look at the respective docs/API. -Ursprüngliche Nachricht- Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]Im Auftrag von jcplerm Gesendet: Dienstag, 21. Januar 2003 02:35 An: [EMAIL PROTECTED] Betreff: Non-string sitemap custom parameters Hello, I need to pass an object of arbitrary type from one action down to another along a sitemap pipeline, but unfortunately it seems that they are all cast to String. This is an example: map:match pattern=myHello2.html map:act type=ObjectRetriever map:act type=CheckParamType map:parameter name=objParam value={objParam}/ map:generate src=jlerm/test1.xml/ map:transform src=jlerm/test1.xsl map:parameter name=zzz value=20/ map:parameter name=objParam value={objParam}/ /map:transform map:serialize type=html/ /map:act /map:act /map:match ObjectRetriever puts an object into its return hashmap, with key objParam. It is passed to CheckParamType with the same name. Unfortunately, tracing code in CheckParamType logs the fact that objParam is of type java.lang.String, when it should be something else (like a Vector, for instance). Any ideas how I could do that? Thanks, Julio Lerm Chicago, IL - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Non-string sitemap custom parameters
Thanks for your reply. What happens is that I want to access another object from within XSLT by means of Xalan extensions. That object should have access to the request/session objects. I think one way would be to subclass TraxTransformer so that it sets XSLT parameters at setup time in the transformer. TraxTransformer apparently has access to the ObjectModelHelper, from which I can extract the request/session and then pass it to the transformer, and the stylesheet passes them to the target object by means of Xalan extension functions. If you have any other ideas, I would appreciate. Thanks, Julio - Original Message - From: Marco Rolappe [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, January 20, 2003 8:10 PM Subject: AW: Non-string sitemap custom parameters hi, as you may know, actions get parameters via avalon Parameters. if you look at the API you see that the parameters in the end can only contain strings. so you have no direct way to pass objects of other type. but you could pass your objects e.g. via request/session attributes. have a look at the respective docs/API. -Ursprüngliche Nachricht- Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]Im Auftrag von jcplerm Gesendet: Dienstag, 21. Januar 2003 02:35 An: [EMAIL PROTECTED] Betreff: Non-string sitemap custom parameters Hello, I need to pass an object of arbitrary type from one action down to another along a sitemap pipeline, but unfortunately it seems that they are all cast to String. This is an example: map:match pattern=myHello2.html map:act type=ObjectRetriever map:act type=CheckParamType map:parameter name=objParam value={objParam}/ map:generate src=jlerm/test1.xml/ map:transform src=jlerm/test1.xsl map:parameter name=zzz value=20/ map:parameter name=objParam value={objParam}/ /map:transform map:serialize type=html/ /map:act /map:act /map:match ObjectRetriever puts an object into its return hashmap, with key objParam. It is passed to CheckParamType with the same name. Unfortunately, tracing code in CheckParamType logs the fact that objParam is of type java.lang.String, when it should be something else (like a Vector, for instance). Any ideas how I could do that? Thanks, Julio Lerm Chicago, IL - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
AW: AW: XSP Redirection HELP!!!
well, it does work, I tried it out. only one generator per pipeline, that's right (only one generator can be set at pipeline setup time). but in this case, there is only one pipeline, that is the ServerPagesGenerator. the redirect is to another pipeline. anyway, I can imagine the use of XSP actions for prototyping (apart from generating and using XML fragments). -Ursprüngliche Nachricht- Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]Im Auftrag von Antonio Gallardo Gesendet: Dienstag, 21. Januar 2003 03:03 An: [EMAIL PROTECTED] Betreff: Re: AW: XSP Redirection HELP!!! This will does not work because you have one generator in the pipeline. A strict rule in any version af Cocoon told: Just ONE generator for pipeline then the another generator on the target of the redirection will not be loaded. I think it will throw a Exception. (Gurus, please shine us and tell us what will happen). I never tried to do somethig like this. See more comments down. another alternative would be to use your xsp via the already mentioned ServerPagesAction (if you must use xsp): form action=save-form-data ... in your sitemap: map:match pattern=save-form-data map:act type=serverpages src=save-form-data.xsp/ ... /map:match for this, you must have the serverpages action declared in the sitemap. then you can redirect via map:redirect-to in the sitemap or you can redirect from within the xsp via action:redirect-to (action logicsheet). third alternative would be to directly code the action, invoke it in your 'save-form-data' pipeline, after which you redirect. I think this is a good aproach too. But I dont see why to waste a XSP when any flavor of Database Action (Original or Modular) can do this for you. Listen: If you think you need your special XSP page because you need to validate the form data that you received from the user request. The answer is: Why reinvent the cool water? There is another fine action that can do this for you, please check the following snip from my sitemap: !-- catalog of Table -- map:match pattern=*-table.html !-- Create -- map:match type=request-parameter pattern=cocoon-action-Create map:act action=crear type=form-validator map:parameter name=descriptor value=docs/{../1}-form.xml/ map:parameter name=validate-set value=add/ !-- Here data are safely validated -- map:act type=dbAdd map:parameter name=descriptor value=docs/{../../1}-form.xml/ !-- At this point the data are already stored in the database -- map:redirect-to uri=where_ever_you want/ /map:act !-- Here was wa problem. Data are not into the database, but validated -- /map:act !-- Here Data are not passed the validation check -- !-- You can let it empty, since if no other pipeline match it, the handle error will take care of what happened -- /map:match For more info about form Validation Action, please check: http://wiki.cocoondev.org/Wiki.jsp?page=FormValidationUsingCocoon I hope it will help you. ;-) Antonio Gallardo - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: XSP Redirection HELP!!!
Don't know if this is what you are looking for but you can also use the sendRedirect (String url) of the HttpResponse object. Would look something like this: xsp:logic ((HttpResponse)response).sendRedirect (http://my_home_page;); /xsp:logic This is kinda clunky because it sends the response header back to the browser but it does the job from within XSP. Jim Jim McCullough Risk Analytics Inc. - Las Vegas Software Engineering [EMAIL PROTECTED] [EMAIL PROTECTED] (702) 407-1814 (voice) (702) 407-1824 (fax) - Original Message - From: Rajasekhar Atchutuni [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, January 20, 2003 3:07 PM Subject: XSP Redirection HELP!!! Hi, I am using cocoon 2.0.3 with tomcat 4.1. In my xsl form submit I call an action that generates an xsp. The xsp writes the form data to sql; After this I need an auto redirect to the home page. How do I do this? Thanks for the help. Raj _ The new MSN 8: smart spam protection and 2 months FREE* http://join.msn.com/?page=features/junkmail - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [XMLForm] initialization of the model
Yes, to both questions. - Original Message - From: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, January 20, 2003 9:45 AM Subject: RE: [XMLForm] initialization of the model Hi Ivelin, I have tried to put these lines in the prepare() method and it works: code Form.remove(getObjectModel(), getFormId()); getForm().addFormListener(this); code But to understand this thing could you tell me: - the getFormModel() method is called the first time you call the app, right? - is the getFormModel() method called before or after the prepare() method? - the prepare() method is called each time you call the app, right? Thank you Regards Sylvain -Message d'origine- De: Ivelin Ivanov [mailto:[EMAIL PROTECTED]] Date: lundi, 20. janvier 2003 15:18 À: [EMAIL PROTECTED] Objet: Re: [XMLForm] initialization of the model Try the overriding reset() - Original Message - From: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, January 20, 2003 2:53 AM Subject: [XMLForm] initialization of the model Hi all, I'm trying to initialize the model of a XMLForm app each time I call this app. This app is launching from the Cocoon portal, in an authenticated environment. I have followed the solution coming from the posts in this list (thank you for that). The solution was to override the getFormModel() method in the Action class to initialize the model inside. I've done this but I still have a problem: the initialization is proceeded only the first time I call the app (the action) and not each time. What should I do for doing this? Is there maybe a session problem? Any help would be greatly appreciated. Thank you Sylvain - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: AW: AW: XSP Redirection HELP!!!
Marco Rolappe dijo: well, it does work, I tried it out. only one generator per pipeline, that's right (only one generator can be set at pipeline setup time). but in this case, there is only one pipeline, that is the ServerPagesGenerator. the redirect is to another pipeline. Sorry I dont know and I think that as you told. This is a ugly solution. And I dont know if the code can be used in future releases of Cocoon. Anyway I recomend to use the correct approach. Solutions are always many, but we need to use the best. The Cocoon gurus said that the XSP-Action for databases is not the best: http://xml.apache.org/cocoon/userdocs/concepts/databases.html Actions are especially great for inserting, changing, or deleting data. Employing the pipeline-switching features of actions will simplify your pages. Such actions are concerned with only one view: either the success or failure of an operation. ESQL is great when reading data from a database. However, it is less attractive to use when it has to react to operation failures. This is due to the fact that it adds a layer of complexity to an XSP file, making it more difficult to understand and maintain. Best Regards, Antonio Gallardo anyway, I can imagine the use of XSP actions for prototyping (apart from generating and using XML fragments). -Ursprüngliche Nachricht- Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]Im Auftrag von Antonio Gallardo Gesendet: Dienstag, 21. Januar 2003 03:03 An: [EMAIL PROTECTED] Betreff: Re: AW: XSP Redirection HELP!!! This will does not work because you have one generator in the pipeline. A strict rule in any version af Cocoon told: Just ONE generator for pipeline then the another generator on the target of the redirection will not be loaded. I think it will throw a Exception. (Gurus, please shine us and tell us what will happen). I never tried to do somethig like this. See more comments down. another alternative would be to use your xsp via the already mentioned ServerPagesAction (if you must use xsp): form action=save-form-data ... in your sitemap: map:match pattern=save-form-data map:act type=serverpages src=save-form-data.xsp/ ... /map:match for this, you must have the serverpages action declared in the sitemap. then you can redirect via map:redirect-to in the sitemap or you can redirect from within the xsp via action:redirect-to (action logicsheet). third alternative would be to directly code the action, invoke it in your 'save-form-data' pipeline, after which you redirect. I think this is a good aproach too. But I dont see why to waste a XSP when any flavor of Database Action (Original or Modular) can do this for you. Listen: If you think you need your special XSP page because you need to validate the form data that you received from the user request. The answer is: Why reinvent the cool water? There is another fine action that can do this for you, please check the following snip from my sitemap: !-- catalog of Table -- map:match pattern=*-table.html !-- Create -- map:match type=request-parameter pattern=cocoon-action-Create map:act action=crear type=form-validator map:parameter name=descriptor value=docs/{../1}-form.xml/ map:parameter name=validate-set value=add/ !-- Here data are safely validated -- map:act type=dbAdd map:parameter name=descriptor value=docs/{../../1}-form.xml/ !-- At this point the data are already stored in the database -- map:redirect-to uri=where_ever_you want/ /map:act !-- Here was wa problem. Data are not into the database, but validated -- /map:act !-- Here Data are not passed the validation check -- !-- You can let it empty, since if no other pipeline match it, the handle error will take care of what happened -- /map:match For more info about form Validation Action, please check: http://wiki.cocoondev.org/Wiki.jsp?page=FormValidationUsingCocoon I hope it will help you. ;-) Antonio Gallardo - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
AW: Non-string sitemap custom parameters
hi julio, In lack of details I don't completely understand your use case, but if you're trying to code in the stylesheet you should consider writing a transformer for your needs. -Ursprüngliche Nachricht- Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]Im Auftrag von jcplerm Gesendet: Dienstag, 21. Januar 2003 03:16 An: [EMAIL PROTECTED] Betreff: Re: Non-string sitemap custom parameters Thanks for your reply. What happens is that I want to access another object from within XSLT by means of Xalan extensions. That object should have access to the request/session objects. I think one way would be to subclass TraxTransformer so that it sets XSLT parameters at setup time in the transformer. TraxTransformer apparently has access to the ObjectModelHelper, from which I can extract the request/session and then pass it to the transformer, and the stylesheet passes them to the target object by means of Xalan extension functions. If you have any other ideas, I would appreciate. Thanks, Julio - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Set SQL results into an array
Why don't you write a stored procedure on SQL Server ? Something like create procedure myProc as declare myCurs cursor for your first select that gets the array open myCurs fetch from myCurs into while (@@fetch_status = 0) begin insert into .. fetch next from end This is an example of such a stored procedure. It writes values from one query into another CREATE PROCEDURE spADMINExportTranslations as declare @ID int declare @Text varchar(7000) declare @Line varchar(7000) delete from EXPORTTranslations declare TCursor cursor for select ID, Text from Translations where id % 10 between 1 and 74999 and len( text ) = 250 order by id open tcursor fetch next from TCursor into @ID, @Text while (@@fetch_status = 0) begin set @Text = replace (@Text, , + ) set @Line = 'INSERT INTO Translations (ID, Text) VALUES (' set @Line = @Line + cast(@ID as varchar(10)) set @Line = @Line + ', ' + + @Text + set @Line = @Line + ')' insert into ExportTranslations (line) values( @line) fetch next from TCursor into @ID, @Text end close TCursor deallocate TCursor GO Regards, Yves Citeren [EMAIL PROTECTED]: Hi everybody, I use microsoft SQL server, and XSP pages. I also use ESQL for all my DB commands. I want to insert data with query like INSERT Into blabla (ID) values (MyArray) In this query MyArray is the result of another query. How can I make it? Here is an example : Table : XY Columns : ID, Num, Date, Descript Table : blabla Columns : ID, Num_ID, Num_text First I select some entries from table XY : Select * From xy Where Descript LIKE '%abc' Then I want to put them into an array (oARRAY) and make a query to insert entries with these paramters. INSERT INTO blabla (Num_ID, Num_text) VALUES (oARRAY[1], 'abc') INSERT INTO blabla (Num_ID, Num_text) VALUES (oARRAY[2], 'abc') ... Or do someone have another solution? Thanks a lot for your help! - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
new wiki page: file uploads
Added FileUploadsWithCocoon, an overview of how Cocoon deals with multipart file uploads and the configuration options available. see http://wiki.cocoondev.org/Wiki.jsp?page=FileUploadsWithCocoon Geoff Howard - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[HELP]Error in sitemap configuration : org.apache.cocoon.transformation.
Hi, I recently completed a web application for accessing SAP via the Business Connector Server. Now I'm working on integrating SAP R/3 with Cocoon 2.0.4. In this regard, I downloaded the patch (Bug 9075 dated 29/12/02) from Apache Bug Database. But unfortunately the information as to how to go about doing the integration was not clear. I was just wondering - has any one done it before? If so, could you please let me know as to how to go about it. Thanks, Harish Mohanbabu _ Get 25MB, POP3, Spam Filtering with LYCOS MAIL PLUS for $19.95/year. http://login.mail.lycos.com/brandPage.shtml?pageId=plusref=lmtplus - Please check that your question has not already been answered in the FAQ before posting. http://xml.apache.org/cocoon/faq/index.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]