初学netty碰到一个bug,想进入源码中去调试,但在配置source attachment的情况下只能看到源码,可以添加断点,但是运行时代码没有中断。

在网上搜了好久感觉都说得有点不清不楚,综合多个答案,终于被我找到方法,特此分享给大家。

1、下载jar包的源码包

使用eclipse debug jar包中的源码

2、放入项目的libs

使用eclipse debug jar包中的源码

3、在代码中随便断个点进入 Debug模式

使用eclipse debug jar包中的源码

4、右键

使用eclipse debug jar包中的源码

5、进入

使用eclipse debug jar包中的源码

 

6、Archive 在工作空间内查找,External Archive 在其他目录查找,两个都可以。

使用eclipse debug jar包中的源码

7、选择对应的jar包

使用eclipse debug jar包中的源码

8、测试

使用eclipse debug jar包中的源码

以后就可以在源码中愉快的断点了。。。。

相关文章:

  • 2021-06-13
  • 2021-07-25
  • 2022-12-23
  • 2021-09-04
  • 2021-07-06
  • 2022-01-08
  • 2021-12-04
  • 2021-04-28
猜你喜欢
  • 2021-12-05
  • 2022-12-23
  • 2021-09-19
  • 2021-12-19
  • 2021-04-04
  • 2021-10-26
相关资源
相似解决方案