[
https://issues.apache.org/jira/browse/CAMEL-6152?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Willem Jiang resolved CAMEL-6152.
---------------------------------
Resolution: Fixed
Assignee: Willem Jiang
> StreamProducer does not close streams
> -------------------------------------
>
> Key: CAMEL-6152
> URL: https://issues.apache.org/jira/browse/CAMEL-6152
> Project: Camel
> Issue Type: Bug
> Components: camel-stream
> Affects Versions: 2.10.4
> Reporter: Luz
> Assignee: Willem Jiang
> Priority: Minor
> Fix For: 2.10.5, 2.11.0
>
>
> Steps to reproduce:
> write a big content(whiche exceeds any write buffer) to the route
> .setHeader("stream").constant(new File("test.txt")).to("stream:header");
> The source code does not make sense here:
> org.apache.camel.component.stream.StreamProducer, line 183
> {code}boolean systemStream = outputStream != System.out || outputStream !=
> System.err;{code}
> should be more like:
> {code}boolean systemStream = outputStream == System.out || outputStream ==
> System.err;{code}
> By the way:
> the line 168 is weird too:
> {code}boolean expiredStream = force || headerStream || reachedLimit; //
> evaluation order is important!{code}
> this would (without this bug) always close header streams after every message.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira