I think withTx is a bit broken. I tried to use it initially but I dropped the idea because it was somehow obscuring the problem from ISPN-2173. it currently does not work well if for some reason the tx is heuristically rolled back. It will try to setRollbackOnly which just results in another exception which hides the initial one. I guess I'll fix it and use it now.