Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.programmer > #24853

Re: Axis2 web service How to Make Web Service Address Configurable

From Sebastian <news@seyweiler.dyndns.org>
Newsgroups comp.lang.java.programmer
Subject Re: Axis2 web service How to Make Web Service Address Configurable
Date 2013-07-31 07:26 +0200
Organization albasani.net
Message-ID <kta765$gpo$1@news.albasani.net> (permalink)
References <160ade1f-4f9c-43a9-aeb8-d9d4f600184f@googlegroups.com>

Show all headers | View raw


Am 31.07.2013 06:30, schrieb zigzagdna@yahoo.com:
> Subject: Axis2 web service How to Make Web Service Address Configurable
>
> I am generating client and web service code from a wsdl file. Now my wsdl file has following for web service end point address:
> <wsdl:service name="SG910_BtB_IN0138_NonConformances_ETS_Source_v1.webService.receiveNonConformanceWS">
> -<wsdl:port name="SG910_BtB_IN0138_NonConformances_ETS_Source_v1_webService_receiveNonConformanceWS_Port" binding="tns:SG910_BtB_IN0138_NonConformances_ETS_Source_v1_webService_receiveNonConformanceWS_Binder">
>    <soap:address location="http://itsusmpl00082.jnj.com:7996/ws/SG910_BtB_IN0138_NonConformances_ETS_Source_v1.webService.receiveNonConformanceWS/SG910_BtB_IN0138_NonConformances_ETS_Source_v1_webService_receiveNonConformanceWS_Port" />
>    </wsdl:port>
>    </wsdl:service>
>
>
> Now location is here is hardcoded to refer to some address. Now I am using wsdl2java to generate code. But code has address hardcoded. Since this address can change from dev to qa to prod. How can I make generated code independent of address; i.e., generated code will work across all environments.
>
> I am new to axis2 and this code generation, so appreciate any guidance,
>
>
if the endpoints are different, I guess there would be multiple wsdl's, 
each appropriate to the environment. So you could
a) generate the code for each environment separately
b) use Ant or Maven to deploy the code appropriate for each environment.

Alternatively, perhaps you could do the code generation in each of the 
environments (perhaps even at runtime) and load the artifacts dynamically.

-- Sebastian

Back to comp.lang.java.programmer | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Axis2 web service How to Make Web Service Address Configurable zigzagdna@yahoo.com - 2013-07-30 21:30 -0700
  Re: Axis2 web service How to Make Web Service Address Configurable Sebastian <news@seyweiler.dyndns.org> - 2013-07-31 07:26 +0200
    Re: Axis2 web service How to Make Web Service Address Configurable zigzagdna@yahoo.com - 2013-07-31 09:28 -0700
  Re: Axis2 web service How to Make Web Service Address Configurable Arved Sandstrom <asandstrom2@eastlink.ca> - 2013-07-31 18:04 -0300
    Re: Axis2 web service How to Make Web Service Address Configurable Lew <lewbloch@gmail.com> - 2013-07-31 14:14 -0700
      Re: Axis2 web service How to Make Web Service Address Configurable zigzagdna@yahoo.com - 2013-07-31 15:07 -0700
        Re: Axis2 web service How to Make Web Service Address Configurable Lew <lewbloch@gmail.com> - 2013-07-31 17:47 -0700
          Re: Axis2 web service How to Make Web Service Address Configurable Arved Sandstrom <asandstrom2@eastlink.ca> - 2013-07-31 22:04 -0300
  Re: Axis2 web service How to Make Web Service Address Configurable Arne Vajhøj <arne@vajhoej.dk> - 2013-07-31 23:26 -0400

csiph-web