3

错误的原因可能是什么:Error 404: SRVE0190E: File not found: /SimpleServletPath

我在 websphere 自由配置文件服务器中进行部署。

我无法访问我的管理控制台登录页面

我可以在我的 websphere liberty 配置文件服务器上访问我的欢迎页面,但在创建 servlet 后无法访问。这时候就会出现上述 404 错误。

网上也有类似的帖子建议改com.ibm.ws.webcontainer.invokefilterscompatibility=true。我找不到如何设置此参数,因为我无法访问 websphere 管理控制台登录。

我通过eclipse市场安装了websphere。

    <?xml version="1.0" encoding="UTF-8"?>
    <web-app id="WebApp_ID" version="3.0" xmlns="http://java.sun.com/xml/ns/javaee" 
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
    xsi:schemaLocation="http://java.sun.com/xml/ns/javaee 
    http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd">
<display-name>ServletExplore</display-name>
<welcome-file-list>
    <welcome-file>index.html</welcome-file>

</welcome-file-list>
    </web-app
4

1 回答 1

2

默认情况下,您的应用程序的上下文根将默认为应用程序的名称。您可以通过查看“服务器”选项卡上的服务器并编辑其配置来更改它(包括将其设置为 /)。您可以在 GUI 中或直接在 server.xml 中进行更改。

如果您的应用程序被称为我的应用程序,我怀疑 localhost:9080/myapp/SimpleServletPath 是您的 servlet 当前所在的位置。

于 2014-05-21T18:40:37.293 回答