[jboss-dev-forums] [jBPM Development] - Re: Migrate app to jBPM - multiple starts

jinlin ning do-not-reply at jboss.com
Mon Nov 15 09:13:34 EST 2010


jinlin ning [http://community.jboss.org/people/ningjinlin] created the discussion

"Re: Migrate app to jBPM - multiple starts"

To view the discussion, visit: http://community.jboss.org/message/571231#571231

--------------------------------------------------------------
This my way to start up in the middle:

step 1:
save the Variable in the map when I star the processInstance :

map.put("startInMiddle", true);
this.executionService.startProcessInstanceByKey("chooseSite",map);

step 2:

add the assign-handdler or event-listener to all the activity you don't want to handle

like this:
@Override
    public void assign(Assignable assignable,
            OpenExecution execution) throws Exception {
         ExecutionImpl e = (ExecutionImpl) execution;
         e.getVariable("starInMiddle").toString().equals(true){
               e.execution).end();
          }       
    }
--------------------------------------------------------------

Reply to this message by going to Community
[http://community.jboss.org/message/571231#571231]

Start a new discussion in jBPM Development at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2035]

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-dev-forums/attachments/20101115/361589bc/attachment.html 


More information about the jboss-dev-forums mailing list