0 Replies Latest reply on Aug 11, 2009 1:21 PM by Cassio Landim

    Remove variable not removing

    Cassio Landim Newbie

      I have this code:

      Map<String,Object> variables = new HashMap<String,Object>();
      variables.put("busLine", busLine);
      executionService.startProcessInstanceByKey("helloWorld", variables);

      and I have an org.jbpm.api.listener.EventListener with this code:
      public void notify(EventListenerExecution execution) {
       boolean removed = execution.removeVariable("busLine");

      with this process definition:
      <process name="helloWorld" xmlns="http://jbpm.org/4.0/jpdl">
       <start g="16,22,80,40">
       <transition to="printHelloWorld" />
       <java expr="#{busLineService}" g="166,24,138,40" method="save2"
       <object expr="#{busLine}" />
       <on event="end">
       <event-listener class="br.com.acttive.wicketjbpm.workflow.WorkflowListener">
       <transition name="to state1" to="state1" g="-49,-18" />
       <state name="state1" g="287,158,92,52">
       <transition name="to end1" to="end1" g="-42,-18" />
       <end g="422,18,48,48" name="end1" />

      where busLine is an entity synchronized with hibernate and I'm not beeing able to remove this variable from the jbpm4_variable table.

      Anyone knows why this happens?