cancel
Showing results for 
Search instead for 
Did you mean: 

Keeping sessions when calling SAP Web Services?

Former Member
0 Kudos

How do you keep a onoing SAP session when making a call to a web service from a SAP RFC? What I'm trying to accomplish is the use of a lot of global varibles that will be used across a few programs / functions that I need to maintain instead of regathering the data by making another database call to get the data.

Accepted Solutions (0)

Answers (1)

Answers (1)

marcin_cholewczuk
Active Contributor
0 Kudos

Hi,

I've never played with web services this way, but I remember that it is possible to set this parameter "Stateful" in web service configuration. Is it not enough?

Best regards

Marcin Cholewczuk

Former Member
0 Kudos

I don't think I've seen the parameter?

What I'm using to access my RFC's is using the url http://(server)/sap/bc/soap/wsdl?services=(RFC / Function Module)&sap-client=****

marcin_cholewczuk
Active Contributor
0 Kudos

In SE80 choose your webservice and go to configuration tab. You'll find this radio button there.

BR

Marcin Cholewczuk

Former Member
0 Kudos

Hi,

If you use http://(server)/sap/bc/soap/rfc?services=(RFC / Function Module)&sap-client=****

It means that you use the WAS 6.20 first implementation of SAP abap web services which is now completely outdated.

It works fine but it is a very basic implementation with no bells and whistles where you will not find any configuration to keep sessions. The web services don't show in SE80 or SE85, you can't use SOAMANAGER, etc...

If you use a an abap stack based on Netweaver 7.0, use the current implementation of web services.

Regards,

Former Member
0 Kudos

Does anyone have a good tutorial / documentation on how to use this new method?

Former Member
0 Kudos

I've found a tutorial on how to create a web service the new way but the issue I run into now is trying to import the xml into my C# project. It's now showing the method like it should.

How do I consume, it properly? Also when trying to consume it, it's making me enter in the username / password 3x even though I've defined it in the service.

Former Member
0 Kudos

Hi,

The documentation is in help.sap.com.

Beware that the configuration changed after SP14 which introduced the SOAMANAGER web transaction to configure the runtime configuration.

If the SAP web service is completely and properly configured, there is nothing special to consume it :

You use the WSDL to generate a proxy and then you use the proxy in your program.

Regards,

Olivier

Former Member
0 Kudos

Yes I've used SOAManager to configure the Web Service and I've select the "Open WSDL document for selected binding" but when I try to consume it in my C# Visual Studio project it's not pulling the methods like it does when I use the old method of calling SAP's web services.

Not sure what I'm doing wrong or if there is another WSDL that I can use to consume.

Also this is a straight ABAP enviroment.

Edited by: VatHB on May 2, 2011 8:14 AM

Former Member
0 Kudos

Ok, I've finally got the proper way to calling a ws working now I've set the web service to be stateful but it's not keeping my session state.when I call it again.