Re: Using existing jsp file
On 03.02.2004 16:33, Anna Bikkina wrote: Thanks for the explanation. I understand it better now, but I still have a problem accessing my jsp page. I am using map:read in map:matches(*.jsp) instead of generate When I use read or generate I am getting the below error . The error is not descriptive. I got the latest code from cocoon and am using it. Any help would be appreciated. org.apache.cocoon.ProcessingException: ServletException while executing JSPEngine: org.apache.jasper.JasperException No reason, no cause somewhere in the stacktrace? Do you use jsp includes or forwards, which do not work AFAIK? The JSP stuff was integrated into Cocoon only as support for legacy code and possible step by step movement to Cocoon. Unfortunately this means that not many people use this code and it's not quite perfect. If nothing helps to get that working using Cocoon is it possible for you to circumvent Cocoon for the JSP requests and give them directly to the servlet container? Joerg On Monday 02 February 2004 07:07 pm, Joerg Heinicke wrote: This must be a basic question. I have a JSP generator and JSP reader in my sitemap. I understand that if I use the JSPReader it can read non xml jsp pages. How can I make cocoon use jspreader instead of the generator.Correct me if my understanding is wrong. Just have a look into the sitemap you are using (I guess it's the default sitemap from JSP block). The above pipeline uses the JSPReader and gives the result as text/html to the client. The above pipeline uses the JSPGenerator and serializes the SAX events to XML. The above pipeline uses the JSPGenerator and serializes the SAX events to HTML. map:read => Reader, map:generate => Generator. Joerg - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using existing jsp file
Thanks for the explanation. I understand it better now, but I still have a problem accessing my jsp page. I am using map:read in map:matches(*.jsp) instead of generate When I use read or generate I am getting the below error . The error is not descriptive. I got the latest code from cocoon and am using it. Any help would be appreciated. org.apache.cocoon.ProcessingException: ServletException while executing JSPEngine: org.apache.jasper.JasperException Thanks, Anna. On Monday 02 February 2004 07:07 pm, Joerg Heinicke wrote: > On 03.02.2004 00:52, Anna Bikkina wrote: > > This must be a basic question. I have a JSP generator and JSP reader in > > my sitemap. I understand that if I use the JSPReader it can read non xml > > jsp pages. How can I make cocoon use jspreader instead of the > > generator.Correct me if my understanding is wrong. > > Just have a look into the sitemap you are using (I guess it's the > default sitemap from JSP block). > > > > > > The above pipeline uses the JSPReader and gives the result as text/html > to the client. > > > > > > > > The above pipeline uses the JSPGenerator and serializes the SAX events > to XML. > > > > > > > The above pipeline uses the JSPGenerator and serializes the SAX events > to HTML. > > map:read => Reader, map:generate => Generator. > > Joerg > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using existing jsp file
Anna Bikkina wrote: This must be a basic question. I have a JSP generator and JSP reader in my sitemap. I understand that if I use the JSPReader it can read non xml jsp pages. How can I make cocoon use jspreader instead of the generator.Correct me if my understanding is wrong. Upayavira I will get the latest cocoon and run it . Thank you once again for the responses. Anna. On Monday 02 February 2004 06:49 pm, Joerg Heinicke wrote: On 03.02.2004 00:38, Anna Bikkina wrote: I need the output in the cocoon pipelines. I am already using the jspReader but it gives me errors. Below is the sitemap that I am using to generate jsp pages. Is JSPReader another option of JTidy/JSPGenerator. You still have the explanation of the two components in your sitemap: JSPGenerator: JspGenerator is used to get result of a JSP page then output it as XML (SAX events) JSPReader: JSPReader is used to serve direct output from a JSP page. Note, that JSP result can be non XML This means the reader has no problem with reading non-XML as it does not have to create SAX events out of it. It just outputs the result to the client. The JSPGenerator *does* generate SAX events of it, i.e. it parses the JSP output. But this will only work with well-formed XML output. Since I have both the JSPGenerator and the JSPReader in the sitemap. Which one is used to display the output of the jsp page. Sorry, but I don't understand what these 2 sentences should mean. When I asked for the need of the JSP output in the pipelines I meant the SAX events. If it is enough for you to give the JSP output directly to the client, you do not need to parse it. Only if you need the SAX events, e.g. for manipulating them via a transformer, you need the tidying JSPGenerator. You said you got errors with JSPReader? What's the error? It should work the same way like JSPGenerator (besides the parsing of course). Here is the error I got An Error Occurred ServletException in JspGenerator.generate() org.apache.cocoon.ProcessingException: ServletException in JspGenerator.generate() cause: org.apache.cocoon.ProcessingException: ServletException in JspGenerator.generate() stacktrace[hide] org.apache.cocoon.ProcessingException: ServletException in JspGenerator.generate() at org.apache.cocoon.generation.JspGenerator.generate(JspGenerator.java:124) Unfortunately that's the shortened stacktrace that is not very helpful. This issue was fixed only some days ago: http://nagoya.apache.org/bugzilla/show_bug.cgi?id=23269. Is it possible for you to either update your Cocoon to latest CVS version or to modify your local code as in the diff at http://cvs.apache.org/viewcvs.cgi/cocoon-2.1/src/blocks/jsp/java/org/apache /cocoon/reading/JSPReader.java?r1=1.8&r2=1.9&diff_format=h It's just the getRootCause() that must be removed in JSPReader. You must rebuild Cocoon afterwards, but alltogether it should not take more than 5 minutes. You can make the same change in the JSPGenerator class as this one could fail with the same not helpful message: http://cvs.apache.org/viewcvs.cgi/cocoon-2.1/src/blocks/jsp/java/org/apache /cocoon/generation/JSPGenerator.java?r1=1.1&r2=1.2&diff_format=h Joerg - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using existing jsp file
On 03.02.2004 00:52, Anna Bikkina wrote: This must be a basic question. I have a JSP generator and JSP reader in my sitemap. I understand that if I use the JSPReader it can read non xml jsp pages. How can I make cocoon use jspreader instead of the generator.Correct me if my understanding is wrong. Just have a look into the sitemap you are using (I guess it's the default sitemap from JSP block). The above pipeline uses the JSPReader and gives the result as text/html to the client. The above pipeline uses the JSPGenerator and serializes the SAX events to XML. The above pipeline uses the JSPGenerator and serializes the SAX events to HTML. map:read => Reader, map:generate => Generator. Joerg - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using existing jsp file
This must be a basic question. I have a JSP generator and JSP reader in my sitemap. I understand that if I use the JSPReader it can read non xml jsp pages. How can I make cocoon use jspreader instead of the generator.Correct me if my understanding is wrong. I will get the latest cocoon and run it . Thank you once again for the responses. Anna. On Monday 02 February 2004 06:49 pm, Joerg Heinicke wrote: > On 03.02.2004 00:38, Anna Bikkina wrote: > >>>I need the output in the cocoon pipelines. I am already using the > >>>jspReader but it gives me errors. Below is the sitemap that I am using > >>>to generate jsp pages. Is JSPReader another option of > >>> JTidy/JSPGenerator. > >> > >>You still have the explanation of the two components in your sitemap: > >> > >>JSPGenerator: JspGenerator is used to get result of a JSP page then > >>output it as XML (SAX events) > >> > >>JSPReader: JSPReader is used to serve direct output from a JSP page. > >>Note, that JSP result can be non XML > >> > >>This means the reader has no problem with reading non-XML as it does not > >>have to create SAX events out of it. It just outputs the result to the > >>client. > >> > >>The JSPGenerator *does* generate SAX events of it, i.e. it parses the > >>JSP output. But this will only work with well-formed XML output. > > > > Since I have both the JSPGenerator and the JSPReader in the sitemap. > > Which one is used to display the output of the jsp page. > > Sorry, but I don't understand what these 2 sentences should mean. > > >>When I asked for the need of the JSP output in the pipelines I meant the > >>SAX events. If it is enough for you to give the JSP output directly to > >>the client, you do not need to parse it. Only if you need the SAX > >>events, e.g. for manipulating them via a transformer, you need the > >>tidying JSPGenerator. > >> > >>You said you got errors with JSPReader? What's the error? It should work > >>the same way like JSPGenerator (besides the parsing of course). > > > > Here is the error I got > > > > An Error Occurred > > > > > > ServletException in JspGenerator.generate() > > > > > > org.apache.cocoon.ProcessingException: ServletException in > > JspGenerator.generate() > > > > > > cause: org.apache.cocoon.ProcessingException: ServletException in > > JspGenerator.generate() > > > > > > stacktrace[hide] > > > > org.apache.cocoon.ProcessingException: ServletException in > > JspGenerator.generate() > > at > > org.apache.cocoon.generation.JspGenerator.generate(JspGenerator.java:124) > > Unfortunately that's the shortened stacktrace that is not very helpful. > This issue was fixed only some days ago: > http://nagoya.apache.org/bugzilla/show_bug.cgi?id=23269. > > Is it possible for you to either update your Cocoon to latest CVS > version or to modify your local code as in the diff at > http://cvs.apache.org/viewcvs.cgi/cocoon-2.1/src/blocks/jsp/java/org/apache >/cocoon/reading/JSPReader.java?r1=1.8&r2=1.9&diff_format=h It's just the > getRootCause() that must be removed in JSPReader. You must rebuild Cocoon > afterwards, but alltogether it should not take more than 5 minutes. You can > make the same change in the JSPGenerator class as this one could fail with > the same not helpful message: > http://cvs.apache.org/viewcvs.cgi/cocoon-2.1/src/blocks/jsp/java/org/apache >/cocoon/generation/JSPGenerator.java?r1=1.1&r2=1.2&diff_format=h > > Joerg > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using existing jsp file
On 03.02.2004 00:38, Anna Bikkina wrote: I need the output in the cocoon pipelines. I am already using the jspReader but it gives me errors. Below is the sitemap that I am using to generate jsp pages. Is JSPReader another option of JTidy/JSPGenerator. You still have the explanation of the two components in your sitemap: JSPGenerator: JspGenerator is used to get result of a JSP page then output it as XML (SAX events) JSPReader: JSPReader is used to serve direct output from a JSP page. Note, that JSP result can be non XML This means the reader has no problem with reading non-XML as it does not have to create SAX events out of it. It just outputs the result to the client. The JSPGenerator *does* generate SAX events of it, i.e. it parses the JSP output. But this will only work with well-formed XML output. Since I have both the JSPGenerator and the JSPReader in the sitemap. Which one is used to display the output of the jsp page. Sorry, but I don't understand what these 2 sentences should mean. When I asked for the need of the JSP output in the pipelines I meant the SAX events. If it is enough for you to give the JSP output directly to the client, you do not need to parse it. Only if you need the SAX events, e.g. for manipulating them via a transformer, you need the tidying JSPGenerator. You said you got errors with JSPReader? What's the error? It should work the same way like JSPGenerator (besides the parsing of course). Here is the error I got An Error Occurred ServletException in JspGenerator.generate() org.apache.cocoon.ProcessingException: ServletException in JspGenerator.generate() cause: org.apache.cocoon.ProcessingException: ServletException in JspGenerator.generate() stacktrace[hide] org.apache.cocoon.ProcessingException: ServletException in JspGenerator.generate() at org.apache.cocoon.generation.JspGenerator.generate(JspGenerator.java:124) Unfortunately that's the shortened stacktrace that is not very helpful. This issue was fixed only some days ago: http://nagoya.apache.org/bugzilla/show_bug.cgi?id=23269. Is it possible for you to either update your Cocoon to latest CVS version or to modify your local code as in the diff at http://cvs.apache.org/viewcvs.cgi/cocoon-2.1/src/blocks/jsp/java/org/apache/cocoon/reading/JSPReader.java?r1=1.8&r2=1.9&diff_format=h It's just the getRootCause() that must be removed in JSPReader. You must rebuild Cocoon afterwards, but alltogether it should not take more than 5 minutes. You can make the same change in the JSPGenerator class as this one could fail with the same not helpful message: http://cvs.apache.org/viewcvs.cgi/cocoon-2.1/src/blocks/jsp/java/org/apache/cocoon/generation/JSPGenerator.java?r1=1.1&r2=1.2&diff_format=h Joerg - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using existing jsp file
On Monday 02 February 2004 06:19 pm, Joerg Heinicke wrote: > On 03.02.2004 00:00, Anna Bikkina wrote: > > I need the output in the cocoon pipelines. I am already using the > > jspReader but it gives me errors. Below is the sitemap that I am using > > to generate jsp pages. Is JSPReader another option of JTidy/JSPGenerator. > > You still have the explanation of the two components in your sitemap: > > JSPGenerator: JspGenerator is used to get result of a JSP page then > output it as XML (SAX events) > > JSPReader: JSPReader is used to serve direct output from a JSP page. > Note, that JSP result can be non XML > > This means the reader has no problem with reading non-XML as it does not > have to create SAX events out of it. It just outputs the result to the > client. > > The JSPGenerator *does* generate SAX events of it, i.e. it parses the > JSP output. But this will only work with well-formed XML output. Since I have both the JSPGenerator and the JSPReader in the sitemap. Which one is used to display the output of the jsp page. > > When I asked for the need of the JSP output in the pipelines I meant the > SAX events. If it is enough for you to give the JSP output directly to > the client, you do not need to parse it. Only if you need the SAX > events, e.g. for manipulating them via a transformer, you need the > tidying JSPGenerator. > > You said you got errors with JSPReader? What's the error? It should work > the same way like JSPGenerator (besides the parsing of course). > Here is the error I got An Error Occurred ServletException in JspGenerator.generate() org.apache.cocoon.ProcessingException: ServletException in JspGenerator.generate() cause: org.apache.cocoon.ProcessingException: ServletException in JspGenerator.generate() stacktrace[hide] org.apache.cocoon.ProcessingException: ServletException in JspGenerator.generate() at org.apache.cocoon.generation.JspGenerator.generate(JspGenerator.java:124) at org.apache.cocoon.components.pipeline.AbstractProcessingPipeline.processXMLPipeline(AbstractProcessingPipeline.java:557) at org.apache.cocoon.components.pipeline.impl.AbstractCachingProcessingPipeline.processXMLPipeline(AbstractCachingProcessingPipeline.java:196) at org.apache.cocoon.components.pipeline.AbstractProcessingPipeline.process(AbstractProcessingPipeline.java:501) at org.apache.cocoon.components.treeprocessor.sitemap.SerializeNode.invoke(SerializeNode.java:147) 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:163) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:108) at org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(PipelinesNode.java:152) at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcessor.java:354) at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcessor.java:307) at org.apache.cocoon.components.treeprocessor.sitemap.MountNode.invoke(MountNode.java:133) at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractPar > Joerg > > > > > http://apache.org/cocoon/sitemap/1.0";> > > > > > > > > > > > >> src="org.apache.cocoon.generation.JspGenerator"/> > > > > > > > > > >> src="org.apache.cocoon.reading.JSPReader"/> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > On Monday 02 February 2004 05:46 pm, Joerg Heinicke wrote: > >>On 02.02.2004 23:24, Anna Bikkina wrote: > >>>Looks like my jsp pages are not well formatted xml docs. They are more > >>>html stuff with jsp tags. Can anyone help me use the same jsps without > >>>rewriting the existing ones. Rewriting them would be a lot of work and > >>> we do not have so much time to complete the project. > >> > >>Do you need the output of the JSP in the Cocoon pipelines? If not you > >>can use JSPReader. Otherwise you need to extend the JSPGenerator with > >>the JTidy functionality as in HTMLGenerator. > >> > >>Joerg > > - > To unsubscribe, e-mail: [EMAIL PROT
Re: Using existing jsp file
On 03.02.2004 00:00, Anna Bikkina wrote: I need the output in the cocoon pipelines. I am already using the jspReader but it gives me errors. Below is the sitemap that I am using to generate jsp pages. Is JSPReader another option of JTidy/JSPGenerator. You still have the explanation of the two components in your sitemap: JSPGenerator: JspGenerator is used to get result of a JSP page then output it as XML (SAX events) JSPReader: JSPReader is used to serve direct output from a JSP page. Note, that JSP result can be non XML This means the reader has no problem with reading non-XML as it does not have to create SAX events out of it. It just outputs the result to the client. The JSPGenerator *does* generate SAX events of it, i.e. it parses the JSP output. But this will only work with well-formed XML output. When I asked for the need of the JSP output in the pipelines I meant the SAX events. If it is enough for you to give the JSP output directly to the client, you do not need to parse it. Only if you need the SAX events, e.g. for manipulating them via a transformer, you need the tidying JSPGenerator. You said you got errors with JSPReader? What's the error? It should work the same way like JSPGenerator (besides the parsing of course). Joerg http://apache.org/cocoon/sitemap/1.0";> src="org.apache.cocoon.generation.JspGenerator"/> On Monday 02 February 2004 05:46 pm, Joerg Heinicke wrote: On 02.02.2004 23:24, Anna Bikkina wrote: Looks like my jsp pages are not well formatted xml docs. They are more html stuff with jsp tags. Can anyone help me use the same jsps without rewriting the existing ones. Rewriting them would be a lot of work and we do not have so much time to complete the project. Do you need the output of the JSP in the Cocoon pipelines? If not you can use JSPReader. Otherwise you need to extend the JSPGenerator with the JTidy functionality as in HTMLGenerator. Joerg - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using existing jsp file
I need the output in the cocoon pipelines. I am already using the jspReader but it gives me errors. Below is the sitemap that I am using to generate jsp pages. Is JSPReader another option of JTidy/JSPGenerator. Thanks, Anna http://apache.org/cocoon/sitemap/1.0";> On Monday 02 February 2004 05:46 pm, Joerg Heinicke wrote: > On 02.02.2004 23:24, Anna Bikkina wrote: > > Looks like my jsp pages are not well formatted xml docs. They are more > > html stuff with jsp tags. Can anyone help me use the same jsps without > > rewriting the existing ones. Rewriting them would be a lot of work and we > > do not have so much time to complete the project. > > Do you need the output of the JSP in the Cocoon pipelines? If not you > can use JSPReader. Otherwise you need to extend the JSPGenerator with > the JTidy functionality as in HTMLGenerator. > > Joerg > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using existing jsp file
On 02.02.2004 23:24, Anna Bikkina wrote: Looks like my jsp pages are not well formatted xml docs. They are more html stuff with jsp tags. Can anyone help me use the same jsps without rewriting the existing ones. Rewriting them would be a lot of work and we do not have so much time to complete the project. Do you need the output of the JSP in the Cocoon pipelines? If not you can use JSPReader. Otherwise you need to extend the JSPGenerator with the JTidy functionality as in HTMLGenerator. Joerg - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using existing jsp file
Looks like my jsp pages are not well formatted xml docs. They are more html stuff with jsp tags. Can anyone help me use the same jsps without rewriting the existing ones. Rewriting them would be a lot of work and we do not have so much time to complete the project. Thanks, Anna. On Monday 02 February 2004 05:09 pm, Upayavira wrote: > Anna Bikkina wrote: > >Hi, > > > >I have an existing website which has jsp files and html files. I want to > > use the jsp's directly when porting to cocoon. Cocoon is complaining > > about jsp tags, META tags(html) and other "&" symbols in between the > > text. Can anyone help me how I can overcome this and use existing jsp's > > and htmls in cocoon directly so that I do not have to rewrite them. > > > >ps: I added the JSp generator and reader to the main component section of > > the sitemap. > > does your JSP output well formed XML? The JSPGenerator will expect that > of a JSP page. If not, others here might be able to help you work with > your current pages. > > Regards, Upayavira > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using existing jsp file
Anna Bikkina wrote: Hi, I have an existing website which has jsp files and html files. I want to use the jsp's directly when porting to cocoon. Cocoon is complaining about jsp tags, META tags(html) and other "&" symbols in between the text. Can anyone help me how I can overcome this and use existing jsp's and htmls in cocoon directly so that I do not have to rewrite them. ps: I added the JSp generator and reader to the main component section of the sitemap. does your JSP output well formed XML? The JSPGenerator will expect that of a JSP page. If not, others here might be able to help you work with your current pages. Regards, Upayavira - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Using existing jsp file
Hi, I have an existing website which has jsp files and html files. I want to use the jsp's directly when porting to cocoon. Cocoon is complaining about jsp tags, META tags(html) and other "&" symbols in between the text. Can anyone help me how I can overcome this and use existing jsp's and htmls in cocoon directly so that I do not have to rewrite them. ps: I added the JSp generator and reader to the main component section of the sitemap. Thanks, Anna. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]