Skip to main content
This tutorial demonstrates how to make a process more flexible using BPMN 2.0 exclusive gateways, routing execution based on dynamic conditions.

Add two gateways

Open your process in the Camunda Modeler. Insert a gateway (diamond shape) between the start event and the service task. Position a second gateway after the user task. Adjust the sequence flows to connect these elements appropriately. Add gateways to the process Name the new elements clearly: Name the gateways and flows

Configure the gateways

Select each outgoing sequence flow and configure its condition in the properties panel: <1000 € flow — set Condition Type to Expression and enter ${amount<1000}: Condition for the under-1000 flow >=1000 € flow${amount>=1000}: Condition for the >=1000 flow Yes flow${approved}: Condition for the Yes flow No flow${!approved}: Condition for the No flow These conditions use the Unified Expression Language to evaluate the gateway.

Deploy the process

Use the deploy button in the Camunda Modeler to publish your updated process.

Work on the task

Navigate to Tasklist at http://localhost:8080/camunda/app/tasklist/ and authenticate with the demo credentials. Start a new instance and set variables via the generic form, using an amount ≥ 1000 to trigger the approval task. Start an instance with the generic form Complete the task by checking the approved checkbox. Test various scenarios, including rejecting payments and creating instances with amounts under 1000.

Next step

Continue to decision automation to learn about adding business rules.