Viswa.TK wrote:
> Yes..I checked CXF samples and i have created my class based on
> java_first_spring_support sample only.
> But in my project, i have kept my interface class and webservice
> implementation class in different packages. I tried creating wsdl using the
> maven plugin and it was working properly (i.e. it contains all definitions
> of the service class and pojo's that are available). But wsdl is not created
> properly if i try on the fly (i.e. directly giving the url in browser. wsdl
> contains service class details. it does not have pojo elements.).
When you have the interface and implementation in different packages
without an explicit targetNamespace then the JAX-WS spec puts the
implementation (the "service" in WSDL-speak) into a different namespace
from the interface (the "portType"). It's not possible to represent all
of this in a single WSDL document, as it can only have one target
namespace, so CXF must break the definition up into separate WSDLs.
The ?wsdl URL gives you an "implementation" WSDL with one
targetNamespace defining just the service, and this imports another WSDL
("?wsdl=2" or something like that) with a different targetNamespace
containing the port type, messages, schema types, etc. If the POJOs are
in yet another namespace then you might end up with the interface WSDL
importing a separate xsd file defining those types. If you resolve all
the imports you'll see that all the definitions are there.
Ian
--
Ian Roberts | Department of Computer Science
[EMAIL PROTECTED] | University of Sheffield, UK