In jbpm3.X ,we could define private variable and general variable ,but in jbpm4.x, i coudn't find this function.
i found there are two methods to create variable in jbpm4.x
one method:
executionService.setVariable(executionId, name, value)
two method:
taskService.setVariables(taskId, variables)
so i made a experiment,i define a workflow with two task nodes ,in task1 node, i create one variables like that:
taskService.setVariables(task1.getId(), "var1");
in task2 node,i think i shouldn't get the var1 which created in task1
but i was suprised when i user this code
taskService.getVariable(task2.getId(), "var1")
the result is i could get variable var1 in task2
so ,how could i create a variable only exist in one task ?
my spoken english is little poor,thansk all..