arthas icon indicating copy to clipboard operation
arthas copied to clipboard

arthas.properties的配置对于arthas-client不生效

Open KerwinAusten opened this issue 3 years ago • 1 comments

  • [x] 我已经在 issues 里搜索,没有重复的issue。

环境信息

  • arthas-boot.jar : 3.6.7
  • 操作系统版本: windows 10

重现问题的步骤

参考文档配置了arthas.properties,其中修改了target-ip参数。 然后通过java -jar arthas-boot.jar 命令启动,已确认配置可以生效(其他机器可以远程连接到本机的arthas),但是启动的时候arthas-client还是会去连接127.0.0.1,导致本机的控制台出不来。

查看源码发现arthas.properties加载的逻辑是在core模块的com.taobao.arthas.core.server.ArthasBootstrap,而arthas-client是通过boot模块的com.taobao.arthas.boot.Bootstrap启动的,client和core是并行的关系。所以client无法获取到arthas.properties的值而只能通过命令行去配置

期望的结果

arthas.properties是否可以在boot模块加载,从而用于整个系统呢

KerwinAusten avatar Feb 13 '23 02:02 KerwinAusten

这样子会有点混乱,并且 as.sh 不好支持。 主要还是少量参数可以从命令行传递,主要配置在 arthas.properties。

hengyunabc avatar Apr 28 '23 09:04 hengyunabc