Spending a little bit of time looking into jax-ws-catalog files in order to add support for a future version of JDeveloper. JAX-WS appears to have good support for the OASIS Catalog specification: so as well as providing indirections for individual URLS:
<?xml version="1.0" encoding="ISO-8859-1" ?> <catalog xmlns="urn:oasis:names:tc:entity:xmlns:xml:catalog" prefer="system"> <system systemId="http://localhost.localdomain:7101/Application1-Project1-context-root/HelloPort?WSDL" uri="http://production:7101/Application1-Project1-context-root/HelloPort?WSDL"/> </catalog>
the catalog can also be used to re-write all URLS:
<?xml version="1.0" encoding="ISO-8859-1" ?> <catalog xmlns="urn:oasis:names:tc:entity:xmlns:xml:catalog" prefer="system"> <rewriteURI uriStartString = "http://localhost.localdomain:7101/" rewritePrefix = "http://production:7101/" /> </catalog>
Although you could create a catalog file for WAR and JAR in your project, you can just create the file once at the EAR file level. For JDeveloper users this can be created directly under "Application Resources".
This catalogue file will be used by all the proxies, you will find that due to a bug in weblogic the service will fail to deploy if the original URL is not available. So for the moment this is a useful hack for non-production environments only with weblogic; but will probably work fine for other application servers. Also do remember this is only going to work for JAX-WS services.