Skip to Content

In this blog, I wanted to give a walk through of the new Workflow service on SAP Cloud Platform. This was one of the most awaited services on the Platform and no surprise, there was lot of excitement when the service was announced GA last month. I had lot of people ask questions on the capability and feature set of this service. Hence, I have tried to capture some screenshots and explain briefly some of the key functionalities.

The need for a Workflow Service in the Cloud Platform

The Cloud Platform is positioned as an Innovation platform where customers can build brand new apps or extend existing systems – be it on-premise or in the cloud.

There are several scenarios where customers build brand new applications on the Cloud Platform which only rely on the database and UX services provided by the platform. Automating tasks in such scenarios can be challenging. One of the scenarios I hear frequently, is the need to expose a portal to suppliers and have an approval mechanism to commit the updates they make using the Apps hosted on the supplier portal.

To give another example, assume there is a bank looking to rollout a mobile application for their customers to request for a loan.  Generally, the mobile app would trigger the APIs directly in the backend banking system. The logic behind the calculation of credit score, auto approval of loan, UI of approval tasks etc would be embedded within the core banking system. This would work, however, this leave lot of custom development within the core banking system and will impact the maintenance of the system overall.

With the Workflow service, we could redefine the same as shown below

Step 1: Retrieves customer details through APIs which are already exposed form the backend system.

Step 2: Calculate the credit score rating which could be maintained in Business Rule Service

Step 3: If credit score is not so great, customer relationship manager gets to review the request and can either decline the request (step 5) or approve the request (step 6) and the relevant business records get created in the backend system using exposed APIs

Step 4: If credit score is great, auto approval process trigger the update of relevant business records in the backend system using exposed APIs.

Hence, in this process there is only a need to ensure that there are APIs which are available to expose customer details and loan origination.

The workflow service is not only limited to brand new Cloud Platform apps or on-premise systems. This could also be used to extend processes in other Cloud solution. Assume, there is one level approval step which comes as a default in a Cloud solution like Field Glass. Using the exposed APIs, it’s now possible to change the approval process to a multi-step process. After the first level of approval, all the remaining level of approvals can be done using the Workflow service on the Cloud Platform.

The Workflow service is already tightly integrated with the Cloud Platform’s integration services. There are APIs already available to perform things like invoking the Workflow service, retrieving tasks details etc. There is detailed blog which shows how to trigger workflows from Integration services by Archana Shukla

Prerequisites

As a perquisite, you would need SAP Cloud Platform Portal service. This provides the Fiori Launchpad where all the approval and monitoring applications will run.

Once you subscribe to the workflow service, you will get a set of Fiori Apps which would allow the administration, monitoring of the Workflows as well as an App for end users to action the tasks.

 

Workflow Editor

When you launch the Workflow service, you will notice a BPMN based web editor which can be used for modelling your scenario. There are four sections. If you have used Cloud Platform Process Integration service, you will be able to find lot of similarities.

(1) The BPMN palette contain the list of objects which you can use to model your scenario

(2) The Properties section list the related properties of each object which you use in the scenario

(3) You can use the save option to download the metadata of the Workflow model or deploy it to the Cloud Platform. Once you deploy the workflow, it will be available in the Fiori App “Monitor Workflow Definitions”.

(4) Canvas where you would model the workflow scenario.

Let’s take a closer look at the key objects which are available to model a workflow.

Events:

These below events are supported by the Workflow service. As the name indicates, the Start and End events mark the beginning and end of the Workflow.

User Task:

A user task is to be used when you want a user to perform an action during the workflow scenario. Notice there are several sections in the properties editor. You can configure the text to be displayed for the task in the My Inbox App. You can also define who the recipients are for this particular task and finally in the user Interface section, you can refer to SAPUI5 components which will provide the UI for the task within the My Inbox App. These SAPUI5 apps need to be deployed in the Cloud Platform.

Service Task:

A Service task is to be used when you want the system to perform some tasks. This would ideally be APIs which would be invoked to either cloud or on-premise solutions. When invoking APIs exposed from on-premise systems, the Cloud Connector can be leveraged. In the below example, SM2 is the backend system which I have configured as destination in SAP Cloud Platform cockpit and this service task invokes an API to retrieve a customer detail. Supported REST operations are GET/POST/PUT/DELETE.

Script Task:

A script task is to be used when you want the system to execute a script based. This could be used to process an input from the workflow context and store the output as a variable which could be used in the following steps. You can use Java script to read and modify context variables of the Workflow service.

Clicking on “Open Script” take you to another screen where you will use insert your scripts.

To know more about how to use read and set the workflow context, you can look at these examples in SAP Help.

Gateways:

Gateways are used in the workflow service to control the flow of execution. An Exclusive gateway is used to model a decision whereas parallel gateways are used to either split the flow into multiple paths or merge multiple incoming paths. There are options to use expressions in order to define

Workflow Apps

As I mentioned earlier, once you subscribe to the Workflow service, your account will automatically get provisioned with the below Fiori Apps. You should be able to find them in the catalog and add them your Launchpad.

My Inbox:

You probably know the My Inbox App which has been available on the Cloud Platform for a while. The Workflow service uses the same My Inbox App for end users to actions their workflow items. You would need to develop the UI for each of your tasks as UI5 components and these UIs would be displayed within the My Inbox App when the user selects the relevant task.

Monitor Workflow Definition

Unlike My Inbox, this Fiori App is meant for Administrators. It can be used to view all the deployed workflow scenarios. An administrator can view all the instances of a particular workflow and also start a new instance by providing a JSON payload. There is also an option to download the metadata of the workflow model which can be imported into the Workflow editor to view the model

Monitor Workflow Instance

This is another Fiori App meant for administrators to view all the workflow instances. If a particular workflow instance has gone into error, the administrator can view the error details from within the App.

 

I hope this blog gave you an overview of the capability of the service. The workflow service is for sure going to add more flexibility to the cloud platform allowing customers to automate some of their processes and thereby differentiate themselves.

Please bookmark the SAP Help documentation for the Workflow Serivce which would get updated with new features added during the bi-weekly updates.

To report this post you need to login first.

15 Comments

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

  1. Mike Doyle

    Great blog Murali, thanks for sharing.  I think this workflow service is going to be a ‘killer app’ for SCP.  It seems so obvious to run the workflow on SCP as a way to co-ordinate processes across disparate cloud and on-prem systems.  The integration with MyInbox and UI5 apps is nice too.  I never got the chance to develop workflows in R/3 or ECC so hopefully soon I will get a chance to do something similar on Cloud Platform.

    (0) 
    1. Murali Shanmugham Post author

      Thanks Mike. Yes, I agree. The Workflow service will start to play a key role in co-coordinating processes in cloud. It should be easy to start building workflow scenarios as you can leverage on SAPUI5 skills to build the UIs for tasks and use the modeler to design the flow.

      (0) 
  2. Sukanta Rudra

    Hi,

    Nice update with features. However my free Cloud account till yesterday did not show up any service for workflow. Today I see the service, but nothing can be done except for viewing the document (screen capture). Is not not released for folks using free Cloud account? Note: I have been using my free account for last two years and have never had any issues.

    Thanks – Sukanta Rudra

     

    (0) 
    1. Murali Shanmugham Post author

      This is the confusion few people are having. You need click on “Home” and then select “Europe(trial”) from data centers. This will get you back to the same trial instance which you were using for the last 2 years.

      (0) 
    2. Christian Loos

      Hi Sukanta,

       

      the Workflow service is not yet available in the free developer edition (Trial), but only in productive accounts.

      We are planning to make it available in Trial by end of Q2.

       

      Regards,

      Christian

      (0) 
  3. Peter Chezowitch

    Thank you for this introduction. What is the strategic purpose for workflow service? Is it rather replacing abap workflow in the s4 world and if so, is it Targeting both, cloud and on premise Installations or is it rather a cloud replacement of the BPM part of process orchestration? Also: will there be a tighter integration with integration service similar to the xi protocol?

    final question: is it already available for partners?

    (0) 
    1. Christian Loos

      Hi Peter,

      • The Workflow service is not intended to replace either Business Workflow (ABAP) or BPM/Process Orchestration. All three solutions will continue to exist and will also be enhanced further. In simple terms, Business Workflow drives standard business processes in S/4HANA (e.g. Purchase Requestion Approvals), while differentiating/custom processes (also cross-system) can be implemented and managed either on-premise (Process Orchestration) or on the SAP Cloud Platform (Workflow service). See this SAPInsider article for a full overview of all three solutions.
      • Yes, we plan to have a tighter integration with the SAP Cloud Platform Integration service in the future, e.g. by directly looking up available integration flows from the workflow editor or by providing end-to-end monitoring across workflows and integration messages.
      • Yes, the service is available to partners for development/testing/demo purposes as part of the Innovation Pack for SAP CP.
        We are currently finalizing the commercial models for embedding the service in a partner application.

      Regards,

      Christian

      (1) 
      1. Peter Chezowitch

        Hi Christian,

        Thank you for your response and the interesting SAPInsider article.

        Regarding installation of  workflow services as part of the innovation pack:

        Where would I find a manual how to activate the service? I have looked up the documentation, but there it is just mentioning to “enable” the service which is not available in our tenant despite having the innovation pack license.

        (0) 
        1. Christian Loos

          Hi Peter,

          the “Enable” button should automatically show up in your cockpit, if you have a valid license.

          We had a few cases where the license check was missing a few cases, but those should be fixed now.

          If it still doesn’t show up, please create a support ticket on component LOD-BPM-WFS.

          Regards,

          Christian

           

          (0) 
  4. Vladimir Savchenko

    Hi Murali,

     

    I have a question regarding the User Task. Sorry for asking here, but i couldn’t find the answer in the SAP Documentation and i can’t get it working.

    In the list of users for the USER Task, i need to add some user ids. But what are those? I login to my idp with an e-mail, and upon trying to add an email – it rejects it and says that @ is not allowed.

    I assume i am missing some core knowledge to get it running but so far i cannot solve it 🙁

     

    Regards, Vladimir

    (0) 
    1. Vimal Rawat

      Hi Vladimir,

       

      In that field you need to give the SUser or PUser id of the members who will be acting as a RECIPIENT. You can make multiple recipients by providing the values separated by ‘,'(comma).

      e.g.: – p123456,s8950348.

      (0) 
    2. Deeksha Ramesh

      Hi Vladimir,

      Thank you for the comment. We have added a note in the user task configuration that says

      ” To provide multiple recipients to process the task, separate each unique ID with a comma.”

      Do you suggest that this information would suffice or that some more information is required additionally?

      (0) 
  5. Arpit Sinha

    Hi Murali,

    Thank a lot for the informative blog.

    I have a question regarding the Start Event. I am unable to figure out the option, where can I set a condition to start event which will automatically trigger the workflow?

    I understand we can do it manually from Workflow Tile using Start new Instance feature, but I would like to get the automatic triggering of workflow using Event condition.

    I am new to HCP Workflow concept, so please bear with my silly question.

    Regards,

    Arpit

    (0) 

Leave a Reply