4 Replies Latest reply on Jan 14, 2015 1:47 AM by narsi.chowdary

    creating the dynamic bpmn file

    narsi.chowdary

      Hi All,

       

      as part of my requirement i need to create bpmn file based on user process steps by dynamically by using java classes. i found RuleFlowProcessFactory API classes in goog, by using that i an able to create the bpmn file. but here my problem to create the bpmn file with human task and business rule task. for creating the Business rule task i have used ruleSetNode in RuleFlowProcessFactory class.

       

      as part of business rule task i need to specify some input and output variables, here i did't find any methods in class to pass the variables.

       

      please help any one having the idea.

        • 1. Re: creating the dynamic bpmn file
          krisverlaenen

          The factory doesn't have methods for IOmapping yet, but you could use on entry scripts to insert objects into the working memory directly instead.

           

          Kris

          1 of 1 people found this helpful
          • 2. Re: creating the dynamic bpmn file
            narsi.chowdary

            Thanks  Kris,

             

            if i am creating the BPMN file Manually then i can able to set the entry scripts to insert the object for RuleSetNode. but i a creating the BPMN file Dynamically. and also i have cross checked the API for RuleSetNode class don't have function to pass the Entry scripts.but HumanTaskNode having the same.

             

            please help me to supported API for this issue.

             

            Ex:

            factory

              .ruleSetNode(currentActionId).name(ruleName)

              .ruleFlowGroup(ruleGroupName).done()

              .connection(prevActionId,currentActionId);

             

            factory

              .humanTaskNode(currentActionId).actorId("#{username}")

              .name(processNames.get(i)).taskName(processNames.get(i))

              .onEntryAction("http://www.java.com/java","System.out.println("+processNames.get(i)+");").done()

              .connection(prevActionId,currentActionId);

            • 3. Re: creating the dynamic bpmn file
              krisverlaenen

              At the beginning, RuleSetNode didn't support on-entry / exit scripts yet, it seems the fluent api wasn't updated when they were added.  Could you open a JIRA or Bugzilla for this?  Should be trivial to add, might be easy to even do a pull request

               

              Kris

              1 of 1 people found this helpful
              • 4. Re: creating the dynamic bpmn file
                narsi.chowdary

                ok thanks kris.. i will open the JIRA for this issue..