Skip to Content
Introduction
A little over a year ago, I wrote Develop a Web Service that sends an Email – in ABAP that detailed the process for creating an ABAP Web Service. This weblog was based upon the Netweaver 04 release.

Prompted by a question about the differences between this process in Netweaver 04 and Netweaver 04S, I thought I would return to the subject and compare the process between the two releases.

I will say up front that the differences between the two releases are not as drastic as the changes that occurred between WebAS 620 and Netweaver 04. What you will see here is that SAP has streamlined and simplified the process in preparation for this technology to be a key part of Enterprise Services Architecture.

In this example we will create a very simple Web Service for the sending of an Email

Prerequisites
-Configured Email Setup in the ABAP system – See Sending E-Mail from ABAP – Version 610 and Higher – BCS Interface

Create an ABAP Function Module
The steps for creating the function module have not changed from Netweaver 04 to Netweaver 04S, however I will include them for the sake of completeness.
1. Go to SE80.
2. Create a new RFC enabled Function Module

image

3. Importing Parameters
image

4. Exporting Parameters
image

5. Program Coding

6. Test Function Module

Just to be safe, let’s use the function tester to make sure that the RFC works before wrapping it in a Web Service.

image

image

Create a Service Definition
1. From SE80 Choose other Object
2. Go to the Enterprise Services Tab
3. Choose Service Definition – This is where we begin to depart from the processing within the earlier release. Gone are the two separate entries for Web Service Definition and Virtual Interface. Instead you have a single entry called Service Definition. This new single object now contains the functionality of the two separate previous objects.
image

4. The creation will actually just start a Create Service Wizard.
image

The first step of the wizard is quite similar to the first step of creating the Virtual Interface. We will supply the name of the service, a short description and an Endpoint Type.
image

If we look at the possible values for the endpoint type, we see that we can still use a BAPI, a function group or a single function module. The entry for XI has been renamed ESI Repository Service Interface.
image

5. In the next step of the wizard we will specify the function module that we want to use as the starting point of our Web service.
image

6. Finally we reach the step for choosing a security profile. This step is the same as what used to be the separate Web Service Definition creation. We can choose between two basic profiles. Later we can further tweak the settings contained in either of these profiles.
image

Notice the checkbox at the bottom of the wizard screen. We used to have to go into WSCONFIG and release the Web Service definition after its creation. However by selecting this checkbox, this step can be done automatically for us.

7. We now have our completed service definition displayed in the ABAP Workbench.
image

8. This new object display is a combination of the old Virtual Interface and Web Service Definition screens. We have the Properties, Interface, and Types tabs that have not really changed. However we also have the new Variants tab. A Variant is the replacement for the separate Web Service Definition.
The initial variant has been created for us. The former settings of the Web Service Definition have been set via the profile that we choose in the wizard. It is this screen where they can be further maintained.
image

9. We can create additional variants, all of which will be contained within the single Service Definition we have created.
image

image

10. We can also still publish directly to a UDDI from this screen as well.
image

image

11. Although the release of our Service Definition can be triggered by the wizard, we can still go to transaction WSCONFIG and create releases manually. Now the keys for creating a release are a combination of the Service Definition and the Variant.
image

image

12. Likewise all the test tool and WSDL functionality is still available from transaction WSADMIN.
image

13. Finally to complete the update of the previous weblog, we can also call our Web Service from another programming tool. In the screen shot below we see it in use in Visual Studio .Net.
image

To report this post you need to login first.

4 Comments

You must be Logged on to comment or reply to a post.

    1. Thomas Jung Post author
      A while back SDN changed the format of one type of Blog URL.  I have corrected the old format link in this blog.  You should be able to reach the older referenced blog now.  Thanks.
      (0) 
  1. Bertrand DESSERTENNE
    Hi Thomas,

    I try it in ECC 6.0 with a specific RFC Function module but when i got the end of the wizard i got an error message without any help.

    Could you help me?

    Best regards.

    (0) 
    1. Thomas Jung Post author
      >Could you help me?
      Maybe.  First off, what does the error message say?  Although my advice is the same as in the comment you posted in another of my blogs:

      “The service wizard is rather straight forward and if you receive no results at the end (or an error message), then you might be best simply opening a support ticket on the problem. “

      (0) 

Leave a Reply