You might want to analyze exceptions received by someone else, for example, QA engineers, or investigate a deadlock, or a hang-problem. Unlike the exceptions that you get in the debug mode or when running unit tests, these exceptions do not have links that help you navigate to the corresponding locations in the source code. Moreover, the source code can be scrambled.
With IntelliJ IDEA, you can simply copy an exception or full thread dump, paste it to the Stacktrace Analyzer, explore information, and navigate to the corresponding source code.
- On the main menu, choose .
- In the Analyze Stacktrace dialog box that opens, paste the external stack trace or thread dump into the Put a stacktrace or a complete thread dump here: text area.
- Specify whether you want to have the stacktrace unscrambled. To do that, select the Unscramble stacktrace check box, select the desired unscrambler and log file.
- If the stacktrace text is corrupted (lines are cut or wrapped, or too long, etc.) after processing with some software (for example, a bug tracker or a mail client), click Normalize.
- Click OK. The stacktrace is displayed in the Dump tab of the
Debug tool window.
In case of thread dump, IntelliJ IDEA will present all threads in a readable way and sort them to show first those most probably responsible for the deadlock or hang-problem in question.