Cockpit doesn't show current step

Hello there! I have the simple bpmn like this:

image

My problem is Cockpit doesn’t show current step. For example, I tried the delegates code:

@Component("TestCamundaApiDelegate")
public class TestCamundaApiDelegate implements JavaDelegate {

    @Override
    public void execute(DelegateExecution delegateExecution) throws Exception {
        log.info("TestCamundaApiDelegate has started!");
        Thread.sleep(30000L);
    }
}

@Component("TestCamundaApiDelegate2")
public class TestCamundaApiDelegate2 implements JavaDelegate {

    @Override
    public void execute(DelegateExecution delegateExecution) throws Exception {
        log.info("TestCamundaApiDelegate2 has started!");
        Thread.sleep(30000L);
    }
}

And in the console I can see sequential delegates call after 30s delay, but I can’t see this in Camunda Cockpit. Why?

Cockpit runtime state will only show state that has been committed to the database, as you have it the entire process runs start to finish in memory. So there’s nothing for the engine to display.

To understand this better take a look at the documentation on transactions.

If you would like to see something incockpit, you could use the asynchronous before tick box to commit the state to the database before it runs the code, in that case you’ll be able to see the token.