Camunda workflow error


I have a camunda WF , and it has been deployed to different environments and although it is working in others, but in one environment it is giving error, in the WF i have yes and no conditions, and for yes condition the expression I have used is ${data.equals(“true”)} and for no condition the expression is ${data.equals(“false”)}, but when the camunda start url for this process is triggered in the said environment, I get an error saying- Unknown property used in expression ${data.equals(“true”)}. Cause: Target unreachable, base expression ‘data’ resolved to null.

Any help in this regard would be highly appreciated, looking for a quick response.


Hey @ThomasShelby!
To me this indicated that the “data” object you want to access is not existent in the current scope of the process. Do you have a process diagram you could share so we are able to take a look on where this object comes from.

I am imagening that you are having the exact same BPMN deployed to multiple environments. (and it works fine most of the time) Hence I guess there is something wrong with data coming from one of the integrations you might have.


Hi , Thanks for your response, sure I am attaching the bpm file, this expression is available there, and this is the code snippet that I am using in the java class:

else if(execution.getCurrentActivityId().equals(“P”)){“Inside P '” + key +"’");
Camunda service=new Camunda();
String result=service.p(key, (String) version);;
execution.setVariable(“data”, result);

One additional info I just found out is that we have different wildfly versions in diff environments, could that be causing this error?

Do let me know what you think after checking these details.

WorkFlow.bpmn (7.8 KB)

Hi @ThomasShelby

It would look as if the result from the call the Camunda.p call is null in the environment where it fails.
What is the output from the

Maybe something else is happening to the “data” attribute inside the camunda.bpm.WF class?
It’s hard to tell from the snippet above…


Hi @mimaom , actually the WF is not even reaching this code , rather it is giving error as soon as it is triggered through the /start URL.

Hi @ThomasShelby

Are you sure it’s not reaching the code? The expression should first be evaluated when the gateway activity is reached.

One more thing - the default transaction behaviour of Camunda will execute the process until it reaches a wait state (and commits the state to DB). In case of the attached WorkFlow, it will run from start to end in the same transaction - BUT if the “data” process variable is not set, it will roll back the entire process because of the expression error - so it could look as if the process did not run. Off couse the log statements will still be visible :slight_smile:


Hi @mimaom

Yes I am quite sure that the BPMN WF is not reaching the code , because this data variable is set to result , and since the WF is not able to reach the code it is not understanding what this variable is, furthermore, I have put loggers in the code before initializing this variable so if it was reaching the code, at least the loggers would be printed which is not the case here, this of course is my understanding , pls feel free to correct me.


Hi @ThomasShelby

Thar really sounds strange. Expressions are first evaluated at runtime when reached, so in your case, the process engine will first complain when the expression is used (at the first gateway). Any activities up until that will be executed. Are you sure that “data” is not being used somewhere else in the process and that might be causing the problem?


Hi @mimaom

Yes , this data variable is only being used in the exclusive gateways in my process, and its value is initialized in the Java class, to which part i think the process is not able to reach.



Can anyone help in this regard?


@StephanHaarmann , would you be able to help in this regard?


I don’t see any cause for this error. I would do the following:
add an async before and an async after the start event and each service task.
This will help us to narrow done the root cause of the error, i.e., is the service task P executed? Then we have to look in depth at your code. If not, we have to revisit your model.

Oh ok, sure , let me try out these changes and redeploy and test. Will update once I have done this.

Thanks a lot for the quick reply.

Hi @StephanHaarmann , after your suggestion, I have deployed the WF, now the error logs are as follows:

ENGINE-14006 Exception while executing job d1b2d008-a6ed-11ed-9036-eeed98c9489c: : org.camunda.bpm.engine.ProcessEngineException: Unknown property used in expression: ${data.equals(“true”)}. Cause: Target unreachable, base expression ‘data’ resolved to null

The issue is same but the Exception while executing job is new, previously it was Exception while closing command context. Does that tell us something?

And an additional info is that the error is only there on GKE container and not on other environments we are using.

Thanks !

Hi @ThomasShelby,

Thanks for checking. This should now raise an incident in the Cockpit. Can you tell me where (which activity) has the incident? Also in the cockpit, you should be able to inspect the variables (or via the API). Is there a variable data?

Hi @StephanHaarmann ,

Yes it raised an incident in the cockpit for the request. I am sharing the related screenshots. Let me know what you think and how I can proceed.


Thanks! This confirms your assumption: Service task ‘P’ does not work as expected, consequently the variable is not set once ‘P’ completes and the conditions on the sequence flow cannot be evaluated.

‘P’ is implemented via a JavaDelegate, correct? We need to check, whether the correct delegate is invoked and whether the correct branch of your if statement is reached. In this regard, it would be helpful to log currentActivityId at the beginning of the JavaDelegate.
You said that you’re using GKE. Do you use Camunda as an embedded engine inside a SpringBoot application?

@StephanHaarmann , in the workflow I am implementing it as a Java Class and providing the fully qualified class name , coming to the currentActivityId, before I am using this, I am using a log, but in the logs it is not printing, suggesting that the class is not being invoked, and for the GKE , yes we use Camunda as an embedded engine inside the SpringBoot Application.

Camunda throws an error if the implementation of a service task is not found. The error would look like this:

cannot instantiate process definition WF:1:b1a4ea65-a848-11ed-84d2-84a9385a77fb: ENGINE-09008 Exception while instantiating class 'camunda.bpm.WF': ENGINE-09017 Cannot load class 'camunda.bpm.WF': camunda.bpm.WF [ start-instance-error ]

Obviously, this is not the error that you receive. This means a delegate is found and called. If no logging takes place, I assume that it is the wrong one. I don’t know what causes this.

  • There might be additional resources on the class path leading to alternative implementations and the wrong one is called
  • The pod my use an outdated version of the process application.

Oh ok, let me check both these points, thanks for the quick reply @StephanHaarmann .