unification of persistence and transaction handling for jbpm and human task

some fixes for persistence and tx sync

(cherry picked from commit 6189bdfaed78d540b464b83bcf6de5b34ee6888b)