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

Narayanan Arunachalam commented on CXF-3889:
--------------------------------------------

How about not writing the payload to the log if the content type is of type 
"application/octet-stream". Right now first 100k is written to the log.
                
> OOM when uploading files greater than 2GB
> -----------------------------------------
>
>                 Key: CXF-3889
>                 URL: https://issues.apache.org/jira/browse/CXF-3889
>             Project: CXF
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 2.4.3
>         Environment: All environments
>            Reporter: Narayanan Arunachalam
>            Assignee: Daniel Kulp
>             Fix For: 2.5
>
>   Original Estimate: 24h
>  Remaining Estimate: 24h
>
> The totalLength field in org.apache.cxf.io.CachedOutputStream is declared as 
> a int field, so when a file greater than 2GB is uploaded for a PUT operation, 
> OOM is thrown.
> When the file size is over 2GB the condition 'totalLength < limit' becomes 
> true when it should not.
>  public void writeCacheTo(StringBuilder out, String charsetName, int limit) 
> throws IOException {
> 294        flush();
> 295        if (totalLength < limit
> 296            || limit == -1) {
> 297            writeCacheTo(out);
> 298            return;
> 299        }

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to