Column "duration_" in "act_hi_actinst"

we are looking for column which describes execution time of element (scriptTask, sequenceFlow with condition). We have seen that in table act_hi_actinst there is column “duration_” but number of millis are calculated like startTime-endTime which is not right for us because element could be created at 11am and processed in 1 second at 11.30am(due to executor busy) so duration will be 30minutes and 1 second insted of 1 second…

So how can I find this kind of information and what is th purpose of column “duration_” calculated like this?

Why execution of sequence flow is calculated like this

    public void recordSequenceFlowTaken(ExecutionEntity executionEntity) {
        ActivityInstanceEntity activityInstance = createActivityInstanceEntity(executionEntity);