When you'd like to deploy an endpoint with existing WSDL, you need to tell the JAX-WS runtime the association between the WSDL and your service. This is done by adding a few more attributes/elements to the ws:service element like this:

<ws:service bean="#myService" serviceName="tns:fooService"
  portName="tns:foo" xmlns:tns="http://my/service/nsURI">

The portName attribute works like @WebService(portName=...) (except that it's a real QName), and the primaryWsdl element works like @WebService(wsdlLocation=...) (except that it can take forms other than String.) If the primary WSDL is omitted, the runtime will search for WSDL in /WEB-INF/wsdl/ and find one that matches the specified port and service name.

See a complete example contirbuted by Andreas for more details (although this does things slightly differently.)

Terms of Use; Privacy Policy; Copyright ©2013-2015 (revision 20151030.c1dd42a)
Please Confirm