[jira] [Updated] (PDFBOX-4774) Add AWS Lambda support to FontFileFinder

2020-02-13 Thread Tilman Hausherr (Jira)


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

Tilman Hausherr updated PDFBOX-4774:

Component/s: FontBox

> Add AWS Lambda support to FontFileFinder
> 
>
> Key: PDFBOX-4774
> URL: https://issues.apache.org/jira/browse/PDFBOX-4774
> Project: PDFBox
>  Issue Type: Improvement
>  Components: FontBox
>Affects Versions: 2.0.18
>Reporter: Ben Manes
>Priority: Major
> Attachments: fixed_page.jpg, original.pdf, rendered_page.jpg
>
>
> The font directory finder is hard coded based on the operating system and is 
> not directly extensible. Instead, if I understand correctly, the fonts have 
> to be explicitly declared in a {{PDFBox_External_Fonts.properties}} file.
> AWS Lambda includes only minimal fonts in its linux distribution. For some 
> documents this is too limiting, so on our EC2 instances we install 
> {{msttcorefonts}}, {{ttf-aenigma}}, and {{fonts-tuffy}}. These go into 
> {{/usr/share/fonts}} which the {{UnixFontDirFinder}} inspects.
> AWS Lambda will unzip the distribution into {{/var/task}}, will unzip layers 
> into {{/opt}} only allows tasks to otherwise write to {{/tmp}}. The common 
> recommendation for fonts is to include them in the lambda, reference them at 
> {{/var/task/fonts}}, and set {{FONTCONFIG_PATH}} to that path for headless 
> tasks like Chrome's print-to-pdf.
> Since PdfBox does not use font-config this solution does not work. Ideally it 
> would be nice if one could specify a custom {{FontDirFinder}} or add custom 
> directories (such as by a system property if not API). Alternatively, PdfBox 
> could include reasonable default locations if the environmental variable 
> {{LAMBDA_TASK_ROOT}} is set.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

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



[jira] [Updated] (PDFBOX-4774) Add AWS Lambda support to FontFileFinder

2020-02-13 Thread Tilman Hausherr (Jira)


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

Tilman Hausherr updated PDFBOX-4774:

Affects Version/s: 2.0.18

> Add AWS Lambda support to FontFileFinder
> 
>
> Key: PDFBOX-4774
> URL: https://issues.apache.org/jira/browse/PDFBOX-4774
> Project: PDFBox
>  Issue Type: Improvement
>Affects Versions: 2.0.18
>Reporter: Ben Manes
>Priority: Major
> Attachments: fixed_page.jpg, original.pdf, rendered_page.jpg
>
>
> The font directory finder is hard coded based on the operating system and is 
> not directly extensible. Instead, if I understand correctly, the fonts have 
> to be explicitly declared in a {{PDFBox_External_Fonts.properties}} file.
> AWS Lambda includes only minimal fonts in its linux distribution. For some 
> documents this is too limiting, so on our EC2 instances we install 
> {{msttcorefonts}}, {{ttf-aenigma}}, and {{fonts-tuffy}}. These go into 
> {{/usr/share/fonts}} which the {{UnixFontDirFinder}} inspects.
> AWS Lambda will unzip the distribution into {{/var/task}}, will unzip layers 
> into {{/opt}} only allows tasks to otherwise write to {{/tmp}}. The common 
> recommendation for fonts is to include them in the lambda, reference them at 
> {{/var/task/fonts}}, and set {{FONTCONFIG_PATH}} to that path for headless 
> tasks like Chrome's print-to-pdf.
> Since PdfBox does not use font-config this solution does not work. Ideally it 
> would be nice if one could specify a custom {{FontDirFinder}} or add custom 
> directories (such as by a system property if not API). Alternatively, PdfBox 
> could include reasonable default locations if the environmental variable 
> {{LAMBDA_TASK_ROOT}} is set.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

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



[jira] [Updated] (PDFBOX-4774) Add AWS Lambda support to FontFileFinder

2020-02-13 Thread Ben Manes (Jira)


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

Ben Manes updated PDFBOX-4774:
--
Attachment: fixed_page.jpg

> Add AWS Lambda support to FontFileFinder
> 
>
> Key: PDFBOX-4774
> URL: https://issues.apache.org/jira/browse/PDFBOX-4774
> Project: PDFBox
>  Issue Type: Improvement
>Reporter: Ben Manes
>Priority: Major
> Attachments: fixed_page.jpg, original.pdf, rendered_page.jpg
>
>
> The font directory finder is hard coded based on the operating system and is 
> not directly extensible. Instead, if I understand correctly, the fonts have 
> to be explicitly declared in a {{PDFBox_External_Fonts.properties}} file.
> AWS Lambda includes only minimal fonts in its linux distribution. For some 
> documents this is too limiting, so on our EC2 instances we install 
> {{msttcorefonts}}, {{ttf-aenigma}}, and {{fonts-tuffy}}. These go into 
> {{/usr/share/fonts}} which the {{UnixFontDirFinder}} inspects.
> AWS Lambda will unzip the distribution into {{/var/task}}, will unzip layers 
> into {{/opt}} only allows tasks to otherwise write to {{/tmp}}. The common 
> recommendation for fonts is to include them in the lambda, reference them at 
> {{/var/task/fonts}}, and set {{FONTCONFIG_PATH}} to that path for headless 
> tasks like Chrome's print-to-pdf.
> Since PdfBox does not use font-config this solution does not work. Ideally it 
> would be nice if one could specify a custom {{FontDirFinder}} or add custom 
> directories (such as by a system property if not API). Alternatively, PdfBox 
> could include reasonable default locations if the environmental variable 
> {{LAMBDA_TASK_ROOT}} is set.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

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