You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by "Alexander Daniel (JIRA)" <ji...@apache.org> on 2009/01/30 15:47:59 UTC
[jira] Created: (COCOON3-23) StackOverflowError on
CachingPipeline.setup(OutputStream)
StackOverflowError on CachingPipeline.setup(OutputStream)
---------------------------------------------------------
Key: COCOON3-23
URL: https://issues.apache.org/jira/browse/COCOON3-23
Project: Cocoon 3
Issue Type: Bug
Components: cocoon-pipeline
Affects Versions: 3.0.0-alpha-1
Reporter: Alexander Daniel
Assignee: Cocoon Developers Team
CachingPipeline.setup(OutputStream) calls itself resulting in a StackOverflowError [1]. I suppose that it should create a CachingOutputStream first and then call super.setup like setup(OutputStream outputStream, Map<String, Object> parameters) does [2]. [3] is a short code fragment to reproduce.
[1]
@Override
public void setup(OutputStream outputStream) {
this.setup(outputStream);
}
[2]
@Override
public void setup(OutputStream outputStream, Map<String, Object> parameters) {
// create a caching output stream to intercept the result
this.cachingOutputStream = new CachingOutputStream(outputStream);
super.setup(this.cachingOutputStream, parameters);
}
[3]
Pipeline pipeline = new CachingPipeline();
pipeline.addComponent(new StringGenerator("<x></x>"));
pipeline.addComponent(new XMLSerializer());
ByteArrayOutputStream baos = new ByteArrayOutputStream();
pipeline.setup(baos);
pipeline.execute();
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Closed: (COCOON3-23) StackOverflowError on
CachingPipeline.setup(OutputStream)
Posted by "Steven Dolg (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/COCOON3-23?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Steven Dolg closed COCOON3-23.
------------------------------
Resolution: Fixed
> StackOverflowError on CachingPipeline.setup(OutputStream)
> ---------------------------------------------------------
>
> Key: COCOON3-23
> URL: https://issues.apache.org/jira/browse/COCOON3-23
> Project: Cocoon 3
> Issue Type: Bug
> Components: cocoon-pipeline
> Affects Versions: 3.0.0-alpha-1
> Reporter: Alexander Daniel
> Assignee: Steven Dolg
> Fix For: 3.0.0-alpha-2
>
> Attachments: cocoon3-23.patch
>
>
> CachingPipeline.setup(OutputStream) calls itself resulting in a StackOverflowError [1]. I suppose that it should create a CachingOutputStream first and then call super.setup like setup(OutputStream outputStream, Map<String, Object> parameters) does [2]. [3] is a short code fragment to reproduce.
> [1]
> @Override
> public void setup(OutputStream outputStream) {
> this.setup(outputStream);
> }
> [2]
> @Override
> public void setup(OutputStream outputStream, Map<String, Object> parameters) {
> // create a caching output stream to intercept the result
> this.cachingOutputStream = new CachingOutputStream(outputStream);
> super.setup(this.cachingOutputStream, parameters);
> }
> [3]
> Pipeline pipeline = new CachingPipeline();
> pipeline.addComponent(new StringGenerator("<x></x>"));
> pipeline.addComponent(new XMLSerializer());
> ByteArrayOutputStream baos = new ByteArrayOutputStream();
> pipeline.setup(baos);
> pipeline.execute();
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Assigned: (COCOON3-23) StackOverflowError on
CachingPipeline.setup(OutputStream)
Posted by "Steven Dolg (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/COCOON3-23?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Steven Dolg reassigned COCOON3-23:
----------------------------------
Assignee: Steven Dolg (was: Cocoon Developers Team)
> StackOverflowError on CachingPipeline.setup(OutputStream)
> ---------------------------------------------------------
>
> Key: COCOON3-23
> URL: https://issues.apache.org/jira/browse/COCOON3-23
> Project: Cocoon 3
> Issue Type: Bug
> Components: cocoon-pipeline
> Affects Versions: 3.0.0-alpha-1
> Reporter: Alexander Daniel
> Assignee: Steven Dolg
>
> CachingPipeline.setup(OutputStream) calls itself resulting in a StackOverflowError [1]. I suppose that it should create a CachingOutputStream first and then call super.setup like setup(OutputStream outputStream, Map<String, Object> parameters) does [2]. [3] is a short code fragment to reproduce.
> [1]
> @Override
> public void setup(OutputStream outputStream) {
> this.setup(outputStream);
> }
> [2]
> @Override
> public void setup(OutputStream outputStream, Map<String, Object> parameters) {
> // create a caching output stream to intercept the result
> this.cachingOutputStream = new CachingOutputStream(outputStream);
> super.setup(this.cachingOutputStream, parameters);
> }
> [3]
> Pipeline pipeline = new CachingPipeline();
> pipeline.addComponent(new StringGenerator("<x></x>"));
> pipeline.addComponent(new XMLSerializer());
> ByteArrayOutputStream baos = new ByteArrayOutputStream();
> pipeline.setup(baos);
> pipeline.execute();
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (COCOON3-23) StackOverflowError on
CachingPipeline.setup(OutputStream)
Posted by "Steven Dolg (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/COCOON3-23?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Steven Dolg updated COCOON3-23:
-------------------------------
Fix Version/s: 3.0.0-alpha-2
> StackOverflowError on CachingPipeline.setup(OutputStream)
> ---------------------------------------------------------
>
> Key: COCOON3-23
> URL: https://issues.apache.org/jira/browse/COCOON3-23
> Project: Cocoon 3
> Issue Type: Bug
> Components: cocoon-pipeline
> Affects Versions: 3.0.0-alpha-1
> Reporter: Alexander Daniel
> Assignee: Steven Dolg
> Fix For: 3.0.0-alpha-2
>
> Attachments: cocoon3-23.patch
>
>
> CachingPipeline.setup(OutputStream) calls itself resulting in a StackOverflowError [1]. I suppose that it should create a CachingOutputStream first and then call super.setup like setup(OutputStream outputStream, Map<String, Object> parameters) does [2]. [3] is a short code fragment to reproduce.
> [1]
> @Override
> public void setup(OutputStream outputStream) {
> this.setup(outputStream);
> }
> [2]
> @Override
> public void setup(OutputStream outputStream, Map<String, Object> parameters) {
> // create a caching output stream to intercept the result
> this.cachingOutputStream = new CachingOutputStream(outputStream);
> super.setup(this.cachingOutputStream, parameters);
> }
> [3]
> Pipeline pipeline = new CachingPipeline();
> pipeline.addComponent(new StringGenerator("<x></x>"));
> pipeline.addComponent(new XMLSerializer());
> ByteArrayOutputStream baos = new ByteArrayOutputStream();
> pipeline.setup(baos);
> pipeline.execute();
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (COCOON3-23) StackOverflowError on
CachingPipeline.setup(OutputStream)
Posted by "Steven Dolg (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/COCOON3-23?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Steven Dolg updated COCOON3-23:
-------------------------------
Attachment: cocoon3-23.patch
This implementation makes no sense of course.
The method is already correctly implemented in the base class AbstractPipeline and actually there is no need to overwrite it.
I provided a patch, that completely removes the method setup(Outputstream) of the CachingPipeline and adds a unit test to check that calling setup(Outputstream) on a CachingPipeline works correctly.
The patch is just for the case that someone wants to apply it locally. I'll commit this change right away.
Thanks for finding this one...
> StackOverflowError on CachingPipeline.setup(OutputStream)
> ---------------------------------------------------------
>
> Key: COCOON3-23
> URL: https://issues.apache.org/jira/browse/COCOON3-23
> Project: Cocoon 3
> Issue Type: Bug
> Components: cocoon-pipeline
> Affects Versions: 3.0.0-alpha-1
> Reporter: Alexander Daniel
> Assignee: Steven Dolg
> Fix For: 3.0.0-alpha-2
>
> Attachments: cocoon3-23.patch
>
>
> CachingPipeline.setup(OutputStream) calls itself resulting in a StackOverflowError [1]. I suppose that it should create a CachingOutputStream first and then call super.setup like setup(OutputStream outputStream, Map<String, Object> parameters) does [2]. [3] is a short code fragment to reproduce.
> [1]
> @Override
> public void setup(OutputStream outputStream) {
> this.setup(outputStream);
> }
> [2]
> @Override
> public void setup(OutputStream outputStream, Map<String, Object> parameters) {
> // create a caching output stream to intercept the result
> this.cachingOutputStream = new CachingOutputStream(outputStream);
> super.setup(this.cachingOutputStream, parameters);
> }
> [3]
> Pipeline pipeline = new CachingPipeline();
> pipeline.addComponent(new StringGenerator("<x></x>"));
> pipeline.addComponent(new XMLSerializer());
> ByteArrayOutputStream baos = new ByteArrayOutputStream();
> pipeline.setup(baos);
> pipeline.execute();
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
Error:Cannot have multiple DOCTYPE declarations in Coccon sitemap
Posted by "Chirathuru, Nagaraju" <NC...@ciber.com>.
Hi All,
Iam using Cocoon 2.1.10.
I am using entity ° to display degree symbol in my xml. For the same
i am using serializerin my sitemap.xmap as follows
<map:serializer logger="sitemap.serializer.html" mime-type="text/xml"
name="ajaxxml"
pool-max="${html-serializer.pool-max}"
src="org.apache.cocoon.serialization.XMLSerializer">
<doctype-public>-//W3C//DTD XHTML 1.1//EN</doctype-public>
<doctype-system>xhtml11-flat.dtd</doctype-system>
<encoding>UTF-8</encoding>
<omit-xml-declaration>yes</omit-xml-declaration>
</map:serializer>
This particular piece is working like a charm in FireFox. I mean in the
XML is parsing properly. If i try to acces my xml using Internet
Explorer(IE) i am getting the following xml parse error
========================================================================
=============
Cannot have multiple DOCTYPE declarations. Error processing resource
'http://localhost:8080/productpreview/transform/Produc...
<!DOCTYPE p PUBLIC "-//W3C//DTD XHTML 1.1//EN" "xhtml11-flat.dtd">
----------^
========================================================================
==============
Can anyone save my time? :-)
Thanks in Advance
Nagaraju