自动将调试器附加到Eclipse中的新Java子进程 [英] automatically attach a debugger to a new Java sub-process in Eclipse
问题描述
我被告知(虽然没有看到)VisualAge曾经能够做到这一点 - 当您尝试创建新的JVM时,会注意到,而是创建一个调试模式并附加到它。 Nifty。
提供通常的JVM标志,以指示您要调试进程(依赖供应商),具有特定端口,并且有一个Eclipse调试启动配置来使用该端口。
较新的日食可以做相反的技巧,调试器在端口上等待新的JVM附加准备。这可能是你要找的?
I hava a Java process that spawns a new JVM using ProcessBuilder etc. While debugging this, is it possible to have Eclipse attach a debugger to the new sub-process? Even better, is there any plugin that will do this automatically when it notices the new child process?
I'm told (though haven't seen) that VisualAge used to be able to do this - it would notice when you tried to create a new JVM, and instead create a debug-mode one and attach to it. Nifty.
Provide the usual JVM flags to indicate that you want to debug the process (vendor dependant), with a specific port, and have an Eclipse debug launch configuration to use that port.
Newer Eclipses can do the reverse trick, where the debugger waits on the port for the new JVM to attach when ready. That might be what you are looking for?
这篇关于自动将调试器附加到Eclipse中的新Java子进程的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!