Package org.jbpm.graph.exe

Examples of org.jbpm.graph.exe.ProcessInstance.end()


    {
      // End the process instance and any open tokens
      // TODO: Think about maybe canceling sub processes?
      cancelToken(pi.getRootToken());

      pi.end();

      log.info("finished process cancellation");
    }
    catch (RuntimeException ex)
    {
View Full Code Here


                    task.cancel();
                }
                context.addSuccessMessage("Token ended");
            } else if (value instanceof ProcessInstance) {
                final ProcessInstance processInstance = ((ProcessInstance) value);
                processInstance.end();
                for (TaskInstance task : (Collection<TaskInstance>) processInstance.getTaskMgmtInstance().getUnfinishedTasks(processInstance.getRootToken())) {
                    task.setSignalling(false);
                    task.cancel();
                }
                context.addSuccessMessage("Process instance cancelled");
View Full Code Here

    processInstance.signal();
    jbpmContext.save(processInstance);
   
    JbpmContext concurrentContext = jbpmConfiguration.createJbpmContext();
    ProcessInstance sameProcessInstanceInDifferentSession = concurrentContext.loadProcessInstance(processInstance.getId());
    sameProcessInstanceInDifferentSession.end();
    concurrentContext.save(sameProcessInstanceInDifferentSession);
    log.debug("closing concurrent context");
    concurrentContext.close();
   
    try {
View Full Code Here

  }

  public void testProcessInstanceEndLog() {
    ProcessDefinition processDefinition = new ProcessDefinition();
    ProcessInstance processInstance = new ProcessInstance(processDefinition);
    processInstance.end();
    LoggingInstance loggingInstance = processInstance.getLoggingInstance();
    List processInstanceEndLogs = loggingInstance.getLogs(ProcessInstanceEndLog.class);
    assertEquals(1, processInstanceEndLogs.size());
    ProcessInstanceEndLog processInstanceEndLog = (ProcessInstanceEndLog) processInstanceEndLogs.get(0);
    assertSame(processInstance.getRootToken(), processInstanceEndLog.getToken());
View Full Code Here

        // Execute it to the full (using the super class)
        log.debug("Executing WorkflowInstance");
        super.executeFullWorkflow(newInstance);

        newInstance.end();
        //inProcessInstance.removeInstance();
       
        log.debug("");
        log.debug("");
        log.debug("Complete Message Cycle:" + i);
View Full Code Here

    // TODO: remove logging!
    try {
      // End the process instance and any open tokens
      // TODO: better implementation, see
      // http://intranet.computation.de/bugs/view_bug.php?bug_id=295
      pi.end();
 
      cancelToken(pi.getRootToken());
      cancelTokens(pi.getRootToken().getChildren().values());
 
      if (cancelSubProcesses)
View Full Code Here

      // see http://intranet.computation.de/bugs/view_bug.php?bug_id=295
 
      cancelToken(pi.getRootToken());
      cancelTokens(pi.getRootToken().getChildren().values());
 
            pi.end();

            if (cancelSubProcesses)
        cancelSubProcesses(processIdToCancel);

      log.info("finished process cancellation");
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.