Community

History Transitions

created by Sebastian Herbst in jBPM - View the full discussion

Hello,

is it possible to get the the history including the taken Transitions of a ProcessInstance ?

 

So far i've just managed to geht the names of the states called during the process. But how do i get the transitions ?

 

historyService = processEngine.getHistoryService();
 
...
 
private List<HistoryActivityInstance> getHistory(ProcessInstance processInstance)
    {
        String executionId = executionService.findProcessInstanceById(processInstance.getId()).getId();
        List<HistoryActivityInstance> historyActivityInstance = historyService
        .createHistoryActivityInstanceQuery().executionId(executionId) 
        .orderAsc(HistoryProcessInstanceQuery.PROPERTY_STARTTIME).list();
        
        return historyActivityInstance;
    }

 

The goal is to gett some String like state1 -- toState2 --> state2 -- toState3 --> state3

I know it's all stored in the db jbpm_hist_actinst, but i would prefer geting the information direktly by jbpm methodes.

 

Greetings and thanks

Sebastian Herbst

Reply to this message by going to Community

Start a new discussion in jBPM at Community