Skip to content

Instantly share code, notes, and snippets.

@MPriess
Created July 23, 2012 13:36
Show Gist options
  • Save MPriess/3163630 to your computer and use it in GitHub Desktop.
Save MPriess/3163630 to your computer and use it in GitHub Desktop.
cxf
public FooWS getEndpoint() throws MalformedURLException {
if (webservice == null) {
FooWS client = new FooWSService(new URL(wsEndpoint)).getFooWSPort();
if (timeout != -1)
{
Client cl = ClientProxy.getClient(client);
HTTPConduit http = (HTTPConduit)cl.getConduit();
HTTPClientPolicy httpClientPolicy = new HTTPClientPolicy();
httpClientPolicy.setConnectionTimeout(timeout);
http.setClient(httpClientPolicy);
}
this.webservice = client;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment