All functionalities of the component log their execution (start, end, warnings, errors, and
received parameters) through the same logging mechanism already used by generated GeneXus
applications, so it integrates with the existing log configuration in each environment (web or
command line) without needing separate configuration.
-
The component does not add its own configuration nor initialize the logging mechanism on its
own: it assumes the host application (the GeneXus application that consumes it) already has its
own log configured, and simply writes into it.
-
If the host application does not have logging configured, the component's log calls have no
effect or error: they silently have no effect, and the rest of the functionality keeps working
normally.
-
Therefore, to see the component's log records, it is enough to enable the log of the GeneXus
application that consumes it, using each generator's own mechanism.
Each public functionality logs the following levels, depending on the situation:
| Level |
What is logged |
| Error |
Any unhandled exception, and business validations that result in an error (for example, non-existent page number), including problem detail. |
| Warning |
Non-fatal conditions already reported as a warning in the operation result (for example, invalid signature page in AddSignature, unresolved fonts in Html2PDF). |
| Info |
Start and successful completion of each functionality. |
| Debug |
Parameters received in the invocation. |
Because they are sensitive information, the following values are never logged at any level,
not even at Debug:
-
The signing certificate password (AddSignature).
-
The user password of the document to protect (ManagePermissions).
-
The full Base64 text content (both in ToBase64 and in
FromBase64); instead, only its length in characters is logged at the Debug
level, as a size reference, since the content is equivalent to the entire document and could
unnecessarily bloat the host application's log storage.
INFO PDFTools.PDFToolsUtils - SetFields started
DEBUG PDFTools.PDFToolsUtils - SetFields parameters: PathSource=C:\Documents\emptyForm.pdf, PathTarget=C:\Documents\filledForm.pdf, Fields.Count=12
INFO PDFTools.PDFToolsUtils - SetFields completed
INFO PDFTools.PDFToolsUtils - SetField started
DEBUG PDFTools.PDFToolsUtils - SetField parameters: PathSource=C:\Documents\emptyForm.pdf, PathTarget=C:\Documents\filledForm.pdf, Field.Key=Email_User, Field.Value=user@mail.com
ERROR PDFTools.PDFToolsUtils - SetField failed: Field 'Email_User' does not exist in the document.