cancel
Showing results for 
Search instead for 
Did you mean: 

Dynamic URL for Adaptive Webservice Model

0 Kudos

Hi everyone,

I'm developing a web dynpro application which uses an adaptive webservice model called and it works fine. But I want to set the wsdl-url dynamicly in the implementation-code and I don't know how.

This is what i use so far:


	model = new MdlRunSQL();
	Request_RunSQL requestMO = new Request_RunSQL(model);
	RunSQL runsqlMO = new RunSQL(model);
	requestMO.setRunSQL(runsqlMO);
	wdContext.nodeRequest_RunSQL().bind(requestMO);

Does anyone know how to set the url there?

Greetings,

Constantin

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Constantin,

there is a tutorial using WSModel in combination with WSIL, it's about NWDI (are you using NWDI?), but you will find the relevant steps: https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/c0b53558-6df6-2910-cfbf-a63316bb...

kind regards

Stefanie

P.S. There is a museum called Christian-Rohlfs-Museum in Hagen

0 Kudos

Hi Stefanie,

is there a possiblity to get the wsdl-url from the visual-administrator by using the defaultExecutionDestination?

Regards,

Constantin

former_member751941
Active Contributor
0 Kudos

Hi Constantin,

Check this documents.

<a href="https://www.sdn.sap.comhttp://www.sdn.sap.comhttp://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/f07de95b-d81c-2a10-3daf-96172e846d00">Migration Guide: Web Service Model to Adaptive Web Service Model</a>

<a href="http://help.sap.com/saphelp_nw70/helpdata/en/b5/ce88b82d7bfe4799ba7e175558d0ba/frameset.htm">Consuming a Web Service</a>

Regards,

Mithu

0 Kudos

Hi,

i solved the problem!

i added a dynamic-ws-proxy (e.g. 'proxytest') with the visual-administrator pointing to the http://<host>:<port>/inspection.wsil.

then i added the model using uddi or url and using the destinations 'proxytest'. and then i needed to use the fixed wsdl-url and finishing the model. now unset the designtimeWsdlUrl in the Request_<model> and everything works fine

thanks everyone and especially to you stefanie

Regards,

Constantin

former_member199223
Participant
0 Kudos

Hi Constantin Wildförster,

I have WSDL URL How can import the adaptive webservice model . URL is http://www.webservicex.net/WeatherForecast.asmx?wsdl . i tried using

the same URL to Import adaptive webservice model, when i am giving WSDL URL i getting an error showing error in loading wsdl file

I m using NWDS 2004s Studio SP12.

can u plz answer me clearly.

Regards,

Boopathi M

Answers (3)

Answers (3)

Former Member
0 Kudos

Constantin,

You can modify and use the code pasted below. It worked fine for me.

Attach attach = new Attach();

Request_CreateAttachment request = new Request_CreateAttachment(attach);

request.wdSetInvocationModifier(new IWDWSInvocationModifier() {

public void doModifyInvocation(Object port) {

HTTPControlInterface httpItf = HTTPControlFactory.getInterface(port);

SOAPHeaderInterface soaptf = SOAPHeaderIFactory.getInterface(port);

// timeout for this WS invocation is 120 sec.

// don't use global config. setting of WS-Runtime

httpItf.setEndpointURL(wdContext.currentContextElement().getEndPoint() + "/Attach/services/AttachFile");

public void doModifyAfterInvocation(){}

});

I passed the server host and port of the webservice as an application parameter in the iView property.

Regards,

Janvi

Message was edited by:

Armin Reichert

Former Member
0 Kudos

Hi Constantin,

why do you need it? One advantage of the Adaptive WS Model is the option to use WSIL, then you have the abstraction layer that allows your application to be transported and you don't have to adapt the WSDL URL every time. Does this meet your use case?

Greetings (also to Christian Rohlfs, if you live in Hagen, you should know him )

Stefanie

0 Kudos

Hi Stefanie,

the Webservice(s) can run on several servers. like one webservice for the production on server x and on webservice for the development on server y.

When the Web Dynpro application is used on the development-server, the webservice url should be taken from a database and the same procedure for the production-server.

But the Web Dynpro application should not be changed or rebuild/deployed.

Or when all Webservices will change the server, the Web Dynpro applications should not be updated (it's only necessary to update the database).

Regards,

Constantin

PS: sorry, i dont know Christian Rohlfs ;(

Former Member
0 Kudos

Hi,

You can change it in WebDynproPerspective..

Expand yuor project>WebDynpro>Models><Modelname>>

ModelClasses--><Request_ Node> Double click

Select properties tab in View Editor.. There you can change WSDL URL

If you change one <RequestNode> it will change all the remaining nodes

Ragards

LakshmiNarayana

0 Kudos

hi,

thank you for your quick reply. but, we've got several servers and the wsdl-url should be taken from a database or a system property, so it MUST be in the implementation code.

Constantin

Former Member
0 Kudos

Hi,

When using AdaptiveWSModel, we have no option to set " _EndPoint"

like in WebserviceModel.. We can change in the above way for every model

I know this way to change WSDL URL.. so, let's wait for expert's reply.

Regards

LakshmiNarayana

Former Member
0 Kudos

Hi alll,

If anybody knows about it, Please Reply.

Thanks in advance

LakshmiNarayana