6 Replies Latest reply on Apr 2, 2007 5:29 AM by amnas

    JBPM Mulitple Processes

    ibamsey

      I have a process in which I want to start 'n' sub processes. i.e. at some stage in my main process, the user is able to initiate 1 or more sub-processes. Once all these processes are complete, the main process is ready to move on.

      I can see how to create a fixed number of sub-processes using a fork, but what approach should be used to create any number sub-processes?

      As an example, a user would like to send a draft document to any number of 'editors' for checking. Once all the editors have completed their work, the document can be finalised.

      Ian

        • 1. Re: JBPM Mulitple Processes
          bazoo

          Hi Ian,

          I need to do the same thing - did you ever find a solution?

          Cheers
          Matt

          • 2. Re: JBPM Mulitple Processes
            kukeltje

            By implementing a custom 'forkhandler' you can achieve this kind of behaviour. More info than this is not in my head, so you have to search the forum a little (afaik there has been some discussion of this before, but I am not sure)

            • 3. Re: JBPM Mulitple Processes
              kukeltje

              isn't there a JSR for pluggable scripting? or is this on the wrong level? (me not specialist on this, me stupid ;-))

              • 4. Re: JBPM Mulitple Processes

                 

                "kukeltje" wrote:
                isn't there a JSR for pluggable scripting? or is this on the wrong level? (me not specialist on this, me stupid ;-))


                "Wrong thread?" said Ed.

                • 5. Re: JBPM Mulitple Processes
                  ibamsey

                  Yes, a custom folk might work. I have considered this idea.

                  I can imagine having a folk, one transition to the process I want to run "n" times (this would exit to a folk), and the other transition to a decision. The decision would be "More" or "No More". The More output from the decision would loop back into the folk, and the No More would go to the join.

                  The idea above would allow the user to start "n" sub-process by selecting the More transition from the decision. The only problem with the above scheme, is that each time More is selected, the new sub-process would be on the child token, when it would need to be upon the parent.

                  I suppose this could be coded in a custom folk, although is seems a hack.

                  It seems to me that this is a common pattern? Is there not a better way?

                  • 6. Re: JBPM Mulitple Processes
                    amnas

                    Hi!

                    Have a look at this : http://wiki.jboss.org/wiki/Wiki.jsp?page=MultiChoiceForkAH

                    Hold on!


                    :)

                    AMNAS.