You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@camel.apache.org by "Claus Ibsen (JIRA)" <ji...@apache.org> on 2011/03/27 12:38:05 UTC

[jira] [Commented] (CAMEL-3791) Camel should reset the stream cache if the useOriginalInMessage option is true

    [ https://issues.apache.org/jira/browse/CAMEL-3791?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13011771#comment-13011771 ] 

Claus Ibsen commented on CAMEL-3791:
------------------------------------

Have you committed this? If so mark this ticket as resolved.

> Camel should reset the stream cache if the useOriginalInMessage option is true
> ------------------------------------------------------------------------------
>
>                 Key: CAMEL-3791
>                 URL: https://issues.apache.org/jira/browse/CAMEL-3791
>             Project: Camel
>          Issue Type: Bug
>          Components: camel-core
>    Affects Versions: 2.5.0, 2.6.0, 2.7.0
>            Reporter: Willem Jiang
>            Assignee: Willem Jiang
>             Fix For: 2.8.0
>
>
> {code}
> --- src/main/java/org/apache/camel/processor/RedeliveryErrorHandler.java	(revision 1083672)
> +++ src/main/java/org/apache/camel/processor/RedeliveryErrorHandler.java	(working copy)
> @@ -591,18 +591,23 @@
>          // is the a failure processor to process the Exchange
>          if (processor != null) {
>  
> -            // reset cached streams so they can be read again
> -            MessageHelper.resetStreamCache(exchange.getIn());
> -
>              // prepare original IN body if it should be moved instead of current body
>              if (data.useOriginalInMessage) {
>                  if (log.isTraceEnabled()) {
>                      log.trace("Using the original IN message instead of current");
>                  }
>                  Message original = exchange.getUnitOfWork().getOriginalInMessage();
>                  exchange.setIn(original);
>              }
> +            // reset cached streams so they can be read again
> +            MessageHelper.resetStreamCache(exchange.getIn());
> {code}

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira