You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cxf.apache.org by John <li...@johndubchak.com> on 2008/08/28 16:47:34 UTC
New to CXF - question with Sample
Hi,
I am new to CXF and trying to get familiar with it by running some of
the samples and trying my hand at writing a couple of simple webservices.
The question I have relates to the basic, HelloWorld, sample. I have
created the server and it runs fine - dependencies are set up correctly.
However, when working on the client, there is a dependency on the
HelloWorld.class file, which I assume to be the actual remote webservice
interface.
How, in a real world scenario, does a client get a hold of this? My
assumption is that I would get the WSDL for the remote service and then
do a wsdl2java on it and compile the generated interface as part of my
client application.
Is this correct? If not, what is recommended?
Thanks very much.
John
Re: New to CXF - question with Sample
Posted by Daniel Kulp <dk...@apache.org>.
In general, the client would use wsdl2java to generate it's own classes.
However, within your enterprise, you can optimize things a bit. For
example:
common.jar -
Stores the wsdl contract.
Runs wsdl2java and generates all the java bits
server.jar/war - depends on common.jar
Contains the "Impl" that implements the interfaces in the common jar
Dan
On Thursday 28 August 2008 10:47:34 am John wrote:
> Hi,
>
> I am new to CXF and trying to get familiar with it by running some of
> the samples and trying my hand at writing a couple of simple webservices.
>
> The question I have relates to the basic, HelloWorld, sample. I have
> created the server and it runs fine - dependencies are set up correctly.
>
> However, when working on the client, there is a dependency on the
> HelloWorld.class file, which I assume to be the actual remote webservice
> interface.
>
> How, in a real world scenario, does a client get a hold of this? My
> assumption is that I would get the WSDL for the remote service and then
> do a wsdl2java on it and compile the generated interface as part of my
> client application.
>
> Is this correct? If not, what is recommended?
>
> Thanks very much.
> John
--
Daniel Kulp
dkulp@apache.org
http://www.dankulp.com/blog