从Eclipse Indigo远程调试JBoss AS 7.1 [英] Remote debug JBoss AS 7.1 from Eclipse Indigo
问题描述
我阅读了有关该主题的一些指南,并执行了以下步骤。
I read some guides on the subject and made the following steps.
http://oreilly.com/pub/a/java/archive/eclipse-jboss-remote-debug.html?page = 8
https://community.jboss.org/thread/177687
在Eclipse中进行JBoss调试
指南有一些区别,但总体上是相似的。
The guides have some distinctions but on the whole they are similar.
我所做的步骤。
- 我单击Eclipse中的 在服务器上运行-> JBoss AS 7.1 ,编译并部署了我的Web项目,并将其部署在JBoss AS
7.1上。 - 我在Eclipse中停止了JBoss AS。
-
我没有注释该行
- I compiled and deployed my web project and deployed it on JBoss AS 7.1 by clicking Run on Server -> JBoss AS 7.1 in Eclipse.
- I stopped JBoss AS in Eclipse.
I uncommented the line
JAVA_OPTS = $ JAVA_OPTS -Xrunjdwp:transport = dt_socket,address = 8787,server = y,suspend = n
在 $ JBOSS_HOME / bin / standalone.conf
文件
- 我执行了
$ JBOSS_HOME / bin / standalone.sh
- 我在浏览器中更新了页面localhost:8080 / MyProject /,并且
有效 - 我执行了 Debug-> Debug Configurations strong>在Eclipse中,然后我创建了
a新配置,以localhost作为主机,8787作为
端口,而MyProject作为项目名称。 - 我按下了
- I executed
$JBOSS_HOME/bin/standalone.sh
- I updated the page localhost:8080/MyProject/ in the browser and it worked
- I executed Debug -> Debug Configurations in Eclipse, then I created a new configuration with the localhost as the host, 8787 as the port, and MyProject as the project name.
- I pressed the Debug button in Eclipse.
到达断点时,我什么也没发生。
When I reach a breakpoint I added, nothing happens.
我希望Eclipse会像在一个简单的Java应用程序项目中那样在断点处停止。我做错了什么?
I expected that Eclipse would stop at the breakpoint as it does in a simple Java application project. What did I do wrong?
Eclipse版本:Indigo。
Eclipse version: Indigo.
Java。
java version "1.6.0_43"
Java(TM) SE Runtime Environment (build 1.6.0_43-b01)
Java HotSpot(TM) 64-Bit Server VM (build 20.14-b01, mixed mode)
编辑# 1。
- Window-> Preferences-> Java-> Installed JRE's
- 编辑正在使用的JRE
-
编辑默认VM参数行
- Window -> Preferences -> Java -> Installed JRE's
- Edit JRE being used
Edit 'Default VM Arguments' line
-XX:+ UseParallelGC
-XX:+UseParallelGC
它没有帮助。
推荐答案
代替在 standalone.conf 中进行更改,而在 standalone.conf.bat中进行更改。
Instead of making the changes in "standalone.conf", make the change in "standalone.conf.bat" .
从 rem set行中删除 rem 。JAVA_OPTS=%JAVA_OPTS%-Xrunjdwp:transport = dt_socket,地址= 8787,server = y,suspend = n。
Remove the rem from the line "rem set "JAVA_OPTS=%JAVA_OPTS% -Xrunjdwp:transport=dt_socket,address=8787,server=y,suspend=n"" .
这对我有用。
这篇关于从Eclipse Indigo远程调试JBoss AS 7.1的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!