I’m new to Camunda and BPM in general. I want to place logs in various places in my BPMN so I can learn both the flow and see what data it has. I’m starting my process by sending a /message via REST which seems to work well. I will be sending various processVariables there.
How can I log variables using grovvy? Here is what I have but it causes an error.
println ${execution.getVariable('messageType')}
causes this error:
{
“type”: “ScriptEvaluationException”,
“message”: “Unable to evaluate script while executing activity ‘ScriptTask_00pwmsi’ in the process definition with id ‘Process_0kjz656:8:2707ef49-55be-11ea-b725-9a2cbcbeb0b3’: groovy.lang.MissingMethodException: No signature of method: org.codehaus.groovy.jsr223.GroovyScriptEngineImpl.$() is applicable for argument types: (Script9$_run_closure1) values: [Script9$_run_closure1@6d37d63c]\nPossible solutions: is(java.lang.Object), any(), get(java.lang.String), use([Ljava.lang.Object;), any(groovy.lang.Closure), wait()”
}
What am I doing wrong?
-Dave