Currently if a batch is defined for the deletion of processes with sub processes he will delete the processes and on the sub processes a NullPointerException is thrown, since the instance is deleted during the deletion of the main process.
We should make the exception more clear so the user can recognize the problem.