Skip to content

Implement a workaround for common OutOfMemoryError cases #69

@GoogleCodeExporter

Description

@GoogleCodeExporter
There have been increasing number of reports of `OutOfMemoryError`s occurring 
when using Thumbnailator. (Issue 1)

In many cases, this is a result of trying to resize large input images, which 
causes Thumbnailator to read the entire image to the JVM heap memory, resulting 
in the `OutOfMemoryError`s due to the heap being filled up.

A permanent fix to the problem is better achieved by changing the Thumbnailator 
architecture to not require loading the entire image to memory before resizing 
the image, but this will require a comprehensive rewrite, which is planned for 
a later release.

To address the `OutOfMemoryError` in a more timely manner, a temporary 
workaround should be possible by examining the image metadata to find out the 
image size, and accordingly apply a subsampling on the read operation to reduce 
the amount of memory used when reading the image.

Original issue reported on code.google.com by coobird...@gmail.com on 4 May 2014 at 5:36

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions