0
I’m trying to run a Web Service
SOAP
by the server GlassFish Server 4.1.1
in the NetBeans 8.2
. When trying to execute the following error is returned:
Methods of Web Service:
@WebService(serviceName = "CalculatorWS")
@Stateless()
public class CalculatorWS {
@WebMethod(operationName = "hello")
public String hello(@WebParam(name = "name") String txt) {
return "Hello " + txt + " !";
}
@WebMethod(operationName = "add")
public int add(@WebParam(name = "i") int i, @WebParam(name = "j") int j) {
return i + j;
}
}
I run the Web Service as follows:
But the following error is returned:
What to do ?
Check that the service has been deployed correctly, and that the server is running.
– Reginaldo Rigo
The server is started
– Raphael Prado de Oliveira
Webresponde when Voce types http://localhost:8080 in the browser? And what happens if you type http://localhost:8080/Calculatorws/Calculatorws? Tester?
– Reginaldo Rigo
localhost:8080 in browser returns "Your server is now running".
– Raphael Prado de Oliveira
if I type http://localhost:8080/Calculatorws/Calculatorws? Tester gives HTTP 404 - Not Found
– Raphael Prado de Oliveira
Edit your question and post the entry of the Calculatorws page where the page receives the parameters.
– Reginaldo Rigo
post the method you say ?
– Raphael Prado de Oliveira