diff --git a/doc/source/gerrit.rst b/doc/source/gerrit.rst index c41179deef..3f1b602c2a 100644 --- a/doc/source/gerrit.rst +++ b/doc/source/gerrit.rst @@ -567,3 +567,18 @@ must follow that steps: a change, you can delete them with following query:: delete from change_messages where author_id={account-id} and change_id={change-id}; + +Generating a Thread Dump for Debugging +-------------------------------------- + +We removed the Java Melody plugin the wake of the Log4Shell vulnerability. +This removed an easy way to acquire a thread dump but dumping threads is +still possible with java command line tools. You may find yourself wanting +to do this if Gerrit is suffering from poor performance or you are trying to +debug odd Gerrit behavior. + +To run jstack and produce a thread dump do:: + + review02# docker exec -it gerrit-compose_gerrit_1 bash + gerrit@review02:/$ ps -ef | grep java # find the Gerrit java process PID + gerrit@review02:/$ jstack $PID > /tmp/dump.yearmonthday