Ben Chuanlong Du's Blog

It is never too late to learn.

Debugging Tools for Java

Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!

arthas

arthas

JDK commands

Thread dump: jstack jvm_pid > (use -F if not responding)

Memory dump: jmap -dump:live,format=b,file=.hprof jvm_pid

Heap status: jmap -heap jvm_pid

GC status: jstat …

Debug Code in JupyterLab Notebooks

Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!

Use the %debug Magic

The easiest way to debug a Jupyter notebook is to use the %debug magic command. Whenever you encounter an error or exception, just open a new notebook …