cxf-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Glynn, Eoghan" <>
Subject RE: Pitfall to avoid with <jaxws:endpoint> config
Date Thu, 03 May 2007 13:44:24 GMT

I guess I should explain a bit further the root of my confusion on this.

In the case of Endpoint.publish(), the thing that's actually created
from the API is not the implementor itself, as this is created directly
by the app in advance of the call to publish().

So the createdFromAPI attribute on <jaxws:endpoint> suggested to me the
physical endpoint (i.e. the Destination), which is actually created
directly as a result of the Endpoint.publish() call. The identity of
this Destination is given by the address param to passed to
Endpoint.publish(). So it seemed logical that this address should be
used to select the port, which would then be used to select the
<jaxws:endpoint> config ... as opposed to the @WebService(portName)
annotation on the implementor (which isn't actually created from API at

But I guess the flaw in my reasoning is that the address may not
actually be associated with any pre-defined port ... i.e. it needn't
actually match the <soap:address location=.../> element of any port
defined in the WSDL.


> -----Original Message-----
> From: Glynn, Eoghan [] 
> Sent: 03 May 2007 14:06
> To:
> Subject: Pitfall to avoid with <jaxws:endpoint> config
> Folks,
> Just in case anyone else makes the same dumb mistake and ends 
> up tearing out their hair as I did, here's a quick heads-up 
> on an aspect of using <jaxws:endpoint> bean to apply 
> <jaxws:features> to individual endpoints within a 
> multi-endpoint service.
> Basically you can no longer use instances of the *same* 
> implementor class to publish on the multiple endpoints. This 
> is because the portName attribute of the @WebService 
> annotation is used to wire in the <jaxws:endpoint> config. If 
> this annotation is missing, then the port name is inferred 
> from the implementator class name. 
> Either way, you're outta luck using the same implementor type 
> for different endpoints *and* picking up endpoint-specific 
> config. Without config, reusing the same implementor class 
> for compatible ports still works fine in CXF, though I guess 
> someone may point out that it goes against either the letter 
> or the spirit of the JAX-WS spec.
> Cheers,
> Eoghan

View raw message