UX Extension: Part 2-Exposing API to SCP

In This Part

In this part, we are going to setup SAP Cloud Connector on the back-end server to connect to SCP and create a new Destination on SCP to allow connection from SCP to back-end.

SAP Cloud Connector Check

Note: Even you already SCC installed but it is likely an old version. I recommend to follow these steps anyway:

  1. Download SAP Cloud Connector (Linux)
  2. Transfer ZIP to Linux VM using psftp (installed with PuTTY).
  3. Use command sudo unzip sapcc-XXX-linux-x64.zip (replace placeholder XXX with the given release version, e.g. 2.9.0.2) to unzip the file.
  4. Then use sudo rpm -i --force com.sap.scc-ui-XXX.x86_64.rpm and wait until the installation finished.
  5. Use command sudo service scc_daemon status and you should see the SAP Cloud Connector is started
scc_daemon.service — LSB: LJS Daemon
Loaded: loaded (/etc/init.d/scc_daemon)
Active: active (exited) since Wed 2017–05–03 12:56:03 UTC; 1h 46min ago
Process: 1525 ExecStart=/etc/init.d/scc_daemon start (code=exited, status=0/SUCCESS)
May 03 12:56:01 sid-npl scc_daemon[1525]: Starting scc_Daemon
May 03 12:56:02 sid-npl su[1635]: (to sccadmin) root on none
May 03 12:56:03 sid-npl su[1635]: pam_unix(su:session): session opened for user sccadmin by (uid=0)
May 03 12:56:03 sid-npl scc_daemon[1525]: scc_Daemon started.
May 03 12:56:03 sid-npl systemd[1]: Started LSB: LJS Daemon.
May 03 12:56:11 sid-npl scc_daemon[1525]: osgi>
May 03 12:56:33 sid-npl scc_daemon[1525]: osgi> SAP HANA Cloud Connector 2.7.2 started on https://localhost:8443 (instance role is undefined)

Connect SCC to SCP

  1. Go to https://vhcalnplci.dummy.nodomain:8443/
  2. Login with username Administrator and password manage
  3. Select Master (Primary Installation) and change password
  4. Select Landscape Host to hanatrial.ondemand.com
  5. Input you Account Name e.g. p1942128127trial
  6. Input Display Name for your reference in SCP
  7. Input your Account User e.g. P1942128127 and password
  8. After connect, you should see the connection is working

Check the connection on SCP at Connectivity → Cloud Connectors

Add Access to Back-end System

  1. On SCC Admin Console, go to Cloud To On-Premise
  2. Click + to Add System Mapping
  3. Select ABAP System
  4. Protocol HTTPS
  5. Local Host: localhost Port: 44300
  6. Input Virtual Host and Port as you want. (This is to hide back-end technical detail from the cloud for security reasons)
  7. Click + to Add Resource
  8. Input URL Path /sap/ and select Path and all sub-paths and Save. This allows access to all resources from the cloud.

Go back to SCP and now you should see the back-end system you’ve just exposed.

Create HTTP Destination on SCP

  1. On SCP, go to Connectivity → Destination
  2. Click New Destination
  3. Input the following:
    Name: s4h-onpremise-http”
    Type: HTTP
    Descriptor: S/4HANA HTTP API
    URL: https://s4h:443
    Proxy Type: OnPremise
    Authentication: BasicAuthentication
  4. Input back-end’s user/password
  5. Add two additional properties: 
    WebIDEEnabled: true 
    WebIDEUsage:odata_abap,ui5_execute_abap,dev_abap
  6. Click Check Connection and you should see this:

Test OData Service in Web IDE

  1. Go to New → Project from Template
  2. Select List Report Application
  3. Enter Project Name Test and Title Test
  4. In Service Catalog, select S/4HANA HTTP API and input back-end username and password
  5. You should see the list of all available services. Search for PROD and select EPM_REF_APPS_PROD_MAN_SRV. You will see the Products entity like you see on the back-end.

Continue Reading

Read More