Thanks Vasile,
i need to have a optimal spend time for each task so the supervisor can compare the real spend time with the optimal time. Finally I have created a auxiliary database table who relate optimal time with bpmn task id.
i.e:
sid-46D69340-5E24-4956-9DE0-34C2BAEDE677 200000 ms
…..
When the task ends I can compare Optimal Time vs Duration (column duration_ in act_hi_taskinst).
Maybe Hooking is better approach, I will study it.