pdfbox-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "John Hewson (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (PDFBOX-3131) Reduce amount of intermediate data and objects to reduce memory footprint/complexity
Date Tue, 01 Dec 2015 20:12:11 GMT

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

John Hewson commented on PDFBOX-3131:

I was using the getData() API for an internal project. I've replaced its implementation with
a new ByteSource class which allows a deferred byte[] source to be passed to CFFParser so
that it can re-read the original byte[] source on demand, instead of keeping it in memory.

I'd have done something simpler but CFF fonts may be nested inside both TTCs and OTFs, so
having a getBytes() API is really useful (at least to me).

> Reduce amount of intermediate data and objects to reduce memory footprint/complexity
> ------------------------------------------------------------------------------------
>                 Key: PDFBOX-3131
>                 URL: https://issues.apache.org/jira/browse/PDFBOX-3131
>             Project: PDFBox
>          Issue Type: Improvement
>          Components: FontBox
>    Affects Versions: 2.0.0
>            Reporter: Andreas Lehmkühler
>            Assignee: Andreas Lehmkühler
>             Fix For: 2.0.0
> The CFFParser holds a lot of intermediate data and produces a lot of objects to do so.
The idea is to reduce the amount of such objects and dat ot reduce the memory footprint and
the complexity.
> - the class IndexData holds intermediate data creates byte array everytime when getBytes
is called. I'm going to replace the class with a simple list to reduce the memory footprint
and the complexity
> - remove unused members of private classes
> - create a list of strings instead of a list of byte arrays which is used to create those

This message was sent by Atlassian JIRA

To unsubscribe, e-mail: dev-unsubscribe@pdfbox.apache.org
For additional commands, e-mail: dev-help@pdfbox.apache.org

View raw message