Hi,
i'm using CXF to create a client like this :
final ExampleService service = new ExampleService();
client = service.getExamplePort();
Now, i would use a dynamic endpoint (don't call each time the same url).
I have seen the following method (which is working):
((BindingProvider)
client).getRequestContext().put(BindingProvider.ENDPOINT_ADDRESS_PROPERTY,
myUrl);
Now i call my client like this :
public Object myFirstMethod(final String myUrl, final MyExampleParam
object) {
((BindingProvider)
client).getRequestContext().put(BindingProvider.ENDPOINT_ADDRESS_PROPERTY,
myUrl);
return client.myFirstMethod(object);
}
As I can have concurrent calls to this method, should I synchronize it ? (I
have not yet noticed strange behavior, but I guess it is compulsory)
Is there some possible problems when using https instead of http with this
mechanism ?
Thanks for answers
Regards