Skip to content
abhishek8gupta edited this page Sep 8, 2020 · 3 revisions

Welcome to the jta wiki!

Executable scripts are located in bin folder

Usage

./jta
usage: jta
 -d,--details        details of thread dump
 -i,--input <arg>    input file path (mandatory if PID is not specified)
 -o,--output <arg>   output file
 -p,--pid <arg>      jvm process id (mandatory if input file path is not
                     specified)
 -s,--summary        summary of thread dump
 -st,--stacktrace    stacktrace of thread dump

Examples

Summary

./jta -p 21236 -s
Sep 07, 2020 10:50:05 PM com.aa.JVM.JTA main
INFO: command line arguments [-p, 21236, -s]
Sep 07, 2020 10:50:05 PM com.aa.JVM.ThreadDumpFileHandler writeToFile
INFO: writing thread dump to /tmp/jta/1599544205081/td_1599544205128.txt
+--------------------+--------------------+
|               GROUP|               COUNT|
+--------------------+--------------------+
|                GC t|                   8|
|              others|                  19|
+--------------------+--------------------+


+--------------------+--------------------+
|               STATE|               COUNT|
+--------------------+--------------------+
|                  NA|                  10|
|            RUNNABLE|                  12|
|             WAITING|                   4|
|       TIMED_WAITING|                   1|
+--------------------+--------------------+
|               TOTAL|                  27|
+--------------------+--------------------+

Stack trace

╰─➤  ./jta -p 21236 -st
Sep 07, 2020 10:50:08 PM com.aa.JVM.JTA main
INFO: command line arguments [-p, 21236, -st]
Sep 07, 2020 10:50:08 PM com.aa.JVM.ThreadDumpFileHandler writeToFile
INFO: writing thread dump to /tmp/jta/1599544208573/td_1599544208620.txt
+--------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
|                 TID|                                                                                                                                                     STACK TRACE|
+--------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
|  0x00007f99dc1ca000|                                                                                                                            java.lang.Object.wait(Native Method)|
|             WAITING|                                                                                                          . waiting on <0x000000076b3f6348> (a java.lang.Object)|
|                    |                                                                                                                          java.lang.Object.wait(Object.java:502)|
|                    |                                                                                                           sun.awt.AWTAutoShutdown.run(AWTAutoShutdown.java:295)|
|                    |                                                                                                              . locked <0x000000076b3f6348> (a java.lang.Object)|
|                    |                                                                                                                           java.lang.Thread.run(Thread.java:748)|
+--------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
|  0x00007f99dc0f3000|                                                                                                            java.net.PlainSocketImpl.socketAccept(Native Method)|
|            RUNNABLE|                                                                                       java.net.AbstractPlainSocketImpl.accept(AbstractPlainSocketImpl.java:409)|
|                    |                                                                                                         java.net.ServerSocket.implAccept(ServerSocket.java:545)|
|                    |                                                                                                             java.net.ServerSocket.accept(ServerSocket.java:513)|
|                    |                                                                                                          org.h2.server.web.WebServer.listen(WebServer.java:397)|
|                    |                                                                                                                        org.h2.tools.Server.run(Server.java:610)|
|                    |                                                                                                                           java.lang.Thread.run(Thread.java:748)|
+--------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
|  0x00007f99dd022000|                                                                                                            java.net.PlainSocketImpl.socketAccept(Native Method)|
|            RUNNABLE|                                                                                       java.net.AbstractPlainSocketImpl.accept(AbstractPlainSocketImpl.java:409)|
|                    |                                                                                                         java.net.ServerSocket.implAccept(ServerSocket.java:545)|
|                    |                                                                                                             java.net.ServerSocket.accept(ServerSocket.java:513)|
|                    |                                                                                                             org.h2.server.pg.PgServer.listen(PgServer.java:192)|
|                    |                                                                                                                        org.h2.tools.Server.run(Server.java:610)|
|                    |                                                                                                                           java.lang.Thread.run(Thread.java:748)|
+--------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
|  0x00007f99da8e5000|                                                                                                                            java.lang.Object.wait(Native Method)|
|       TIMED_WAITING|                                                                                      sun.java2d.opengl.OGLRenderQueue$QueueFlusher.run(OGLRenderQueue.java:203)|
|                    |                                                                                 . locked <0x000000076b3a0488> (a sun.java2d.opengl.OGLRenderQueue$QueueFlusher)|
+--------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
|  0x00007f99dc02f800|                                                                                                                            java.lang.Object.wait(Native Method)|
|             WAITING|                                                                                              . waiting on <0x000000076ab06b68> (a java.lang.ref.Reference$Lock)|
|                    |                                                                                                                          java.lang.Object.wait(Object.java:502)|
|                    |                                                                                                    java.lang.ref.Reference.tryHandlePending(Reference.java:191)|
|                    |                                                                                                  . locked <0x000000076ab06b68> (a java.lang.ref.Reference$Lock)|
|                    |                                                                                                java.lang.ref.Reference$ReferenceHandler.run(Reference.java:153)|
+--------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
Clone this wiki locally