Ant Tomcat 7 重新加载 FileNotFoundException [英] Ant Tomcat 7 Reload FileNotFoundException

查看:25
本文介绍了Ant Tomcat 7 重新加载 FileNotFoundException的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试从 ant 重新加载 Web 应用程序.但我没有找到错误:

I'm trying to reload web application from ant. but I got error not found:

D:\project\triplelands\ocbcfilesending\src\com.ocbcmcd.monitoring\build.xml:90:
java.io.FileNotFoundException: http://localhost:8080/manager/reload?path=%2Fhello

我也尝试直接访问:http://localhost:8080/manager/reload?path=/你好我从浏览器收到 404 错误代码:

I also try direct access: http://localhost:8080/manager/reload?path=/hello I got 404 error code from my browser:

我的配置是:

我的蚂蚁脚本

<target name="deploy-realod" depends="deploy" description="Reload application in Tomcat">
       <reload url="${tomcat.manager.url}" username="${tomcat.manager.username}" password="${tomcat.manager.password}" path="/${name}" />
</target>

build.properties

appserver.home=C:/appserv/apache6
#for Tomcat 5 use $appserver.home}/server/lib
#for Tomcat 6 use $appserver.home}/lib
appserver.lib=${appserver.home}/lib

deploy.path=${appserver.home}/webapps
tomcat.manager.url=http://localhost:8080/manager
tomcat.manager.username=root
tomcat.manager.password=root

tomcat 用户配置

tomcat user configuration

<user name="root" password="root" roles="admin-gui,manager-gui,tomcat,role1" />

多谢指教

推荐答案

我也遇到了这个问题,在将我一直从事的项目从 Tomcat 6 转移到 Tomcat 7 时.本质上,经理发生了变化URL,它被分成几个,每个的用途取决于你如何与它交互:

I too ran into this issue, while moving a project I've been working on from Tomcat 6 to Tomcat 7. Essentially, there's been a change in the manager URL, where it's been split into several, the use of each depending on how you interface with it:

* /manager/html for the HTML GUI
* /manager/text for the text interface
* /manager/jmxproxy for the JMX proxy
* /manager/status for the status pages

在 ant 的情况下,您想使用/manager/text.所以,您需要编辑 build.properties 文件,如下所示:

In the case of ant, you want to use /manager/text. SO, you'll need to edit your build.properties file, like so:

tomcat.manager.url=http://localhost:8080/manager/text

希望有帮助!

这篇关于Ant Tomcat 7 重新加载 FileNotFoundException的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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