Search in sources :

Example 6 with ProcessNodeTriggeredEvent

use of org.kie.api.event.process.ProcessNodeTriggeredEvent in project jbpm by kiegroup.

the class ActivityTest method testSubProcessWithTerminateEndEventProcessScope.

@Test
public void testSubProcessWithTerminateEndEventProcessScope() throws Exception {
    KieBase kbase = createKnowledgeBase("BPMN2-SubProcessWithTerminateEndEventProcessScope.bpmn2");
    ksession = createKnowledgeSession(kbase);
    final List<String> list = new ArrayList<String>();
    ksession.addEventListener(new DefaultProcessEventListener() {

        public void afterNodeTriggered(ProcessNodeTriggeredEvent event) {
            list.add(event.getNodeInstance().getNodeName());
        }
    });
    ProcessInstance processInstance = ksession.startProcess("SubProcessTerminate");
    assertProcessInstanceCompleted(processInstance);
    assertEquals(5, list.size());
}
Also used : KieBase(org.kie.api.KieBase) ArrayList(java.util.ArrayList) DefaultProcessEventListener(org.kie.api.event.process.DefaultProcessEventListener) ProcessNodeTriggeredEvent(org.kie.api.event.process.ProcessNodeTriggeredEvent) ProcessInstance(org.kie.api.runtime.process.ProcessInstance) WorkflowProcessInstance(org.kie.api.runtime.process.WorkflowProcessInstance) Test(org.junit.Test)

Example 7 with ProcessNodeTriggeredEvent

use of org.kie.api.event.process.ProcessNodeTriggeredEvent in project jbpm by kiegroup.

the class ActivityTest method testMinimalProcessMetaData.

@Test
public void testMinimalProcessMetaData() throws Exception {
    KieBase kbase = createKnowledgeBase("BPMN2-MinimalProcessMetaData.bpmn2");
    ksession = createKnowledgeSession(kbase);
    final List<String> list1 = new ArrayList<String>();
    final List<String> list2 = new ArrayList<String>();
    final List<String> list3 = new ArrayList<String>();
    final List<String> list4 = new ArrayList<String>();
    ksession.addEventListener(new DefaultProcessEventListener() {

        public void beforeNodeTriggered(ProcessNodeTriggeredEvent event) {
            logger.debug("before node");
            Map<String, Object> metaData = event.getNodeInstance().getNode().getMetaData();
            for (Map.Entry<String, Object> entry : metaData.entrySet()) {
                logger.debug(entry.getKey() + " " + entry.getValue());
            }
            String customTag = (String) metaData.get("customTag");
            if (customTag != null) {
                list1.add(customTag);
            }
            String customTag2 = (String) metaData.get("customTag2");
            if (customTag2 != null) {
                list2.add(customTag2);
            }
        }

        public void afterVariableChanged(ProcessVariableChangedEvent event) {
            logger.debug("after variable");
            VariableScope variableScope = (VariableScope) ((org.jbpm.process.core.impl.ProcessImpl) event.getProcessInstance().getProcess()).resolveContext(VariableScope.VARIABLE_SCOPE, event.getVariableId());
            if (variableScope == null) {
                return;
            }
            Map<String, Object> metaData = variableScope.findVariable(event.getVariableId()).getMetaData();
            for (Map.Entry<String, Object> entry : metaData.entrySet()) {
                logger.debug(entry.getKey() + " " + entry.getValue());
            }
            String customTag = (String) metaData.get("customTagVar");
            if (customTag != null) {
                list3.add(customTag);
            }
        }

        public void afterProcessStarted(ProcessStartedEvent event) {
            logger.debug("after process");
            Map<String, Object> metaData = event.getProcessInstance().getProcess().getMetaData();
            for (Map.Entry<String, Object> entry : metaData.entrySet()) {
                logger.debug(entry.getKey() + " " + entry.getValue());
            }
            String customTag = (String) metaData.get("customTagProcess");
            if (customTag != null) {
                list4.add(customTag);
            }
        }
    });
    Map<String, Object> params = new HashMap<String, Object>();
    params.put("x", "krisv");
    ProcessInstance processInstance = ksession.startProcess("Minimal", params);
    assertProcessInstanceCompleted(processInstance);
    assertEquals(3, list1.size());
    assertEquals(2, list2.size());
    assertEquals(1, list3.size());
    assertEquals(1, list4.size());
}
Also used : ProcessVariableChangedEvent(org.kie.api.event.process.ProcessVariableChangedEvent) HashMap(java.util.HashMap) ArrayList(java.util.ArrayList) ProcessStartedEvent(org.kie.api.event.process.ProcessStartedEvent) KieBase(org.kie.api.KieBase) DefaultProcessEventListener(org.kie.api.event.process.DefaultProcessEventListener) ProcessNodeTriggeredEvent(org.kie.api.event.process.ProcessNodeTriggeredEvent) ProcessInstance(org.kie.api.runtime.process.ProcessInstance) WorkflowProcessInstance(org.kie.api.runtime.process.WorkflowProcessInstance) Map(java.util.Map) HashMap(java.util.HashMap) VariableScope(org.jbpm.process.core.context.variable.VariableScope) Test(org.junit.Test)

Example 8 with ProcessNodeTriggeredEvent

use of org.kie.api.event.process.ProcessNodeTriggeredEvent in project jbpm by kiegroup.

the class ProcessEventSupportTest method testProcessEventListenerWithEvent.

@Test
public void testProcessEventListenerWithEvent() throws Exception {
    InternalKnowledgeBase kbase = KnowledgeBaseFactory.newKnowledgeBase();
    // create a simple package with one process to test the events
    final InternalKnowledgePackage pkg = new KnowledgePackageImpl("org.drools.test");
    RuleFlowProcess process = new RuleFlowProcess();
    process.setId("org.drools.core.process.event");
    process.setName("Event Process");
    StartNode startNode = new StartNode();
    startNode.setName("Start");
    startNode.setId(1);
    process.addNode(startNode);
    ActionNode actionNode = new ActionNode();
    actionNode.setName("Print");
    DroolsAction action = new DroolsConsequenceAction("java", null);
    action.setMetaData("Action", new Action() {

        public void execute(ProcessContext context) throws Exception {
            logger.info("Executed action");
        }
    });
    actionNode.setAction(action);
    actionNode.setId(2);
    process.addNode(actionNode);
    new ConnectionImpl(startNode, Node.CONNECTION_DEFAULT_TYPE, actionNode, Node.CONNECTION_DEFAULT_TYPE);
    EventNode eventNode = new EventNode();
    eventNode.setName("Event");
    eventNode.setId(3);
    List<EventFilter> filters = new ArrayList<EventFilter>();
    EventTypeFilter filter = new EventTypeFilter();
    filter.setType("signal");
    filters.add(filter);
    eventNode.setEventFilters(filters);
    process.addNode(eventNode);
    new ConnectionImpl(actionNode, Node.CONNECTION_DEFAULT_TYPE, eventNode, Node.CONNECTION_DEFAULT_TYPE);
    EndNode endNode = new EndNode();
    endNode.setName("End");
    endNode.setId(4);
    process.addNode(endNode);
    new ConnectionImpl(eventNode, Node.CONNECTION_DEFAULT_TYPE, endNode, Node.CONNECTION_DEFAULT_TYPE);
    pkg.addProcess(process);
    List<KiePackage> pkgs = new ArrayList<KiePackage>();
    pkgs.add(pkg);
    kbase.addPackages(pkgs);
    KieSession session = kbase.newKieSession();
    final List<ProcessEvent> processEventList = new ArrayList<ProcessEvent>();
    final ProcessEventListener processEventListener = new ProcessEventListener() {

        public void afterNodeLeft(ProcessNodeLeftEvent event) {
            processEventList.add(event);
        }

        public void afterNodeTriggered(ProcessNodeTriggeredEvent event) {
            processEventList.add(event);
        }

        public void afterProcessCompleted(ProcessCompletedEvent event) {
            processEventList.add(event);
        }

        public void afterProcessStarted(ProcessStartedEvent event) {
            processEventList.add(event);
        }

        public void beforeNodeLeft(ProcessNodeLeftEvent event) {
            processEventList.add(event);
        }

        public void beforeNodeTriggered(ProcessNodeTriggeredEvent event) {
            processEventList.add(event);
        }

        public void beforeProcessCompleted(ProcessCompletedEvent event) {
            processEventList.add(event);
        }

        public void beforeProcessStarted(ProcessStartedEvent event) {
            processEventList.add(event);
        }

        public void beforeVariableChanged(ProcessVariableChangedEvent event) {
            processEventList.add(event);
        }

        public void afterVariableChanged(ProcessVariableChangedEvent event) {
            processEventList.add(event);
        }
    };
    session.addEventListener(processEventListener);
    // execute the process
    ProcessInstance pi = session.startProcess("org.drools.core.process.event");
    pi.signalEvent("signal", null);
    assertEquals(20, processEventList.size());
    assertEquals("org.drools.core.process.event", ((ProcessStartedEvent) processEventList.get(0)).getProcessInstance().getProcessId());
    assertEquals("Start", ((ProcessNodeTriggeredEvent) processEventList.get(1)).getNodeInstance().getNodeName());
    assertEquals("Start", ((ProcessNodeLeftEvent) processEventList.get(2)).getNodeInstance().getNodeName());
    assertEquals("Print", ((ProcessNodeTriggeredEvent) processEventList.get(3)).getNodeInstance().getNodeName());
    assertEquals("Print", ((ProcessNodeLeftEvent) processEventList.get(4)).getNodeInstance().getNodeName());
    assertEquals("Event", ((ProcessNodeTriggeredEvent) processEventList.get(5)).getNodeInstance().getNodeName());
    assertEquals("Event", ((ProcessNodeTriggeredEvent) processEventList.get(6)).getNodeInstance().getNodeName());
    assertEquals("Print", ((ProcessNodeLeftEvent) processEventList.get(7)).getNodeInstance().getNodeName());
    assertEquals("Print", ((ProcessNodeTriggeredEvent) processEventList.get(8)).getNodeInstance().getNodeName());
    assertEquals("Start", ((ProcessNodeLeftEvent) processEventList.get(9)).getNodeInstance().getNodeName());
    assertEquals("Start", ((ProcessNodeTriggeredEvent) processEventList.get(10)).getNodeInstance().getNodeName());
    assertEquals("org.drools.core.process.event", ((ProcessStartedEvent) processEventList.get(11)).getProcessInstance().getProcessId());
    assertEquals("Event", ((ProcessNodeLeftEvent) processEventList.get(12)).getNodeInstance().getNodeName());
    assertEquals("End", ((ProcessNodeTriggeredEvent) processEventList.get(13)).getNodeInstance().getNodeName());
    assertEquals("End", ((ProcessNodeLeftEvent) processEventList.get(14)).getNodeInstance().getNodeName());
    assertEquals("org.drools.core.process.event", ((ProcessCompletedEvent) processEventList.get(15)).getProcessInstance().getProcessId());
    assertEquals("org.drools.core.process.event", ((ProcessCompletedEvent) processEventList.get(16)).getProcessInstance().getProcessId());
    assertEquals("End", ((ProcessNodeLeftEvent) processEventList.get(17)).getNodeInstance().getNodeName());
    assertEquals("Event", ((ProcessNodeLeftEvent) processEventList.get(19)).getNodeInstance().getNodeName());
    assertEquals("End", ((ProcessNodeTriggeredEvent) processEventList.get(18)).getNodeInstance().getNodeName());
}
Also used : ProcessVariableChangedEvent(org.kie.api.event.process.ProcessVariableChangedEvent) RuleFlowProcess(org.jbpm.ruleflow.core.RuleFlowProcess) DroolsConsequenceAction(org.jbpm.workflow.core.impl.DroolsConsequenceAction) DroolsAction(org.jbpm.workflow.core.DroolsAction) Action(org.jbpm.process.instance.impl.Action) DroolsConsequenceAction(org.jbpm.workflow.core.impl.DroolsConsequenceAction) ActionNode(org.jbpm.workflow.core.node.ActionNode) ArrayList(java.util.ArrayList) ConnectionImpl(org.jbpm.workflow.core.impl.ConnectionImpl) ProcessContext(org.kie.api.runtime.process.ProcessContext) EventNode(org.jbpm.workflow.core.node.EventNode) EventTypeFilter(org.jbpm.process.core.event.EventTypeFilter) KiePackage(org.kie.api.definition.KiePackage) ProcessNodeTriggeredEvent(org.kie.api.event.process.ProcessNodeTriggeredEvent) KieSession(org.kie.api.runtime.KieSession) ProcessNodeLeftEvent(org.kie.api.event.process.ProcessNodeLeftEvent) InternalKnowledgeBase(org.drools.core.impl.InternalKnowledgeBase) DroolsAction(org.jbpm.workflow.core.DroolsAction) StartNode(org.jbpm.workflow.core.node.StartNode) ProcessEvent(org.kie.api.event.process.ProcessEvent) ProcessEventListener(org.kie.api.event.process.ProcessEventListener) ProcessStartedEvent(org.kie.api.event.process.ProcessStartedEvent) EventFilter(org.jbpm.process.core.event.EventFilter) ProcessCompletedEvent(org.kie.api.event.process.ProcessCompletedEvent) EndNode(org.jbpm.workflow.core.node.EndNode) ProcessInstance(org.kie.api.runtime.process.ProcessInstance) KnowledgePackageImpl(org.drools.core.definitions.impl.KnowledgePackageImpl) InternalKnowledgePackage(org.drools.core.definitions.InternalKnowledgePackage) Test(org.junit.Test) AbstractBaseTest(org.jbpm.test.util.AbstractBaseTest)

Example 9 with ProcessNodeTriggeredEvent

use of org.kie.api.event.process.ProcessNodeTriggeredEvent in project jbpm by kiegroup.

the class ProcessEventSupportTest method testProcessEventListenerWithStartEvent.

@Test
public void testProcessEventListenerWithStartEvent() throws Exception {
    InternalKnowledgeBase kbase = KnowledgeBaseFactory.newKnowledgeBase();
    // create a simple package with one process to test the events
    final InternalKnowledgePackage pkg = new KnowledgePackageImpl("org.drools.test");
    RuleFlowProcess process = new RuleFlowProcess();
    process.setId("org.drools.core.process.event");
    process.setName("Event Process");
    StartNode startNode = new StartNode();
    startNode.setName("Start");
    startNode.setId(1);
    EventTrigger trigger = new EventTrigger();
    EventTypeFilter eventFilter = new EventTypeFilter();
    eventFilter.setType("signal");
    trigger.addEventFilter(eventFilter);
    startNode.addTrigger(trigger);
    process.addNode(startNode);
    ActionNode actionNode = new ActionNode();
    actionNode.setName("Print");
    DroolsAction action = new DroolsConsequenceAction("java", null);
    action.setMetaData("Action", new Action() {

        public void execute(ProcessContext context) throws Exception {
            logger.info("Executed action");
        }
    });
    actionNode.setAction(action);
    actionNode.setId(2);
    process.addNode(actionNode);
    new ConnectionImpl(startNode, Node.CONNECTION_DEFAULT_TYPE, actionNode, Node.CONNECTION_DEFAULT_TYPE);
    EndNode endNode = new EndNode();
    endNode.setName("End");
    endNode.setId(3);
    process.addNode(endNode);
    new ConnectionImpl(actionNode, Node.CONNECTION_DEFAULT_TYPE, endNode, Node.CONNECTION_DEFAULT_TYPE);
    pkg.addProcess(process);
    List<KiePackage> pkgs = new ArrayList<KiePackage>();
    pkgs.add(pkg);
    kbase.addPackages(pkgs);
    KieSession session = kbase.newKieSession();
    final List<ProcessEvent> processEventList = new ArrayList<ProcessEvent>();
    final ProcessEventListener processEventListener = new ProcessEventListener() {

        public void afterNodeLeft(ProcessNodeLeftEvent event) {
            processEventList.add(event);
        }

        public void afterNodeTriggered(ProcessNodeTriggeredEvent event) {
            processEventList.add(event);
        }

        public void afterProcessCompleted(ProcessCompletedEvent event) {
            processEventList.add(event);
        }

        public void afterProcessStarted(ProcessStartedEvent event) {
            processEventList.add(event);
        }

        public void beforeNodeLeft(ProcessNodeLeftEvent event) {
            processEventList.add(event);
        }

        public void beforeNodeTriggered(ProcessNodeTriggeredEvent event) {
            processEventList.add(event);
        }

        public void beforeProcessCompleted(ProcessCompletedEvent event) {
            processEventList.add(event);
        }

        public void beforeProcessStarted(ProcessStartedEvent event) {
            processEventList.add(event);
        }

        public void beforeVariableChanged(ProcessVariableChangedEvent event) {
            processEventList.add(event);
        }

        public void afterVariableChanged(ProcessVariableChangedEvent event) {
            processEventList.add(event);
        }
    };
    session.addEventListener(processEventListener);
    // execute the process
    // session.startProcess("org.drools.core.process.event");
    session.signalEvent("signal", null);
    assertEquals(16, processEventList.size());
    assertEquals("org.drools.core.process.event", ((ProcessStartedEvent) processEventList.get(0)).getProcessInstance().getProcessId());
    assertEquals("Start", ((ProcessNodeTriggeredEvent) processEventList.get(1)).getNodeInstance().getNodeName());
    assertEquals("Start", ((ProcessNodeLeftEvent) processEventList.get(2)).getNodeInstance().getNodeName());
    assertEquals("Print", ((ProcessNodeTriggeredEvent) processEventList.get(3)).getNodeInstance().getNodeName());
    assertEquals("Print", ((ProcessNodeLeftEvent) processEventList.get(4)).getNodeInstance().getNodeName());
    assertEquals("End", ((ProcessNodeTriggeredEvent) processEventList.get(5)).getNodeInstance().getNodeName());
    assertEquals("End", ((ProcessNodeLeftEvent) processEventList.get(6)).getNodeInstance().getNodeName());
    assertEquals("org.drools.core.process.event", ((ProcessCompletedEvent) processEventList.get(7)).getProcessInstance().getProcessId());
    assertEquals("org.drools.core.process.event", ((ProcessCompletedEvent) processEventList.get(8)).getProcessInstance().getProcessId());
    assertEquals("End", ((ProcessNodeLeftEvent) processEventList.get(9)).getNodeInstance().getNodeName());
    assertEquals("End", ((ProcessNodeTriggeredEvent) processEventList.get(10)).getNodeInstance().getNodeName());
    assertEquals("Print", ((ProcessNodeLeftEvent) processEventList.get(11)).getNodeInstance().getNodeName());
    assertEquals("Print", ((ProcessNodeTriggeredEvent) processEventList.get(12)).getNodeInstance().getNodeName());
    assertEquals("Start", ((ProcessNodeLeftEvent) processEventList.get(13)).getNodeInstance().getNodeName());
    assertEquals("Start", ((ProcessNodeTriggeredEvent) processEventList.get(14)).getNodeInstance().getNodeName());
    assertEquals("org.drools.core.process.event", ((ProcessStartedEvent) processEventList.get(15)).getProcessInstance().getProcessId());
}
Also used : ProcessVariableChangedEvent(org.kie.api.event.process.ProcessVariableChangedEvent) RuleFlowProcess(org.jbpm.ruleflow.core.RuleFlowProcess) DroolsConsequenceAction(org.jbpm.workflow.core.impl.DroolsConsequenceAction) DroolsAction(org.jbpm.workflow.core.DroolsAction) Action(org.jbpm.process.instance.impl.Action) DroolsConsequenceAction(org.jbpm.workflow.core.impl.DroolsConsequenceAction) ActionNode(org.jbpm.workflow.core.node.ActionNode) ArrayList(java.util.ArrayList) ConnectionImpl(org.jbpm.workflow.core.impl.ConnectionImpl) ProcessContext(org.kie.api.runtime.process.ProcessContext) EventTypeFilter(org.jbpm.process.core.event.EventTypeFilter) KiePackage(org.kie.api.definition.KiePackage) ProcessNodeTriggeredEvent(org.kie.api.event.process.ProcessNodeTriggeredEvent) KieSession(org.kie.api.runtime.KieSession) ProcessNodeLeftEvent(org.kie.api.event.process.ProcessNodeLeftEvent) InternalKnowledgeBase(org.drools.core.impl.InternalKnowledgeBase) EventTrigger(org.jbpm.workflow.core.node.EventTrigger) DroolsAction(org.jbpm.workflow.core.DroolsAction) StartNode(org.jbpm.workflow.core.node.StartNode) ProcessEvent(org.kie.api.event.process.ProcessEvent) ProcessEventListener(org.kie.api.event.process.ProcessEventListener) ProcessStartedEvent(org.kie.api.event.process.ProcessStartedEvent) ProcessCompletedEvent(org.kie.api.event.process.ProcessCompletedEvent) EndNode(org.jbpm.workflow.core.node.EndNode) KnowledgePackageImpl(org.drools.core.definitions.impl.KnowledgePackageImpl) InternalKnowledgePackage(org.drools.core.definitions.InternalKnowledgePackage) Test(org.junit.Test) AbstractBaseTest(org.jbpm.test.util.AbstractBaseTest)

Example 10 with ProcessNodeTriggeredEvent

use of org.kie.api.event.process.ProcessNodeTriggeredEvent in project jbpm by kiegroup.

the class GlobalTimerServiceBaseTest method testTimerFailureAndRetrigger.

@Test(timeout = 20000)
public void testTimerFailureAndRetrigger() throws Exception {
    NodeLeftCountDownProcessEventListener countDownListener = new NodeLeftCountDownProcessEventListener("Timer_1m", 3);
    final List<Long> timerExporations = new ArrayList<Long>();
    ProcessEventListener listener = new DefaultProcessEventListener() {

        @Override
        public void afterNodeTriggered(ProcessNodeTriggeredEvent event) {
            if (event.getNodeInstance().getNodeName().equals("Timer_1m")) {
                timerExporations.add(event.getNodeInstance().getId());
            }
        }
    };
    environment = RuntimeEnvironmentBuilder.Factory.get().newDefaultBuilder().entityManagerFactory(emf).addAsset(ResourceFactory.newClassPathResource("org/jbpm/test/functional/timer/helloretrigger.bpmn2"), ResourceType.BPMN2).schedulerService(globalScheduler).registerableItemsFactory(new TestRegisterableItemsFactory(listener, countDownListener)).get();
    manager = getManager(environment, false);
    RuntimeEngine runtime = manager.getRuntimeEngine(ProcessInstanceIdContext.get());
    KieSession ksession = runtime.getKieSession();
    Map<String, Object> params = new HashMap<>();
    ProcessInstance pi = ksession.startProcess("rescheduletimer.helloretrigger", params);
    assertEquals("Process instance should be active", ProcessInstance.STATE_ACTIVE, pi.getState());
    manager.disposeRuntimeEngine(runtime);
    final long processInstanceId = pi.getId();
    // let the timer (every 2 sec) fire three times as third will fail on gateway
    countDownListener.waitTillCompleted(8000);
    assertEquals("There should be only 3 nodes as there third is failing", 3, timerExporations.size());
    runtime = manager.getRuntimeEngine(ProcessInstanceIdContext.get(processInstanceId));
    ksession = runtime.getKieSession();
    ksession.execute(new ExecutableCommand<Void>() {

        @Override
        public Void execute(Context context) {
            KieSession ksession = ((RegistryContext) context).lookup(KieSession.class);
            ProcessInstance pi = (ProcessInstance) ksession.getProcessInstance(processInstanceId);
            ((WorkflowProcessInstance) pi).setVariable("fixed", true);
            return null;
        }
    });
    manager.disposeRuntimeEngine(runtime);
    countDownListener.reset(1);
    countDownListener.waitTillCompleted(5000);
    assertEquals("There should be 3 expirations as the failing one should finally proceed", 3, timerExporations.size());
    try {
        runtime = manager.getRuntimeEngine(ProcessInstanceIdContext.get(processInstanceId));
        ksession = runtime.getKieSession();
        pi = ksession.getProcessInstance(processInstanceId);
        assertNull(pi);
    } catch (SessionNotFoundException e) {
    // expected for PerProcessInstanceManagers since process instance is completed
    }
    ((AbstractRuntimeManager) manager).close(true);
}
Also used : InitialContext(javax.naming.InitialContext) RegistryContext(org.drools.core.command.impl.RegistryContext) Context(org.kie.api.runtime.Context) ProcessInstanceIdContext(org.kie.internal.runtime.manager.context.ProcessInstanceIdContext) RuntimeEngine(org.kie.api.runtime.manager.RuntimeEngine) HashMap(java.util.HashMap) NodeLeftCountDownProcessEventListener(org.jbpm.test.listener.NodeLeftCountDownProcessEventListener) ProcessEventListener(org.kie.api.event.process.ProcessEventListener) DefaultProcessEventListener(org.kie.api.event.process.DefaultProcessEventListener) AbstractRuntimeManager(org.jbpm.runtime.manager.impl.AbstractRuntimeManager) ArrayList(java.util.ArrayList) NodeLeftCountDownProcessEventListener(org.jbpm.test.listener.NodeLeftCountDownProcessEventListener) DefaultProcessEventListener(org.kie.api.event.process.DefaultProcessEventListener) ProcessNodeTriggeredEvent(org.kie.api.event.process.ProcessNodeTriggeredEvent) KieSession(org.kie.api.runtime.KieSession) WorkflowProcessInstance(org.jbpm.workflow.instance.WorkflowProcessInstance) ProcessInstance(org.kie.api.runtime.process.ProcessInstance) SessionNotFoundException(org.kie.internal.runtime.manager.SessionNotFoundException) Test(org.junit.Test)

Aggregations

ProcessNodeTriggeredEvent (org.kie.api.event.process.ProcessNodeTriggeredEvent)24 Test (org.junit.Test)22 ProcessInstance (org.kie.api.runtime.process.ProcessInstance)19 DefaultProcessEventListener (org.kie.api.event.process.DefaultProcessEventListener)18 KieBase (org.kie.api.KieBase)14 ArrayList (java.util.ArrayList)13 HashMap (java.util.HashMap)13 WorkflowProcessInstance (org.kie.api.runtime.process.WorkflowProcessInstance)13 ProcessEventListener (org.kie.api.event.process.ProcessEventListener)9 ProcessStartedEvent (org.kie.api.event.process.ProcessStartedEvent)8 KieSession (org.kie.api.runtime.KieSession)8 WorkItem (org.kie.api.runtime.process.WorkItem)8 ProcessVariableChangedEvent (org.kie.api.event.process.ProcessVariableChangedEvent)7 TestWorkItemHandler (org.jbpm.bpmn2.objects.TestWorkItemHandler)6 ProcessCompletedEvent (org.kie.api.event.process.ProcessCompletedEvent)6 ProcessNodeLeftEvent (org.kie.api.event.process.ProcessNodeLeftEvent)6 Map (java.util.Map)5 InternalKnowledgeBase (org.drools.core.impl.InternalKnowledgeBase)5 RuleFlowProcess (org.jbpm.ruleflow.core.RuleFlowProcess)5 AbstractBaseTest (org.jbpm.test.util.AbstractBaseTest)5