Use and configure your favorite logger, e.g. log4j 2.
Tilman Am 25.11.2021 um 14:50 schrieb Bernhard Fey:
Hello, We are in the process of integrating PDFBox into our PDF library, so we can use it to merge or encrypt the PDFs we create. This works very well, but we have one remaining issue: By default PDFBox logs to stderr. To change that it seems we have to change the Commons Logging configuration which will affect every usage of PDFBox as well as everything else that uses Commons Logging in the same VM. So, if our library is used by a customer that also uses other libraries that use Commons Logging in the same VM, we need a way to configure the logging of PDFBox without affecting other libraries used by that customer that also use Commons Logging. In the worst case the customer also has PDFBox as a (transitive) dependency. In this case we'd require to configure the logging of our calls to PDFBox independently of any other ones. Additionally it would be nice if we could attribute the log messages from our usage of PDFBox to the specific caller, but we should be able to implement that ourselves, if we can solve the rest. Thanks in advance. Bernhard Fey Product Development Team Martha - - - - - - - - - - - - - - - - RealObjects GmbH Altenkesseler Str. 17/B6 66115 Saarbrücken, Germany Tel +49 (0)681 98579 0 Fax +49 (0)681 98579 29 http://www.realobjects.com<http://www.realobjects.com/> bernhard....@realobjects.com<mailto:bernhard....@realobjects.com> - - - - - - - - - - - - - - - - Commercial Register: Amtsgericht Saarbrücken, HRB 12016 Managing Directors: Michael Jung, Markus Neurohr VAT-ID: DE210373115
--------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@pdfbox.apache.org For additional commands, e-mail: users-h...@pdfbox.apache.org