[hibernate-dev] Changes around transaction -> changed exception behavior

Steve Ebersole steve at hibernate.org
Tue Apr 28 17:26:31 EDT 2015


Where does that wrapping happen?

On Tue, Apr 28, 2015 at 3:53 PM, Gunnar Morling <gunnar at hibernate.org>
wrote:

>  Hi,
>
> while working on making OGM work with ORM 5, I noticed a slightly different
> behaviour wrt. to exceptions occurring during flushes.
>
> Previously, such exceptions would bubble up as is, whereas now the
> beforeTransactionCompletion() logic is called in a try/catch block,
> wrapping any exceptions in a TransactionException. It's no big deal for me
> (I just need to adapt some tests in our suite which expect specific
> exception types), but then I was wondering whether that change poses a
> migration issue for existing client code, e.g.
> expecting/handling StaleObjectStateException which would need to be adapted
> accordingly?
>
> Anyone thinking it's a problem?
>
> Thanks,
>
> --Gunnar
> _______________________________________________
> hibernate-dev mailing list
> hibernate-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/hibernate-dev
>


More information about the hibernate-dev mailing list