To get the WSDL, change the web.xml url-pattern to <url-pattern>/*</url-pattern>
.
and the URL is http://localhost:8080/ws-inbound-gateway/echoService.wsdl
.
Everything else looks good.
Regarding the WebServiceTemplateQuestion, what are you sending? It looks like you are using the ws sample app, which uses a WebServiceTemplate...
@Test
public void testWebServiceRequestAndResponse() {
StringResult result = new StringResult();
Source payload = new StringSource(
"<?xml version=\"1.0\" encoding=\"UTF-8\"?>" +
"<echoRequest xmlns=\"http://www.springframework.org/spring-ws/samples/echo\">hello</echoRequest>");
template.sendSourceAndReceiveToResult(WS_URI, payload, result);
logger.info("RESULT: " + result.toString());
assertThat(result.toString(), equalTo(
"<?xml version=\"1.0\" encoding=\"UTF-8\"?>" +
"<echoResponse xmlns=\"http://www.springframework.org/spring-ws/samples/echo\">hello</echoResponse>"));
}
And that works just fine.
Looks like your NPE is on the server - take a look at the server logs to see what happened.