Quantcast
Channel: SCN : All Content - SAP Business Process Management
Viewing all articles
Browse latest Browse all 887

Step by Step Process for Creating a Simple BRM(Business Rules Management) Project and Connectivity with BPM with Web Service

$
0
0

Hi All,

  This Document will help you to create the BRM Proect and can be use as web service in BPM

 

Step by Step Process for Creating a Simple BRM(Business Rules Management) Project and
Connectivity with BPM with Web Service:

I am using NWDS 7.3

 

1. Open NWDS – Go To File – new –others-Development Infrastructure – Select the Development
Component – Next – Select Rules Composer – Next –LocalDevelopment-Select My
Component-Next -
Name your Development Component
I gave name : brm/test

Click on Next – Finish

      Click yes to Confimation Perspective PoP Up

 

After Successfully Completionof  your test BRM  Project ir will look like:

1.png

 

2. Now we have to create a Ruleset for creation of Rules

      Expand your BRM Project – Right click on Rules Modeling – Select New Flow Ruleset

2.png

 

Give name for Your RuleSet

3.png


3. After Creating Rule set your DC look like this :

5.png


After Creation of RuleSet we have to create XML Schema:

      Expand src folder in the BRM DC – Right click on wsdl – New – XML Schema

6.png

 

 

Name your XSD Schema and click finish (in my case I created AgeValidation.xsd)

 

7.png

 

4. Open your XSD element by double click on it , it will look like

8.png

 

   Now we have to create the element in the XSD Element :

  1. 1.UserAge  ; Integer Type
  2. 2.UserCatagory  : String Type

 

     For this Right click on Types – Add Simple type

9.png

 

 

 

5. After Creation Simple type you can see it in XSD Types :

10.png

 

 

  After this create Elements and select the type Simple Type (which we created)

  Right click on Element – Add Element

  After creating Element you can see like this:

 

11.png

  Now we have to add these element in our Project :

  Open the Project Resources

 

  Expand
   Rules Modeling – Right click on Project Resources – open

 

12.png


   7. You will see the below screen after open the Project Resources

 

13.png

 

 

   8. Now go to Alias Tab – Add –Left click on Add – choose XSD Element

       (Before this save your Project)

14.png

 

 

    9. You can see here your created XSD Elements : (Selectthe Element one by one for your Project) After selection the Added XSD element look like this :

 

15.png

 

 

    Now for Rules we have to create a Decision Table for our Project

    (for more Detail about Decision Table use this SAP help Link :      http://help.sap.com/saphelp_nw73/helpdata/en/d2/df35008f5d423180d57257c5570093/content.htm)

     Expand Your Ruleset – Right Click on Decision Table – Select New Decision Table

 

16.png


     Give Name to your Decision Table and Comments (optional) – and click Next

 

17.png

 

 

 

   10.  Now Select the Condition for your Decision Table (you can see the Aliases  here)

          Double click on aliases to select and it will look like this (select the check box for ‘Table has Horizontal Condition’):

 

18.png

     Click next – now select the action (what action to be performed in Decision Table)

     Choose category and you can see it in selected Actions ;

 

19.png

 

 

 

     Click on finish – Expand Decision Table Folder and Double click on your Decsion Table you can see the created decision table:

20.png


     11. We can do editing in the decision table :

21.png

 

21.png

 

 

     The above condition check the input value for Age and if Age is less than 18 then it will return result as ‘Child’

     We can add one more condition in decision table

     For Adding one more condition right click on the values as follows:

 

22.png

23.png


     12. After creation of Decision Table we have to create a flow for our BRM project :

        Expand your Ruleset – Right Click – New Flow

 

24.png

 

25.png

 

 

26.png

 

 

     13. Now the above flow is having the start and end points
          we can add our decision table to perform the action after starting the flow , for
         adding drag the decision table from Palette (in Right hand Side from Activities)And
        give  the connections as following(first
        remove the previous connection between start and end points):

 

27.png

 

 

 

     Now go to Properties of Decision Table Activity and browse for your Decision Table

 

28.png

 

29.png

 

 

 

     14. The flow is ready to use and we have to exposed the web service so that we can use it into our BPM project :

          Right Click on your Flow Ruleset – web service – Create WSDL Artifacts

 

30.png

 

 

 

     15. Give Name to your Web Service – click next –and choose Input and output for web Service –Click Finish:

          Now Build and Deploy your BRM DC and after Successfully Deployed you can use this
          web service in BPM Project (Publish the ws in Service Registery and configured it)

 

If you want to use this web service in BPM then you have to create Service Interface for this in BPM Project and import the web service and then you  can use this service interface into automated activity

 

 

Thanks
Rohit


Viewing all articles
Browse latest Browse all 887

Trending Articles