Search code examples
javaweb-servicesjax-wsjax-rpc

How to change address location of JAX-WS webservice


We have currently exposed JAX-RPC webservice with following URL

http://xx.xx.xx.xx/myservice/MYGatewaySoapHttpPort?wsdl

We migrated webservice to JAX-WS by generating WebService from above WSDL

But new webservice is accessible from following URL

http://xx.xx.xx.xx/myservice/MYGateway?wsdl

How i can make my JAX-WS webservice to be accessible by same URL mentioned first? so that our customer dont have any problem.

Update:

Service Element of WSDL from which i created is as per expectation

<WL5G3N0:service name="MyGateway">
    <WL5G3N0:port binding="WL5G3N2:MyGatewaySoapHttp" name="MyGatewaySoapHttpPort">
      <WL5G3N3:address location="http://xx.xx.xx/myservice/MyGatewaySoapHttpPort"/>
    </WL5G3N0:port>
  </WL5G3N0:service>

But WSDL of JAX-WS is not same and this WSDL is auto generated.

<WL5G3N0:service name="MyGateway">
- <WL5G3N0:port binding="WL5G3N2:MyGatewaySoapHttp" name="MyGatewaySoapHttpPort">
  <WL5G3N3:address location="http://xx.xx.xx/myservice/MyGateway" /> 
  </WL5G3N0:port>
 </WL5G3N0:service

I created webservice with Oracle Eclipse Indigo.

Can i change with any annotaion?

Regards,


Solution

  • We missed very basic point, servlet mapping in web.xml did all trick. for details please find below link

    http://pic.dhe.ibm.com/infocenter/wasinfo/v6r1/index.jsp?topic=%2Fcom.ibm.websphere.wsfep.multiplatform.doc%2Finfo%2Fae%2Fae%2Ftwbs_customwebxml.html