Problem to create Java Delegate

Hi,

I’m trying to create test Java Delegate [https://app.camunda.com/nexus/content/repositories/camunda-bpm/, camunda-archetype-servlet-war]. I follow this tutorial:
Tutorial: Camunda Enterprise Edition for Java Developers (Video 2) - YouTube

Problem no 1:
When I run Run us => Maven install I get error:

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12.4:test (default-test) on project SimpleDemo: There are test failures.

So I add true to pom (can be any version?):

<plugin> 
	<groupId>org.apache.maven.plugins</groupId> 
	<artifactId>maven-surefire-plugin</artifactId> 
	<version>2.6</version>	
	<configuration>	
	<skipTests>true</skipTests>	
	</configuration> 
</plugin>

And it compiles with success.

Problem no 2
When I try to start process, I get error:

{

    "type": "RestException",

    "message": "Cannot instantiate process definition SimpleDemo:1:9922cc3e-b652-11eb-8751-049226bdb658: Unknown property used in expression: #{weatherOK}. Cause: Cannot resolve identifier 'weatherOK'"

}

Diagram is OK (I attach).process.bpmn (5.1 KB)

Problem no 3
I try to undeploy this package/application using Manager. Tomcat shows contex

errors, application was removed but… it still exists in Camunda(!?). Restart does not help.

Any suggestions?
Regards

Can you show the code you’re running in the CheckWeatherDelegate class?

Cause: Cannot resolve identifier ‘weatherOK’"

The above indicates that the variable that you’re checking for at the gateway doesn’t exist so there might be something wrong with how it’s being set.

@mkelton your process is being executed in synchronous passion. So, the weatherOk field was computed but it was not persisted when it reached the gateway. The variable is in-memory and it will be persisted once wait state is reached, so that variable will be accessible.

So if you mark asyncBefore:true (save point) at the exclusive gateway it will persist the variable and available for the gateway expression evaluation.

Thanks for help guys!

Looks like I made stupid mistake; I did open class file in Eclipse and it had… no code. I did not know that it requires ‘save’ before compilation - I was expecting ‘runs us’ does it.

But I still do not know how to undeploy application.
If I use Tomcat Manager or simply delete war file - Tomcat removes this application. But ‘SimpleDemo’ remains in Camunda cockpit.
So I remove it using REST with engine-rest/process-definition/SimpleDemo:1:55a8cdb1-b743-11eb-962d-049226bdb658?cascade=true
Yet when I want to deploy it again (using Mangager or copy file into webapps folder) Tomcat says deployed successfully but Camunda cockpit has no application.
I played with restart - no help.

Regards