[ 
https://issues.apache.org/jira/browse/CAMEL-20965?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Bartosz Popiela updated CAMEL-20965:
------------------------------------
    Affects Version/s: 4.6.0
                       4.4.3

> InputStreamCache is not thread-safe
> -----------------------------------
>
>                 Key: CAMEL-20965
>                 URL: https://issues.apache.org/jira/browse/CAMEL-20965
>             Project: Camel
>          Issue Type: Bug
>          Components: camel-core
>    Affects Versions: 4.4.3, 4.6.0
>            Reporter: Bartosz Popiela
>            Priority: Major
>
> InputStreamCache is reset after each step 
> (org.apache.camel.impl.engine.CamelInternalProcessor.StreamCachingAdvice#after),
>  and if there are two threads processing the same InputStreamCache (e.g. 
> Seda), there may be a case where one thread invokes InputStreamCache#reset 
> (org.apache.camel.support.MessageHelper#resetStreamCache) while another 
> thread converts this InputStreamCache to String 
> (org.apache.camel.util.IOHelper#toString(java.io.BufferedReader, long). It 
> leads to java.io.ByteArrayInputStream#pos being reset and the target String 
> having duplicate entries.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to