You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pdfbox.apache.org by "Jorge moraleda (Jira)" <ji...@apache.org> on 2024/04/23 19:31:00 UTC
[jira] [Updated] (PDFBOX-5807) JPEGFactory. Reduce logging severity when no image metadata is present
[ https://issues.apache.org/jira/browse/PDFBOX-5807?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Jorge moraleda updated PDFBOX-5807:
-----------------------------------
Description:
Currently when the image size cannot retrieved from metadata we issue:
`LOG.warn("No image metadata, will decode image and use raster size");` and
`LOG.warn("Error reading image metadata, will decode image and use raster size", ex);` both at the warning level, but since these are recoverable errors (by using the raster size, as the messages indicate, I think their priority should be reduced to `info` or `debug`. This is particularly important in the second message since we actually go ahead and print the full stack trace, which heavily pollutes log files.
I use JPEGFactory inside a server side application without control from which files the user uploads, and it is irksome to get all those irelevant stack traces.
Thank you.
> JPEGFactory. Reduce logging severity when no image metadata is present
> ----------------------------------------------------------------------
>
> Key: PDFBOX-5807
> URL: https://issues.apache.org/jira/browse/PDFBOX-5807
> Project: PDFBox
> Issue Type: Improvement
> Components: FontBox
> Affects Versions: 2.0.31, 3.0.2 PDFBox
> Reporter: Jorge moraleda
> Priority: Minor
>
> Currently when the image size cannot retrieved from metadata we issue:
> `LOG.warn("No image metadata, will decode image and use raster size");` and
> `LOG.warn("Error reading image metadata, will decode image and use raster size", ex);` both at the warning level, but since these are recoverable errors (by using the raster size, as the messages indicate, I think their priority should be reduced to `info` or `debug`. This is particularly important in the second message since we actually go ahead and print the full stack trace, which heavily pollutes log files.
> I use JPEGFactory inside a server side application without control from which files the user uploads, and it is irksome to get all those irelevant stack traces.
> Thank you.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@pdfbox.apache.org
For additional commands, e-mail: dev-help@pdfbox.apache.org