Doc 2.3.7 missing explanation about processInstance

In the 2.3.7 section of the doc, there is the following code which contains “processInstance”, but we don’t know where it comes from :

HistoryService historyService = processEngine.getHistoryService();
List activities =
historyService.createHistoricActivityInstanceQuery()
.processInstanceId(processInstance.getId())
.finished()
.orderByHistoricActivityInstanceEndTime().asc()
.list();

Do you know how to get processInstance ?

My bad : the answer is in section 2.3.3 :
ProcessInstance processInstance =
runtimeService.startProcessInstanceByKey(“holidayRequest”, variables);

I would like to delete this post, is it possible ?

No need to delete it, someone might find it useful in the future.

Best regards,

Tijs