We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
arthas-boot.jar
as.sh
arthas-boot
package com.mvp.service; import java.util.concurrent.TimeUnit; public class HqlParseMain { public static void main(String[] args) throws InterruptedException { String input ="SELECT "; HqlParseMain parseTest = new HqlParseMain(); parseTest.doParse2(input); } private void doParse2(String input) throws InterruptedException { while (true) { System.out.println(input); sleep(); } } private void sleep() throws InterruptedException { TimeUnit.SECONDS.sleep(2); } }
输入trace命令,查看结果一直没有出现: [arthas@17951]$ trace com.mvp.service.HqlParseMain doParse2 Press Q or Ctrl+C to abort. Affect(class count: 1 , method count: 1) cost in 98 ms, listenerId: 1 一直等待不会出现调用结果的。
package com.mvp.service; import java.util.concurrent.TimeUnit; public class HqlParseMain { public static void main(String[] args) throws InterruptedException { String input ="SELECT "; HqlParseMain parseTest = new HqlParseMain(); while (true) { parseTest.doParse2(input); parseTest.sleep(); } } private void doParse2(String input) throws InterruptedException { for (int i = 0; i < 100; i++) { System.out.println(input); } } private void sleep() throws InterruptedException { TimeUnit.SECONDS.sleep(2); } }
输入trace命令就会正常出现结果:
[arthas@17842]$ trace com.mvp.service.HqlParseMain doParse2 Press Q or Ctrl+C to abort. Affect(class count: 1 , method count: 1) cost in 95 ms, listenerId: 1 ---ts=2024-02-29 17:36:43;thread_name=main;id=1;is_daemon=false;priority=5;TCCL=sun.misc.Launcher$AppClassLoader@18b4aac2 ---[2.426401ms] com.mvp.service.HqlParseMain:doParse2()
---ts=2024-02-29 17:36:43;thread_name=main;id=1;is_daemon=false;priority=5;TCCL=sun.misc.Launcher$AppClassLoader@18b4aac2
第1步的方法也可以查看到调用信息。
参考上文的结果描述。
在日志没有发现异常,感觉问题应该跟java.lang.Thread有关。
The text was updated successfully, but these errors were encountered:
trace命令执行之后,没有出现doParse2方法的调用,所以就看不到调用信息
Sorry, something went wrong.
No branches or pull requests
环境信息
arthas-boot.jar
或者as.sh
的版本: 3.7.2arthas-boot
的版本: 3.7.2重现问题的步骤
输入trace命令就会正常出现结果:
期望的结果
第1步的方法也可以查看到调用信息。
实际运行的结果
参考上文的结果描述。
The text was updated successfully, but these errors were encountered: