Index.html not showing up for my WebApp (Tomcat 7 in Eclipse)

I have Tomcat 7 with Servlet 3.0 working in Eclipse.

In my WEB-INF folder, I placed two files: web.xml and index.html. However web.xml defines the welcome file as index.html when I go to

http://localhost:8080/WebApp/

I get 404.

The strange thing is that I have a servlet defined as / login, and when I go to

http://localhost:8080/WebApp/login

I can see and use the servlet (I can debug it and see the doGet () request)

I have no idea why I cannot see the welcome file. It really worked a while ago, but since then I made some changes, I changed the way to connect to the database by setting up the connection pool when Tomcat starts up, but it should "It has a big impact. Not quite sure where to look next, catalina. out does not give any hints.

- , , ? :)

+5
2

, - . . index.html , WEB-INF, WebContent ( WEB-INF). 404 , , ! Doh!

+8

web.xml - :

<servlet-mapping>
    <servlet-name>Faces Servlet</servlet-name>
    <url-pattern>*.xhtml</url-pattern>
    <url-pattern>*.jsf</url-pattern>
    <url-pattern>/faces/*</url-pattern>
</servlet-mapping>

url . index.xhtml, index.jsf .../faces/index

0

All Articles