Since most Java applications and packages already integrate with Log4j2 for logging, we recommend adding the Loupe Appender for Log4j2 as your first step to capturing log data with Loupe. Once that's done, you can choose to either do all of your logging to Log4j2 or go direct to Loupe's API. If you know you are using another supported logging framework we recommend adding the relevant appenders for them as well. For a list of supported frameworks, see Developer's Guide - Java - Using Loupe with other Logging Frameworks.
The main advantage of Loupe's API comes when logging exceptions in exception handlers. The specialized recordException methods and options on the error and critical logging methods which let you easily tell Loupe what class & method to attribute the exception to. For more information, see Developer's Guide - Java - Logging Directly to Loupe.