metro-jax-ws icon indicating copy to clipboard operation
metro-jax-ws copied to clipboard

Control timeout on wsdl download

Open Tomas-Kraus opened this issue 2 years ago • 0 comments

Currently there's no documented way of controlling the timeout on a WSDL download phase.

We've seen calls hanging for up to several minutes in the WSDL download phase.

The 'problem' is that JAX-WS RI uses several underlying JDK technologies which probably each have their own timeout setting. This includes at a minumum:

1. Name resolution timeout 2. HTTP timeout (as per the HttpURLConnection class)

The other problem is that JAX-WS will try a lot of different URLs before it gives up. It will try to append "?wsdl" and repeat the attempt, it will append "mex" and repeat the attempt, and so on. There are probably good reasons for this but all of this is what means that you can wait minutes for a WSDL download to finally give up.

You can find information on how people work around this here but this just seems sad that people have to resort to such measures because of JAX-WS RI shortcomings.

In short: We need to have control over the WSDL download phase and this needs to be separated from settings relating to the actual web service call. For example I would not wait more than 20 seconds for the WSDL download to complete. Anything more than that I would consider an error. On the other hand I'm willing to wait many minutes for the actual web service call to complete (the WS is quite long running by design) and this is no error. So you see, settings for WSDL download phase should not be mixed up with settings for the actual WS call.

Some of this can potentially be solved by having documentation on the issue in the User Guide but I'm afraid some love and attention to the actual WSDL download code within JAX-WS RI is also required.

Environment

Any

Source: https://github.com/javaee/metro-jax-ws/issues/1141 Author: glassfishrobot

Tomas-Kraus avatar Jun 02 '22 17:06 Tomas-Kraus