You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pdfbox.apache.org by "John Hewson (JIRA)" <ji...@apache.org> on 2014/10/14 06:44:34 UTC

[jira] [Comment Edited] (PDFBOX-1462) Use file backed buffer for FlateFilter?

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

John Hewson edited comment on PDFBOX-1462 at 10/14/14 4:44 AM:
---------------------------------------------------------------

I think we should close this: large flate-filtered streams are usually images, and an image will need to be loaded into a BufferedImage once it is decompressed, so we will just get OOM when trying to load the image, instead of when decompressing it, which won't be of any help.


was (Author: jahewson):
I think we should close this - large flate-filtered streams are usually images, and an image will need to be loaded into a BufferedImage once it is decompressed, so we will just get OOM when trying to load the image, instead of when decompressing it, which won't be of any help.

> Use file backed buffer for FlateFilter?
> ---------------------------------------
>
>                 Key: PDFBOX-1462
>                 URL: https://issues.apache.org/jira/browse/PDFBOX-1462
>             Project: PDFBox
>          Issue Type: New Feature
>          Components: Parsing
>    Affects Versions: 1.7.1, 2.0.0
>            Reporter: Edoardo Causarano
>             Fix For: 2.0.0
>
>
> org.apache.pdfbox.filter.FlateFilter#decompress can cause OOM (depending on the size of the document and configured heap of course.) Consider using something like http://docs.guava-libraries.googlecode.com/git/javadoc/com/google/common/io/FileBackedOutputStream.html to constraint memory pressure.
> Best,
> Edoardo



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)