Solution for Web Service 404 Error in Eclipse

A fun little Web Service 404 mystery and solution for you. Our Eclipse Workbench contains 3 projects, though only the two pertinent ones in our story are Jaxws and Jaxweb, a web service and client respectively.

We’re using Tomcat as our project web server and everything looks good, but we’re getting a 404 error when testing our Fahrenheit to Celsius Conversion Web Service.

The error is displayed (as opposed to plain ol’ ugliness) because we designed the JSP page to catch any errors using the Web Service.

Let’s look at the Eclipse Servers View.

Mystery solved! Only the jaxweb web services client application is running, so the jaxws web service application obviously cannot be found. We could end the story right here, but in case you’re interested in the solution, we start by right-clicking on our Tomcat server and select “Add and Remove…”

And add the web service application.

Oh Happy Day! 90 Degrees Fahrenheit is 32.22222 degrees Celsius!

And yes, from the application screenshots it’s clear I need to learn how to spell “Fahrenheit” consistently, but hey, that’s a hard word!