SlideShare a Scribd company logo
1 of 29
Download to read offline
SAP Business Workflow and
Business Rules Framework Plus -
BRFplus
Thomas Kosog
ASUG Annual Conference
Session 0801
May 14, 2012
© 2011 SAP AG. All rights reserved. 2
Agenda - SAP Business Workflow and BRFplus
• Overview of an example material master process
• Overview of BRFplus (recommended release level: NW 7.02 SP 11)
• BRFplus in Detail
• Function, Ruleset, Rule, Expression, Action
• ABAP program to start the process
• Business Object Type
• Event Queue
• Steps in the SAP Business Workflow
• BOR method with BRFplus function call
• Generated BRFplus Task with generated ABAP Object Class
• Summary
© 2011 SAP AG. All rights reserved. 3
Example for a Material Master Workflow and BRF plus
ABAP program to call BRF plus function “Check Material”
-Select materials from data base using field MARA-BISMT and MARA_MTART
- Loop over result and filter via Material Class and Material Type in Decision Table
- Trigger Business Object Event BUS1001006 – Started_By_BRFplus
Hint: Use Event Queue to avoid system overload
Workflow
Container
- Material-Number
- Material-Type
- Unit of Measure
- Old Material
- Industry
- Material Owners
Background Step “ZB1001006 - Get Material data and find Material Owner”
Call BRF plus function “Find Approvers” with Decision Table
(Material Type & Branch  Material Owner)
Workflow WS97300254
Dialog Step for Material Owner with Attachment – Display Material.
BOR method calls BRF plus function “Determine BISMT” - Decision Tree
- Present result in Pop-Up with suggested BISMT value
Background Step
Call BAPI to add BISMT to Material
-Raise temporary ERROR, if it fails
Generated BRFplus Task
“Send Email”
Material Owner provided value for BISMT
BRFplus Details
© 2011 SAP AG. All rights reserved. 5
BRFplus Overview
BRFplus workbench:
- Simulate Function
Input via ABAP
Program to call a
BRFplus function
Input via
generated
Web Service
Function with Signature (Input data and result)
BRFplus Application
Ruleset (One or more)Context:
Function Signature
and additional
Variables Sequential Rules
to implement Business Logic
Perform Action,
like “Send email”,
“Start Workflow”,
“Trigger Event”
Expressions, like
Data Base Look Up,
Loop, Decision Table,
Decision Tree, Formula
After simulation:
Look at result
and trace in the
BRFplus WorkbenchRead
Read
and Update
Returned Result
© 2011 SAP AG. All rights reserved. 6
Transaction “BRFplus”
– Call Web Browser with BRFplus Workbench
Finishing Steps
- SAVE
- CHECK
- ACTIVATE
 BRFplus is
generating ABAP
objects
Called from method in Workflow dialog step
Called from method in Workflow background step
Called from Program to start Workflow
Active Indicator
Switch to EDIT mode
for more functionality
Right click
to get menu
© 2011 SAP AG. All rights reserved. 7
BRFplus Function
GUID
used in
ABAP
program
to call
BRFplus
function
Import
Export
Drop Down Menu
Test
© 2011 SAP AG. All rights reserved. 8
Simulation of a BRFplus function (Test)
Trace shows result of every step
Note: This event did not occur yet, since the step to call the
ABAP statement “Commit Work” was not added to this
BRFplus function yet.
© 2011 SAP AG. All rights reserved. 9
BRFplus Data Element and “Where Used List “
BRFplus “Binding” points to DDIC element.
You can also define elements on BRFplus delivered types:
- Text, Amount, Boolean, Number, Quantity or Time-Point
Signature
© 2011 SAP AG. All rights reserved. 10
Ruleset defined in BRFplus Function
A BRFplus function
needs at least
one ruleset.
Each ruleset has one
or more rules.
A ruleset is using the
signature of the
BRFplus function
and can add
additional
variables to
the context
Hint: Top-Down Modeling Approach –
Create the next “lower” level when and where you need it
© 2011 SAP AG. All rights reserved. 11
Ruleset and Rules
Click on the “number”
in front of the variable
to add more Context Elements
Example: “Material-List” to carry
result of rule-1 into rule-2
Rules are called sequentially
BRFplus expression for
a data base select statement
- Result: Material-List
Complex rule with loop,
decision table and action
to trigger Workflow Event
© 2011 SAP AG. All rights reserved. 12
Rule with Expression – Decision Table
The Material List was created by
the previous rule, which called
an expression to perform a
data base look up.
The Material-Group and Industry
are a part of the structure Z_MATERIAL
and are used in the decision table
Decision Table
© 2011 SAP AG. All rights reserved. 13
Action
Predefined BRFplus
action for Workflow
- Start Workflow Instance
- Trigger Object Event
Hint: It is better for the system
performance not to start too
many workflow instances in a short time
 Trigger Events and use Event Queue
Option to add values to predefined event parameters
© 2011 SAP AG. All rights reserved. 14
Decision Table to Return Users
BRFplus function to find users
- Context
- Ruleset
- Rule
- Expression with
decision table
returning a list of users
- Check user validity
and convert into
Workflow Agents
in following rule
or calling ABAP method
© 2011 SAP AG. All rights reserved. 15
Decision Tree to suggest Value for BISMT
Find BISMT Value based on
- Industry (Branch)
- Unit of Measure
- Material Type
Industry
UoM
M Others
Type
BISMT =
Goods
FERT Others
BISMT =
Item
Type
BISMT =
Service
FERT Others
BISMT =
Component
KG Others
Hint: This is only an example. This is NOT how SAP recommends to use the field MARA_BISMT
BISMT =
Others
Workflow Design
© 2011 SAP AG. All rights reserved. 17
Summary Overview for the Start Process
ABAP program
BRFplus function
BRFplus Expression
Workflow
WS97300254
Workflow - Container
BOR Event
Event Queue
Job to run Event Queue
BRFplus Ruleset
BRFplus Rule
MARABRFplus Action
BRFplus
Application
Read
© 2011 SAP AG. All rights reserved. 18
Business Object Type – SW01
ZB1001006 is a sub-object type
of Business Object BUS1001006
with a system-wide delegation
Hint: BRFplus functions can also be called
in virtual attributes and functional methods
BAPI call
Call
BRFplus
function
Triggered by an Action
from within a BRFplus function
© 2011 SAP AG. All rights reserved. 19
Example Program to Start the Process – SE38
Hint: Set a breakpoint and run the program to see the ABAP code, which was generated by BRFplus
Each BRFplus
function has its own
unique GUID
© 2011 SAP AG. All rights reserved. 20
BOR Method calling a BRFplus function
GUID of the BRFplus
function to find
Material Owners
This BRFplus
function provides
a result. These
users need to be
checked and changed
into Workflow Agents.
If no workflow agent could be determined, then an exception handler could be added,
a Workflow error could be raised or the workitem could be routed to all possible agents of the dialog step.
© 2011 SAP AG. All rights reserved. 21
Event Trace - SWEL
If the BRFplus function was only simulated, then this list is empty
This snap shot was taken, after the Start Program was called
This snap shot was taken after the “event-queue” job was started
© 2011 SAP AG. All rights reserved. 22
Event Type Linkage - SWETYPV
Similar to the
„Workflow event activation‟,
this configuration for using
the Event Queue needs to be
transported to the QA or
productive system.
© 2011 SAP AG. All rights reserved. 23
Event Queue - SWEQADM
Background job for processing the event queue
The event queue is read by a background job at regular intervals.
The events found are delivered to the registered event receivers.
Configuration setting on each system:
- Schedule background job
- Define operating mode
Specify the events per read access, which are to be processed via the event queue.
Specify the time interval between two read accesses, if there are events in the queue.
Specify the time interval before the event queue is next checked.
This time interval is adhered to if there are no more events after the queue is read.
Hint:
Start with the SAP
default setting for
“Events per minute”
and then increase
this number by 50%
once (or twice)
and test max.
throughput
of tRFC
© 2011 SAP AG. All rights reserved. 24
Simple Example for a Dialog Workitem with Result of BRFplus Decision Tree
© 2011 SAP AG. All rights reserved. 25
BRFplus Button in the Workflow Builder
1.
2.
3.
5.
Manually copy
GUID of
BRFplus Function
BRFplus Workbench
CONTINUE
creates a Task
with BRFplus
button
Click on BRFplus button to open Workbench
4. Generated
Task
© 2011 SAP AG. All rights reserved. 26
BRFplus Workflow Task with
Generated Binding and Generated ABAP Object Class
Look at class
with transaction
SE24 to see how
the Method reads
task container
and calls
BRFplus
function with
import and export
parameters
BRFplus
function
with decision
table and
send email
action
Parameters of BRFplus function
must be based on DDIC elements
© 2011 SAP AG. All rights reserved. 27
Summary “End To End” Process
ABAP Program
calling
BRFplus function
“Check Material”
to trigger
Business Object Events
Event Queue
will spread out
Workflow starts
Business Object Method
to collect data for Workflow Container
and to call BRFplus function “Find Owners”.
Method will also check user and convert
them to Workflow Agents.
Online transaction calling
BRFplus function “Determine BISMT”
Generated Task
based on
generated ABAP Object Class
to call BRFplus function “Send Email”
© 2011 SAP AG. All rights reserved. 28
Summary - BRFplus Terminology compared to Workflow
BRFplus SAP Business Workflow
Function Workflow template
Simulate with trace Test Workflow and look Workflow Log
ABAP procedure to call BRFplus function ABAP program to start Workflow instance
Import parameters in function signature Workflow container elements with import flag
Ruleset
(Each function needs at least one ruleset)
Workflow Builder for Main Workflow
or Sub-Workflow
Context (for each ruleset)
- Click on “Number” to add Variables
Manually add elements to the Workflow container at design-time
Rule
- Ruleset calls one or more rules in sequence
Workflow Step of the type „Activity‟
- Standard Task
Condition to perform rules
- based on variables in context
Condition in the process flow to bypass a step
Expression
(One rule can call many expressions)
- Import parameters from context
- Result changes a variable in context
Standard Task calls method
of Business Object or ABAP Object
- Binding to Workflow Container via
Task Container
Action
- Import parameters from context
- Result has no impact on context
Asynchronous procedure called by Workflow.
Examples: “Send Email”, “Start Workflow”
or “Trigger Event”
Thank You!
Contact information:
Thomas Kosog
Principal Workflow Consultant
SAP Chicago

More Related Content

What's hot

Expanding the capabilities of SAC with App Design
Expanding the capabilities of SAC with App DesignExpanding the capabilities of SAC with App Design
Expanding the capabilities of SAC with App DesignVisual_BI
 
Fund management sap
Fund management   sapFund management   sap
Fund management sapAbiListiyono
 
55811936 product-costing-cost-estimation-in-sap
55811936 product-costing-cost-estimation-in-sap55811936 product-costing-cost-estimation-in-sap
55811936 product-costing-cost-estimation-in-sapPepa Pencheva
 
Project Management on SAP Business One for Consulting and Software Companies
Project Management on SAP Business One for Consulting and Software CompaniesProject Management on SAP Business One for Consulting and Software Companies
Project Management on SAP Business One for Consulting and Software CompaniesBlue Ocean Systems Pte Ltd
 
SAP S/4 HANA - SAP sFIN (Simple Finance) - Financial Reporting and Advanced A...
SAP S/4 HANA - SAP sFIN (Simple Finance) - Financial Reporting and Advanced A...SAP S/4 HANA - SAP sFIN (Simple Finance) - Financial Reporting and Advanced A...
SAP S/4 HANA - SAP sFIN (Simple Finance) - Financial Reporting and Advanced A...Jothi Periasamy
 
S4F55_EN_Col12 SAP Revenue Accounting and.pdf
S4F55_EN_Col12 SAP Revenue Accounting and.pdfS4F55_EN_Col12 SAP Revenue Accounting and.pdf
S4F55_EN_Col12 SAP Revenue Accounting and.pdflakshmi vara
 
ASC 606 - IFRS 15 and SAP RAR
ASC 606 - IFRS 15 and SAP RARASC 606 - IFRS 15 and SAP RAR
ASC 606 - IFRS 15 and SAP RARZak Syed
 
Sap business process flows
Sap business process flowsSap business process flows
Sap business process flowsVerity Solutions
 
Migrating to the SAP Cloud
Migrating to the SAP Cloud Migrating to the SAP Cloud
Migrating to the SAP Cloud Capgemini
 
SAP S_4HANA Migration Cockpit - Deep Dive LTMOM for Direct Transfer.pdf
SAP S_4HANA Migration Cockpit - Deep Dive LTMOM for Direct Transfer.pdfSAP S_4HANA Migration Cockpit - Deep Dive LTMOM for Direct Transfer.pdf
SAP S_4HANA Migration Cockpit - Deep Dive LTMOM for Direct Transfer.pdfssuserf6d533
 
IDOC , ALE ,EDI
IDOC , ALE ,EDIIDOC , ALE ,EDI
IDOC , ALE ,EDIAmit Khari
 
BP_CLD_ENTPR_S4CLD2208_28_Cust_Scope_Pres_EN_XX.pptx
BP_CLD_ENTPR_S4CLD2208_28_Cust_Scope_Pres_EN_XX.pptxBP_CLD_ENTPR_S4CLD2208_28_Cust_Scope_Pres_EN_XX.pptx
BP_CLD_ENTPR_S4CLD2208_28_Cust_Scope_Pres_EN_XX.pptxAlexYuniarto1
 
1NT Webinar_Simple Projects
1NT Webinar_Simple Projects1NT Webinar_Simple Projects
1NT Webinar_Simple ProjectsSHIVA PRASAD
 
SAP ODATA Overview & Guidelines
SAP ODATA Overview & GuidelinesSAP ODATA Overview & Guidelines
SAP ODATA Overview & GuidelinesAshish Saxena
 
S/4 HANA conversion functional value proposition
S/4 HANA conversion functional value propositionS/4 HANA conversion functional value proposition
S/4 HANA conversion functional value propositionVignesh Bhatt
 
Introduction to data migration
Introduction to data migrationIntroduction to data migration
Introduction to data migrationHubert Manduku
 

What's hot (20)

Expanding the capabilities of SAC with App Design
Expanding the capabilities of SAC with App DesignExpanding the capabilities of SAC with App Design
Expanding the capabilities of SAC with App Design
 
Fund management sap
Fund management   sapFund management   sap
Fund management sap
 
SAP ABAP data dictionary
SAP ABAP data dictionarySAP ABAP data dictionary
SAP ABAP data dictionary
 
55811936 product-costing-cost-estimation-in-sap
55811936 product-costing-cost-estimation-in-sap55811936 product-costing-cost-estimation-in-sap
55811936 product-costing-cost-estimation-in-sap
 
Project Management on SAP Business One for Consulting and Software Companies
Project Management on SAP Business One for Consulting and Software CompaniesProject Management on SAP Business One for Consulting and Software Companies
Project Management on SAP Business One for Consulting and Software Companies
 
SAP S/4 HANA - SAP sFIN (Simple Finance) - Financial Reporting and Advanced A...
SAP S/4 HANA - SAP sFIN (Simple Finance) - Financial Reporting and Advanced A...SAP S/4 HANA - SAP sFIN (Simple Finance) - Financial Reporting and Advanced A...
SAP S/4 HANA - SAP sFIN (Simple Finance) - Financial Reporting and Advanced A...
 
S4F55_EN_Col12 SAP Revenue Accounting and.pdf
S4F55_EN_Col12 SAP Revenue Accounting and.pdfS4F55_EN_Col12 SAP Revenue Accounting and.pdf
S4F55_EN_Col12 SAP Revenue Accounting and.pdf
 
SAP workflow events
SAP workflow eventsSAP workflow events
SAP workflow events
 
ASC 606 - IFRS 15 and SAP RAR
ASC 606 - IFRS 15 and SAP RARASC 606 - IFRS 15 and SAP RAR
ASC 606 - IFRS 15 and SAP RAR
 
Sap business process flows
Sap business process flowsSap business process flows
Sap business process flows
 
SAC_Planning.pdf
SAC_Planning.pdfSAC_Planning.pdf
SAC_Planning.pdf
 
Migrating to the SAP Cloud
Migrating to the SAP Cloud Migrating to the SAP Cloud
Migrating to the SAP Cloud
 
SAP S_4HANA Migration Cockpit - Deep Dive LTMOM for Direct Transfer.pdf
SAP S_4HANA Migration Cockpit - Deep Dive LTMOM for Direct Transfer.pdfSAP S_4HANA Migration Cockpit - Deep Dive LTMOM for Direct Transfer.pdf
SAP S_4HANA Migration Cockpit - Deep Dive LTMOM for Direct Transfer.pdf
 
IDOC , ALE ,EDI
IDOC , ALE ,EDIIDOC , ALE ,EDI
IDOC , ALE ,EDI
 
BP_CLD_ENTPR_S4CLD2208_28_Cust_Scope_Pres_EN_XX.pptx
BP_CLD_ENTPR_S4CLD2208_28_Cust_Scope_Pres_EN_XX.pptxBP_CLD_ENTPR_S4CLD2208_28_Cust_Scope_Pres_EN_XX.pptx
BP_CLD_ENTPR_S4CLD2208_28_Cust_Scope_Pres_EN_XX.pptx
 
SAP Activate Aula 3
SAP Activate Aula 3SAP Activate Aula 3
SAP Activate Aula 3
 
1NT Webinar_Simple Projects
1NT Webinar_Simple Projects1NT Webinar_Simple Projects
1NT Webinar_Simple Projects
 
SAP ODATA Overview & Guidelines
SAP ODATA Overview & GuidelinesSAP ODATA Overview & Guidelines
SAP ODATA Overview & Guidelines
 
S/4 HANA conversion functional value proposition
S/4 HANA conversion functional value propositionS/4 HANA conversion functional value proposition
S/4 HANA conversion functional value proposition
 
Introduction to data migration
Introduction to data migrationIntroduction to data migration
Introduction to data migration
 

Similar to 0801 sap business_workflow_and_business_rules_framework_plus_brfplus

How to Improve Performance Testing Using InfluxDB and Apache JMeter
How to Improve Performance Testing Using InfluxDB and Apache JMeterHow to Improve Performance Testing Using InfluxDB and Apache JMeter
How to Improve Performance Testing Using InfluxDB and Apache JMeterInfluxData
 
JBPM5 Community Training Course - Module #1 Introduction
JBPM5 Community Training Course - Module #1 IntroductionJBPM5 Community Training Course - Module #1 Introduction
JBPM5 Community Training Course - Module #1 IntroductionMauricio (Salaboy) Salatino
 
Sap enhancement packages
Sap enhancement packagesSap enhancement packages
Sap enhancement packagesJoyce Maina
 
Fi enhancement technique how-to-guide on the usage of business transaction ...
Fi enhancement technique   how-to-guide on the usage of business transaction ...Fi enhancement technique   how-to-guide on the usage of business transaction ...
Fi enhancement technique how-to-guide on the usage of business transaction ...Rajeev Kumar
 
Fi enhancement technique how-to-guide on the usage of business transaction ...
Fi enhancement technique   how-to-guide on the usage of business transaction ...Fi enhancement technique   how-to-guide on the usage of business transaction ...
Fi enhancement technique how-to-guide on the usage of business transaction ...Kranthi Kumar
 
Lessons learned during SAP CPI and API mgt projects
Lessons learned during SAP CPI and API mgt projects Lessons learned during SAP CPI and API mgt projects
Lessons learned during SAP CPI and API mgt projects Daniel Graversen
 
J11_S4CLD2208_BPD_EN_US.docx
J11_S4CLD2208_BPD_EN_US.docxJ11_S4CLD2208_BPD_EN_US.docx
J11_S4CLD2208_BPD_EN_US.docxArun Obilisetty
 
Thinking Beyond The Possibilities of SAP Event Management with SAP BRF+
Thinking Beyond The Possibilities of SAP Event Management with SAP BRF+Thinking Beyond The Possibilities of SAP Event Management with SAP BRF+
Thinking Beyond The Possibilities of SAP Event Management with SAP BRF+Gopi Chandrakesan
 
Nesma autumn conference - Contracting & Performance management - Cees Kuijpers
Nesma autumn conference - Contracting & Performance management - Cees KuijpersNesma autumn conference - Contracting & Performance management - Cees Kuijpers
Nesma autumn conference - Contracting & Performance management - Cees KuijpersNesma
 
Maintaining aggregates
Maintaining aggregatesMaintaining aggregates
Maintaining aggregatesSirisha Kumari
 
Iwsm2014 e fpa in sap environment (cees kuijpers)
Iwsm2014   e fpa in sap environment (cees kuijpers)Iwsm2014   e fpa in sap environment (cees kuijpers)
Iwsm2014 e fpa in sap environment (cees kuijpers)Nesma
 
Itm110 how does sap solution manager support sap hana
Itm110 how does sap solution manager support sap hanaItm110 how does sap solution manager support sap hana
Itm110 how does sap solution manager support sap hanaOlivier Bilger
 
SAP Innovations:Are you overlooking important functionality in SAP Controlling
SAP Innovations:Are you overlooking important functionality in SAP ControllingSAP Innovations:Are you overlooking important functionality in SAP Controlling
SAP Innovations:Are you overlooking important functionality in SAP ControllingAlice Adams
 
SAP’s innovations – Are you overlooking important functionality in SAP Contro...
SAP’s innovations – Are you overlooking important functionality in SAP Contro...SAP’s innovations – Are you overlooking important functionality in SAP Contro...
SAP’s innovations – Are you overlooking important functionality in SAP Contro...John Jordan
 
CO_TM_Controlling_co-om Master Data .pdf
CO_TM_Controlling_co-om Master Data .pdfCO_TM_Controlling_co-om Master Data .pdf
CO_TM_Controlling_co-om Master Data .pdfssuser878ec2
 
Streamline your business processes and enhance productivity by using jBPM
Streamline your business processes and enhance productivity by using jBPMStreamline your business processes and enhance productivity by using jBPM
Streamline your business processes and enhance productivity by using jBPMKris Verlaenen
 

Similar to 0801 sap business_workflow_and_business_rules_framework_plus_brfplus (20)

How to Improve Performance Testing Using InfluxDB and Apache JMeter
How to Improve Performance Testing Using InfluxDB and Apache JMeterHow to Improve Performance Testing Using InfluxDB and Apache JMeter
How to Improve Performance Testing Using InfluxDB and Apache JMeter
 
JBPM5 Community Training Course - Module #1 Introduction
JBPM5 Community Training Course - Module #1 IntroductionJBPM5 Community Training Course - Module #1 Introduction
JBPM5 Community Training Course - Module #1 Introduction
 
About work flow
About work flowAbout work flow
About work flow
 
Sap enhancement packages
Sap enhancement packagesSap enhancement packages
Sap enhancement packages
 
Fi enhancement technique how-to-guide on the usage of business transaction ...
Fi enhancement technique   how-to-guide on the usage of business transaction ...Fi enhancement technique   how-to-guide on the usage of business transaction ...
Fi enhancement technique how-to-guide on the usage of business transaction ...
 
Fi enhancement technique how-to-guide on the usage of business transaction ...
Fi enhancement technique   how-to-guide on the usage of business transaction ...Fi enhancement technique   how-to-guide on the usage of business transaction ...
Fi enhancement technique how-to-guide on the usage of business transaction ...
 
Lessons learned during SAP CPI and API mgt projects
Lessons learned during SAP CPI and API mgt projects Lessons learned during SAP CPI and API mgt projects
Lessons learned during SAP CPI and API mgt projects
 
J11_S4CLD2208_BPD_EN_US.docx
J11_S4CLD2208_BPD_EN_US.docxJ11_S4CLD2208_BPD_EN_US.docx
J11_S4CLD2208_BPD_EN_US.docx
 
Thinking Beyond The Possibilities of SAP Event Management with SAP BRF+
Thinking Beyond The Possibilities of SAP Event Management with SAP BRF+Thinking Beyond The Possibilities of SAP Event Management with SAP BRF+
Thinking Beyond The Possibilities of SAP Event Management with SAP BRF+
 
Nesma autumn conference - Contracting & Performance management - Cees Kuijpers
Nesma autumn conference - Contracting & Performance management - Cees KuijpersNesma autumn conference - Contracting & Performance management - Cees Kuijpers
Nesma autumn conference - Contracting & Performance management - Cees Kuijpers
 
Bte
BteBte
Bte
 
Bte
BteBte
Bte
 
Maintaining aggregates
Maintaining aggregatesMaintaining aggregates
Maintaining aggregates
 
Iwsm2014 e fpa in sap environment (cees kuijpers)
Iwsm2014   e fpa in sap environment (cees kuijpers)Iwsm2014   e fpa in sap environment (cees kuijpers)
Iwsm2014 e fpa in sap environment (cees kuijpers)
 
Itm110 how does sap solution manager support sap hana
Itm110 how does sap solution manager support sap hanaItm110 how does sap solution manager support sap hana
Itm110 how does sap solution manager support sap hana
 
SAP Innovations:Are you overlooking important functionality in SAP Controlling
SAP Innovations:Are you overlooking important functionality in SAP ControllingSAP Innovations:Are you overlooking important functionality in SAP Controlling
SAP Innovations:Are you overlooking important functionality in SAP Controlling
 
SAP’s innovations – Are you overlooking important functionality in SAP Contro...
SAP’s innovations – Are you overlooking important functionality in SAP Contro...SAP’s innovations – Are you overlooking important functionality in SAP Contro...
SAP’s innovations – Are you overlooking important functionality in SAP Contro...
 
Abap for sd consultatnt
Abap for sd consultatntAbap for sd consultatnt
Abap for sd consultatnt
 
CO_TM_Controlling_co-om Master Data .pdf
CO_TM_Controlling_co-om Master Data .pdfCO_TM_Controlling_co-om Master Data .pdf
CO_TM_Controlling_co-om Master Data .pdf
 
Streamline your business processes and enhance productivity by using jBPM
Streamline your business processes and enhance productivity by using jBPMStreamline your business processes and enhance productivity by using jBPM
Streamline your business processes and enhance productivity by using jBPM
 

Recently uploaded

Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationSlibray Presentation
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...Fwdays
 
Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Neo4j
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubKalema Edgar
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersThousandEyes
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxOnBoard
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):comworks
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...shyamraj55
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Enterprise Knowledge
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
APIForce Zurich 5 April Automation LPDG
APIForce Zurich 5 April  Automation LPDGAPIForce Zurich 5 April  Automation LPDG
APIForce Zurich 5 April Automation LPDGMarianaLemus7
 

Recently uploaded (20)

Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck Presentation
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
 
Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding Club
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
DMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special EditionDMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special Edition
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptx
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
APIForce Zurich 5 April Automation LPDG
APIForce Zurich 5 April  Automation LPDGAPIForce Zurich 5 April  Automation LPDG
APIForce Zurich 5 April Automation LPDG
 

0801 sap business_workflow_and_business_rules_framework_plus_brfplus

  • 1. SAP Business Workflow and Business Rules Framework Plus - BRFplus Thomas Kosog ASUG Annual Conference Session 0801 May 14, 2012
  • 2. © 2011 SAP AG. All rights reserved. 2 Agenda - SAP Business Workflow and BRFplus • Overview of an example material master process • Overview of BRFplus (recommended release level: NW 7.02 SP 11) • BRFplus in Detail • Function, Ruleset, Rule, Expression, Action • ABAP program to start the process • Business Object Type • Event Queue • Steps in the SAP Business Workflow • BOR method with BRFplus function call • Generated BRFplus Task with generated ABAP Object Class • Summary
  • 3. © 2011 SAP AG. All rights reserved. 3 Example for a Material Master Workflow and BRF plus ABAP program to call BRF plus function “Check Material” -Select materials from data base using field MARA-BISMT and MARA_MTART - Loop over result and filter via Material Class and Material Type in Decision Table - Trigger Business Object Event BUS1001006 – Started_By_BRFplus Hint: Use Event Queue to avoid system overload Workflow Container - Material-Number - Material-Type - Unit of Measure - Old Material - Industry - Material Owners Background Step “ZB1001006 - Get Material data and find Material Owner” Call BRF plus function “Find Approvers” with Decision Table (Material Type & Branch  Material Owner) Workflow WS97300254 Dialog Step for Material Owner with Attachment – Display Material. BOR method calls BRF plus function “Determine BISMT” - Decision Tree - Present result in Pop-Up with suggested BISMT value Background Step Call BAPI to add BISMT to Material -Raise temporary ERROR, if it fails Generated BRFplus Task “Send Email” Material Owner provided value for BISMT
  • 5. © 2011 SAP AG. All rights reserved. 5 BRFplus Overview BRFplus workbench: - Simulate Function Input via ABAP Program to call a BRFplus function Input via generated Web Service Function with Signature (Input data and result) BRFplus Application Ruleset (One or more)Context: Function Signature and additional Variables Sequential Rules to implement Business Logic Perform Action, like “Send email”, “Start Workflow”, “Trigger Event” Expressions, like Data Base Look Up, Loop, Decision Table, Decision Tree, Formula After simulation: Look at result and trace in the BRFplus WorkbenchRead Read and Update Returned Result
  • 6. © 2011 SAP AG. All rights reserved. 6 Transaction “BRFplus” – Call Web Browser with BRFplus Workbench Finishing Steps - SAVE - CHECK - ACTIVATE  BRFplus is generating ABAP objects Called from method in Workflow dialog step Called from method in Workflow background step Called from Program to start Workflow Active Indicator Switch to EDIT mode for more functionality Right click to get menu
  • 7. © 2011 SAP AG. All rights reserved. 7 BRFplus Function GUID used in ABAP program to call BRFplus function Import Export Drop Down Menu Test
  • 8. © 2011 SAP AG. All rights reserved. 8 Simulation of a BRFplus function (Test) Trace shows result of every step Note: This event did not occur yet, since the step to call the ABAP statement “Commit Work” was not added to this BRFplus function yet.
  • 9. © 2011 SAP AG. All rights reserved. 9 BRFplus Data Element and “Where Used List “ BRFplus “Binding” points to DDIC element. You can also define elements on BRFplus delivered types: - Text, Amount, Boolean, Number, Quantity or Time-Point Signature
  • 10. © 2011 SAP AG. All rights reserved. 10 Ruleset defined in BRFplus Function A BRFplus function needs at least one ruleset. Each ruleset has one or more rules. A ruleset is using the signature of the BRFplus function and can add additional variables to the context Hint: Top-Down Modeling Approach – Create the next “lower” level when and where you need it
  • 11. © 2011 SAP AG. All rights reserved. 11 Ruleset and Rules Click on the “number” in front of the variable to add more Context Elements Example: “Material-List” to carry result of rule-1 into rule-2 Rules are called sequentially BRFplus expression for a data base select statement - Result: Material-List Complex rule with loop, decision table and action to trigger Workflow Event
  • 12. © 2011 SAP AG. All rights reserved. 12 Rule with Expression – Decision Table The Material List was created by the previous rule, which called an expression to perform a data base look up. The Material-Group and Industry are a part of the structure Z_MATERIAL and are used in the decision table Decision Table
  • 13. © 2011 SAP AG. All rights reserved. 13 Action Predefined BRFplus action for Workflow - Start Workflow Instance - Trigger Object Event Hint: It is better for the system performance not to start too many workflow instances in a short time  Trigger Events and use Event Queue Option to add values to predefined event parameters
  • 14. © 2011 SAP AG. All rights reserved. 14 Decision Table to Return Users BRFplus function to find users - Context - Ruleset - Rule - Expression with decision table returning a list of users - Check user validity and convert into Workflow Agents in following rule or calling ABAP method
  • 15. © 2011 SAP AG. All rights reserved. 15 Decision Tree to suggest Value for BISMT Find BISMT Value based on - Industry (Branch) - Unit of Measure - Material Type Industry UoM M Others Type BISMT = Goods FERT Others BISMT = Item Type BISMT = Service FERT Others BISMT = Component KG Others Hint: This is only an example. This is NOT how SAP recommends to use the field MARA_BISMT BISMT = Others
  • 17. © 2011 SAP AG. All rights reserved. 17 Summary Overview for the Start Process ABAP program BRFplus function BRFplus Expression Workflow WS97300254 Workflow - Container BOR Event Event Queue Job to run Event Queue BRFplus Ruleset BRFplus Rule MARABRFplus Action BRFplus Application Read
  • 18. © 2011 SAP AG. All rights reserved. 18 Business Object Type – SW01 ZB1001006 is a sub-object type of Business Object BUS1001006 with a system-wide delegation Hint: BRFplus functions can also be called in virtual attributes and functional methods BAPI call Call BRFplus function Triggered by an Action from within a BRFplus function
  • 19. © 2011 SAP AG. All rights reserved. 19 Example Program to Start the Process – SE38 Hint: Set a breakpoint and run the program to see the ABAP code, which was generated by BRFplus Each BRFplus function has its own unique GUID
  • 20. © 2011 SAP AG. All rights reserved. 20 BOR Method calling a BRFplus function GUID of the BRFplus function to find Material Owners This BRFplus function provides a result. These users need to be checked and changed into Workflow Agents. If no workflow agent could be determined, then an exception handler could be added, a Workflow error could be raised or the workitem could be routed to all possible agents of the dialog step.
  • 21. © 2011 SAP AG. All rights reserved. 21 Event Trace - SWEL If the BRFplus function was only simulated, then this list is empty This snap shot was taken, after the Start Program was called This snap shot was taken after the “event-queue” job was started
  • 22. © 2011 SAP AG. All rights reserved. 22 Event Type Linkage - SWETYPV Similar to the „Workflow event activation‟, this configuration for using the Event Queue needs to be transported to the QA or productive system.
  • 23. © 2011 SAP AG. All rights reserved. 23 Event Queue - SWEQADM Background job for processing the event queue The event queue is read by a background job at regular intervals. The events found are delivered to the registered event receivers. Configuration setting on each system: - Schedule background job - Define operating mode Specify the events per read access, which are to be processed via the event queue. Specify the time interval between two read accesses, if there are events in the queue. Specify the time interval before the event queue is next checked. This time interval is adhered to if there are no more events after the queue is read. Hint: Start with the SAP default setting for “Events per minute” and then increase this number by 50% once (or twice) and test max. throughput of tRFC
  • 24. © 2011 SAP AG. All rights reserved. 24 Simple Example for a Dialog Workitem with Result of BRFplus Decision Tree
  • 25. © 2011 SAP AG. All rights reserved. 25 BRFplus Button in the Workflow Builder 1. 2. 3. 5. Manually copy GUID of BRFplus Function BRFplus Workbench CONTINUE creates a Task with BRFplus button Click on BRFplus button to open Workbench 4. Generated Task
  • 26. © 2011 SAP AG. All rights reserved. 26 BRFplus Workflow Task with Generated Binding and Generated ABAP Object Class Look at class with transaction SE24 to see how the Method reads task container and calls BRFplus function with import and export parameters BRFplus function with decision table and send email action Parameters of BRFplus function must be based on DDIC elements
  • 27. © 2011 SAP AG. All rights reserved. 27 Summary “End To End” Process ABAP Program calling BRFplus function “Check Material” to trigger Business Object Events Event Queue will spread out Workflow starts Business Object Method to collect data for Workflow Container and to call BRFplus function “Find Owners”. Method will also check user and convert them to Workflow Agents. Online transaction calling BRFplus function “Determine BISMT” Generated Task based on generated ABAP Object Class to call BRFplus function “Send Email”
  • 28. © 2011 SAP AG. All rights reserved. 28 Summary - BRFplus Terminology compared to Workflow BRFplus SAP Business Workflow Function Workflow template Simulate with trace Test Workflow and look Workflow Log ABAP procedure to call BRFplus function ABAP program to start Workflow instance Import parameters in function signature Workflow container elements with import flag Ruleset (Each function needs at least one ruleset) Workflow Builder for Main Workflow or Sub-Workflow Context (for each ruleset) - Click on “Number” to add Variables Manually add elements to the Workflow container at design-time Rule - Ruleset calls one or more rules in sequence Workflow Step of the type „Activity‟ - Standard Task Condition to perform rules - based on variables in context Condition in the process flow to bypass a step Expression (One rule can call many expressions) - Import parameters from context - Result changes a variable in context Standard Task calls method of Business Object or ABAP Object - Binding to Workflow Container via Task Container Action - Import parameters from context - Result has no impact on context Asynchronous procedure called by Workflow. Examples: “Send Email”, “Start Workflow” or “Trigger Event”
  • 29. Thank You! Contact information: Thomas Kosog Principal Workflow Consultant SAP Chicago