Is it valid to write #{true}
for camunda engine 7 or what is the correct syntax for true
, I get the parameter then using org.camunda.bpm.engine.delegate.VariableScope#getVariable
?
Hey @banan314!
Welcome to the Camunda Community
What do you want to do with this syntax? If you are using it for evaluating conditions in Camunda Platform 7 you should take a look here:
I’m not evaluating any condition. I want to set a variable or parameter so that I’m able to view its value in my application.
What is the difference between local and global variables, as in org.camunda.bpm.engine.TaskService#setVariable
and org.camunda.bpm.engine.TaskService#setVariableLocal
?
From the docs of the global one:
If the variable is not already existing, it will be created in the most outer scope. This means the process instance in case this task is related to an execution.
From the docs ot the local one:
If the variable is not already existing, it will be created in the task.
So I guess the task scope is narrower than the execution scope?
I have just created an example using a take listener on a sequence flow element to create a variable.
This will create a global variable which will be alive in the context of the process instance.
If you go with a local variable, this will only be available in a more limited scope.
As far as I remember this get’s especially important if you are working with multiple subprocesses.
Best,
Thomas
Multiple subprocesses in camunda?
I see, thank you
Here’s some documentation on variable scopes and global vs local: Process Variables | docs.camunda.org