-
Notifications
You must be signed in to change notification settings - Fork 23
CommandCodec 中 agentClassLoader 无法注入? #10
New issue
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
Comments
感谢反馈,这里处理有点问题,可以提个pr修复一下问题 |
请问下这里 TCCL 获取的 classLoader 为什么是空呢? |
你的服务怎么启动的?获取到空表示取到的是bootClassLoader |
我是先启动springboot服务,然后开启server端,没有改端口,只指定了pid,然后开启客户端连接pid。 |
如果可以,希望能上传一个可以复现的场景,我来看一下具体的情况,没有复现不好进一步做排查 |
当时问题:
按照提示流程正常启动,出现了类加载的问题。打印出来这里报错了
Class<?> agentCls = Thread.currentThread().getContextClassLoader().loadClass("io.javadebug.agent.Agent");
Agent 是由系统加载器进行加载么?
解决方案:
CommandCodec 里注入 AgentClassLoader直接改为:agentClassLoader = CommandCodec.class.getClassLoader();
使用TCCL获取classloader一直为空,导致加载类失败。
The text was updated successfully, but these errors were encountered: