简体   繁体   中英

404 error when called the default jsp page, able to call index.html

Environment - Eclipse IDE, running tomcat server by creating an instance of it in Eclipse.

Overall Setup - I have deployed 2 web application(A & B) in Tomcat server, where A calls B & things happens. This works fine most of the time.

Orignal Issue Scenario

  1. Lets say I leave my machine unattended for couple of hrs & then comeback restart the server(has 2 apps deployed in it).
  2. Open the browser, I am able to call app A, but not able to establish connection with app B.

On digging further, I tried to load a jsp page from app B with url -

http://localhost:8080/testrunner/login

but can't do that HTTP状态404 . However I am able to call the index.html from this url -

http://localhost:8080/testrunner/

Current Solution - The way to overcome this issue is to simply redeploy app B & I am good to go ie I am app A calls app B.

Question -

  1. But my Issue is that why should I get this error & how to overcome this issue without redeploying app B.
  2. Also when I do my current solution , the login page loads in eclipse's browser, but the same is not loaded in FF browser. Not sure what's missing here.

Any help/clue would be appreciated.

From provided details I can say

You have deployed application as testrunner . So, http://localhost:8080/testrunner/ calls index.html from the welcome-file-list given in deployment descriptor.

404 or Not Found error message is a HTTP standard response code indicating that the
client was able to communicate with the server, but the server could not find what was
requested.

When you do http://localhost:8080/testrunner/login , Server could not find any mapping named \\login . So, Check You have mapping for " /login " in your application called "testrunner"

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM