IntelliJ IDEA 2020.2 Help


Use Logs tab in the Run/Debug Configuration dialogs to configure the way log files, generated by an application or server, are displayed in the console.

If your application or server generates log files, the default entries will be automatically added to the log file list in the Run/Debug Configuration dialog.

Configure options for logs

  1. In the Run/Debug Configuration dialog, click the Logs tab. The Edit Log Files Aliases table displays the list of log files.

  2. Click the Add button the Add button. The Edit Log Files Aliases Dialog opens.

    Opening the Edit Log Files dialog

  3. In the Alias field, type the alias for the log entry.

  4. In the Log File Location field, specify the log files to display during running or debugging. You can specify the files by using two options:

    • Specify the full path to a specific file. Type the path manually or click the Browse button the Browse button and select the file.

    • Specify the base directory and add an Ant pattern that defines the fileset to be displayed.

  5. (Optional) Select the Show All Files Coverable by Pattern checkbox to open a separate tab for each log file that matches the specified Ant pattern.

  6. Click OK.

  7. In the Edit Log Files Aliases table, select the Is Active checkbox to have the log entries displayed in the corresponding tabs in the Run tool window or Debug tool window.

  8. To skip the previous content of the selected log, select the checkbox in the Skip Content column.

If you are using third-party logging tools, you might want to make the message's output that mimics a standard linkage to the source code as for stack trace line (at <fully-qualified-class-name>.<method-name>(<file-name>:<line-number>)). For that, add specific Conversion Pattern to your log.xml configuration file.

For example, in a log4j Conversion Pattern this would be <param name="ConversionPattern" value="%-5p - [%-80m] - at %c.%M(%F:%L)%n"/>.

Last modified: 19 August 2020