Development of Workflow in Business Process automation
2023-11-27 18:13:23 Author: blogs.sap.com(查看原文) 阅读量:10 收藏

Hello People!! Hope you are doing well 🙂

I am back with one more interesting article to show how to develop the workflows in SAP Build using Process Automation..

Introduction

SAP Build Process Automation combines workflow management, RPA functionality, decision management, process visibility, and embedded AI capabilities into one intuitive low-code experience. This allows you to simplify automation with visual drag-and-drop tools. It enables both citizen and professional developers to easily digitalize their workflows without writing code. There are hundreds of pre-built content packages and connectors you can use to jumpstart your automation projects and save on development time.

Lets discover how to use this process automation tool to create and manage the workflows.

  • In Business application Studio or the SAP Web ide the workflow modules are developed which works on the business process.
  • In BAS the workflows are developed which has all the components which differs with the sap business process automation.
  • In workflows, there are some tasks that has the payload creation, service calls, exclusive gateway, intermediate message events, and all the other tasks.

Deploy the Workflow in BPA Runtime:

Step1: Firstly when we are migrating the SAP workflow management workflows, that is to make the workflow run in BPA run time we have to do some code changes in the mta.yaml file of the project.

modules:
– name: workflow-module
type: com.sap.application.content
path: workflow-module
requires:
– name: workflow
parameters:
content-target: true
resources:
– name: workflow
type: org.cloudfoundry.managed-service
parameters:
service: workflow
service-plan: standard

Step2 :Change the above snippet in mta.yaml file into the below code

requires:
– name: sap_processautomation
parameters:
content-target: true
service-key:
config:
deployUsageScenario: workflow
name: spa-workflow-service-key
resources:
– name: sap_processautomation
type: org.cloudfoundry.managed-service
parameters:
service: process-automation-service
service-plan: standard

Step 3: Deploy the application into cloud foundry and trigger the workflow as same as in workflow management but the monitoring of the workflow can be seen in the Monitor tab of SAP Build.

Now, I don’t think the above manual changes are needed in the code as the code is automated in mta.yaml file when you select the workflow module.

Steps for Redevelopment of the Workflow in Business Process Automation:

  • First analyze the steps of the existing workflow and check how can we replicate in BPA.
  • Let’s take the first step if the workflow is having an UI form which triggers the workflow initially, that form can be developed in BPA and can be used.

  • Now, for the script task and service task we can use the action project in BPA.
  • Go to create and click on Build an Automated Process then click on Action Projects.

  • This action project works on Open API Specification where we will be creating it for the required service call.
  • Once you create your API specification, you must upload it here while creating action project and test it with the relevant destination and input parameters.
  • Once you get your action project output you can release and publish.

  • Click on Browse Library you can see the published action projects, take the project which u have created and add it to your process.
  • Now for this action project you need to map your input fields, which comes from your previous step.

  • If your next step is also a service call you have to follow the same steps as mentioned above.
  • In the workflow if you have an intermediate message event, as the BPA is still not providing this feature you can use the existing workflow management workflow to leverage the task.
  • Recently SAP has released a new feature called Events which initiates/ sends as an event to your workflow instance you can try to use that instead.
  • As of now, SAP Build Process Automation supports events from SAP S/4HANA Cloud and SAP S/4HANA On-Premise. It will be scaled up with other external systems (SAP Ariba, SAP SuccessFactors)which is part of the roadmap.
  • Here you can use the Call Workflow task to call your existing workflow if its required to call the workflow management workflow.

  • Provide the input parameters to the workflow task, definition id would be your workflow id, for the inputs you can also create a data type through which you can map the inputs all around the process.
  • In the workflow if you have an approval task, create an approval form which has approve and reject connections. The task can be seen in My inbox of the SAP Build, based on the approval or reject you can connect the next process.

  • Once the process is deployed and triggered, when it reached the step of the approval based on the category of approve/reject the flow will work.
  • All the deployed workflows can be monitored in monitor tab of sap build.

  • Process and workflow instances will take you to all the instances, filter out with the respective workflow id.

  • Here, where you can observe all the workflow context parameters.
  • This Monitor tab also has the visibility scenarios tile from where you can navigate to the dashboard of respective visibility scenario if any.
  • Here, the way how can you re develop or develop the workflows in more simpler way…

What we have covered so far…

  • Changing the mta.yaml file manually to support the BPA runtime
  • Developing UI/form
  • Script/Service Tasks (to call api’s)
  • Deploying to BPA
  • Monitoring the Business Process

Happy Learning 🙂

Useful Links:

SAP Build Process Automation | Product Features

SAP Process Automation | SAP Learning

Tutorial Link:

Build Your First Business Process with SAP Build Process Automation | SAP Tutorials


文章来源: https://blogs.sap.com/2023/11/27/development-of-workflow-in-business-process-automation/
如有侵权请联系:admin#unsafe.sh