设置maven + jetty + eclipse的调试配置 [英] Setting debug configuration for maven+jetty+eclipse

查看:141
本文介绍了设置maven + jetty + eclipse的调试配置的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经在eclipse中创建了一个使用maven的网络应用程序。我正在使用码头来运行应用程序。
我可以使用maven jetty插件来运行应用程序。但是我在调​​试应用程序时遇到困难 -
我已经遵循的设置调试设置的步骤是从以下链接
http://www.clickonchris.com/2010/05/configuring-jetty-maven-and-eclipse-together-with- hot-deploy /

I have created a web app using maven in eclipse. I am using jetty for running the app. I am able to run the app using the maven jetty plugin. But I am facing difficulty while debugging the app - The steps that i have followed to setup debug settings are from the below link http://www.clickonchris.com/2010/05/configuring-jetty-maven-and-eclipse-together-with-hot-deploy/

我可以在端口8080运行应用程序,并且继续监听地址为4000的传输dt_socket。为了调试我已经给出端口4000.但是当我在eclipse中启动调试器时,它给我一个带有以下错误的窗口 -
无法连接到远程VM连接被拒绝
连接拒绝:连接
可以有一个帮助我解决这个问题来调试应用程序。

I can run the app at port 8080 and it keeps on Listening for transport dt_socket at address: 4000. For debugging i have given port 4000. But when i start the debugger in eclipse it gives me a window with following error - "Failed to connect to remote VM. Connection refused. Connection refused: connect" Can some one help me out in resolving this issue for debugging the app.

谢谢!!!

推荐答案

使用 -

export MAVEN_OPTS="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,address=8000,server=y,suspend=n"

然后使用 -

mvn jetty:run

开始远程调试您的端口8000上的fav IDE

Start remote debugging from your fav IDE on port 8000

这篇关于设置maven + jetty + eclipse的调试配置的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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