我在配置Eclipse EE
运行 Tomcat 6 时遇到问题(我的公司尚未迁移到 Tomcat 7)。我试图按照这些说明进行操作。我进入底部面板中的服务器选项卡,点击New->Server
,然后选择Apache->Tomcat 6
。然后我经历了以下一系列屏幕:
终于到了报错信息:
这是我的 Tomcat conf dir ( C:\home\SFTWR\tomcat6\conf
) 的内容:
catalina.policy
catalina.properties
context.xml
logging.properties
server.xml
web.xml
wrapper.properties
有什么建议可能是错的吗?它在独立运行时运行良好,我可以从 Eclipse 部署应用程序,但我希望能够在 Eclipse 中运行以进行调试。
更新:
尽管出现错误消息,但我注意到服务器确实已注册,但是无法正常工作——当我尝试点击“开始”时,我收到一个错误弹出窗口,列出了两个问题:
发布到本地主机 (详细信息:无法发布到服务器,因为它缺少运行时环境。)
启动本地主机 (详细信息: 在“启动本地主机”期间发生内部错误。java.lang.NullPointerException)
详细的异常堆栈跟踪如下:
org.eclipse.core.runtime.CoreException: Could not load the Tomcat server configuration at \Servers\localhost-config. The configuration may be corrupt or incomplete.
at org.eclipse.jst.server.tomcat.core.internal.Tomcat60Configuration.load(Tomcat60Configuration.java:313)
at org.eclipse.jst.server.tomcat.core.internal.TomcatServer.getTomcatConfiguration(TomcatServer.java:124)
at org.eclipse.jst.server.tomcat.core.internal.TomcatServerBehaviour.getTomcatConfiguration(TomcatServerBehaviour.java:80)
at org.eclipse.jst.server.tomcat.core.internal.TomcatServerBehaviour.setupLaunch(TomcatServerBehaviour.java:496)
at org.eclipse.jst.server.tomcat.core.internal.TomcatLaunchConfigurationDelegate.launch(TomcatLaunchConfigurationDelegate.java:96)
at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:854)
at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:703)
at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:696)
at org.eclipse.wst.server.core.internal.Server.startImpl2(Server.java:3402)
at org.eclipse.wst.server.core.internal.Server.startImpl(Server.java:3340)
at org.eclipse.wst.server.core.internal.Server$StartJob.run(Server.java:363)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)