cxf-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Glen Mazza <>
Subject Re: jaxws:endpoint address not used when using createdFromAPI
Date Wed, 26 May 2010 16:15:56 GMT

dkulp wrote:
> On Wednesday 26 May 2010 4:18:25 am Seumas Soltysik wrote:
>> If I call Enpoint.publish(address, implementation) and define a
>> <jaxws:endpoint> like this:
>>      <jaxws:endpoint
>> name="{}PeerManagerPort"
>> address="http://localhost:8888/services/PeerManagerService"
>>      wsdlLocation="./wsdl/peer-manager.wsdl"
>>      createdFromAPI="true"
>>      endpointName="ns:PeerManagerPort"
>>      serviceName="ns:PeerManagerService"
>>      xmlns:ns=""/>
>> the address attribute is not used by the EndpointImpl class. In
>> EndpointImpl.getServer(), the address is read from the configuration and
>> set on the endpoint but it is never used. The address from
>> Endpoint.publish(address, implementation) always over-rides the address
>> in
>> the configuration. This pretty much makes sense since if you specifically
>> specify an address then that is the address that should be used as
>> opposed
>> to the address in configuration. However, it seems to me that if you pass
>> in and empty string or a null value and the configuration for the
>> <jaxws:endpoint> contains an address attribute, then that address
>> attribute should be used. Why is this not the case?
> I'd probably consider that a bug.   If the passed in address is null,
> pulling 
> it from the config definitely makes sense.

Probably, but I wouldn't say "definitely".  The fact that the developer used
Endpoint.publish(address, implementation) instead of
Endpoint.publish(implementation) indicates the developer specifically wanted
to override the address from what's in the default configuration but that he
goofed up and made an error in his setting of the address property.  If
that's the majority scenario, we would be doing the developer a favor in not
relying on the config file value--instead having CXF return an error and
alerting the developer to his mistake.


View this message in context:
Sent from the cxf-dev mailing list archive at

View raw message