How can I get the past transitions?


#1

Hei guys, how can I get all the transitions before the current step?


#2

Check the History
Accessible via REST
Has previous steps


#3

Yeah, I forgot sorry, i need to do it through Java Api. Is there any way?


#4

As long as you have access to the process engine you can query

execution.getProcessEngineServices().getHistoryService()
    .createHistoricActivityInstanceQuery()
    .processInstanceId("someProcess")
    .list();

#5

Thank you so much kind sir.


#6

Sorry for double posting, your solution works fine, but it doesn’t include the sequence flows, is there any way i can retrieve those too?


#7

Sequence flows are not stored in history - is there a specific reason why you need the sequence flows?


#8

Details, we have a table with all the processes ongoing and when you click on one of them you get all the info about it.