无法在eclipse中调试ant脚本

时间:2011-12-20 14:12:37

标签: eclipse debugging ant

当我尝试通过eclipse调试ant脚本时,它会在调试点进行终止!!!!

以下是错误日志的详细信息

消息:从Ant UI记录错误: 异常堆栈跟踪:

java.net.SocketTimeoutException: Accept timed out
at java.net.PlainSocketImpl.socketAccept(Native Method)
at java.net.PlainSocketImpl.accept(PlainSocketImpl.java:384)
at java.net.ServerSocket.implAccept(ServerSocket.java:453)
at java.net.ServerSocket.accept(ServerSocket.java:421)
at org.eclipse.ant.internal.launching.launchConfigurations.RemoteAntBuildListener$ServerConnection.run(RemoteAntBuildListener.java:89)

会话数据:

eclipse.buildId=M20110210-1200
java.version=1.6.0_10
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=en_GB
Framework arguments:  -product org.eclipse.epp.package.jee.product
Command-line arguments:  -os win32 -ws win32 -arch x86 -product org.eclipse.epp.package.jee.product

1 个答案:

答案 0 :(得分:0)

我通常通过从Eclipse外部运行并远程连接来调试Ant。我将我的ANT_OPTS设置为包含

-Xdebug -Xrunjdwp:transport=dt_socket,address=8000,server=y,suspend=y

然后我只是将Eclipse连接到指定的端口。