使用 jboss 进行 Eclipse 远程调试 [英] Eclipse Remote debugging with jboss

查看:30
本文介绍了使用 jboss 进行 Eclipse 远程调试的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在 Eclipse 中使用 JBOSS 服务器 4.x 版本配置远程调试?

How can I configure remote debugging in Eclipse with JBOSS server 4.x version?

到目前为止,

Step1:我修改了 run.confg 文件.通过取消注释以下行.用于远程套接字调试的 JPDA 设置示例:

Step1: I have modified the run.confg file. By uncommenting the below line. Sample JPDA settings for remote socket debugging:

JAVA_OPTS="$JAVA_OPTS -Xrunjdwp:transport=dt_socket,address=8787,server=y,suspend=n"

Step2 :然后我在调试配置中配置了 Eclipse.它说:

Step2 : Then I configured Eclipse in debug configurations. It's saying:

Failed to connect to remote VM. Connection refused.

推荐答案

您所问的不是 Java EE 或 JBoss 4.x 特有的 - 如果您在以下情况下指定了远程调试运行时参数,您可以调试任何 Java 进程启动JVM.

What you are asking is not specific to either Java EE or JBoss 4.x - you can debug any Java process in case you specified the remote debugging runtime parameters when starting the JVM.

在您的设置中缺少 -Xdebug 参数,因此您的行将是:

In your setting the -Xdebug parameter is missing, so your line would be:

JAVA_OPTS="$JAVA_OPTS -Xdebug -Xrunjdwp:transport=dt_socket,address=8787,server=y,suspend=n"

现在它应该能够连接,以防您使用正确的主机和指定的端口 8787.如果它仍然无法工作,很可能是防火墙问题阻止了端口.

Now it should be able to connect, in case you are using the correct host and your specified port 8787. In case it's still not working, it's most likely a firewall issue blocking the port.

这篇关于使用 jboss 进行 Eclipse 远程调试的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆