[jboss-user] [JBossWS] - Chicken vs. Egg problem: Specifying URL for WSDL: file or ht

pxstein do-not-reply at jboss.com
Thu Oct 30 15:38:20 EDT 2008


Assume I have a WSDL file onn C:\myproj\test\mytest.wsdl and generate all the necessary web service stuff from it with wsconsume.

Then one of the generated files contains a reference to the original WSDL file similar to:

public class myService     extends Service  {
    private final static URL CMPXWSSERVICE_WSDL_LOCATION;
    static {
        URL url = null;
        try {
            url = new URL("file:/C:/myproj/test/mytest.wsdl");
        } catch (MalformedURLException e) {
            e.printStackTrace();        }
        CMPXWSSERVICE_WSDL_LOCATION = url;
    }


Later, when I deploy this web service the main, one-and-only WSDL is visible on the server through the address

http://127.0.0.1:8080/pTestProj/mytest.wsdl

Should I replace now the "file:/...." reference by the later "http:...." address in the source code and re-compile and re-deploy it again?

How else can I make the wsdl file address more independent from origin?

Peter

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4185812#4185812

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4185812



More information about the jboss-user mailing list