Andrus Adamchik closed CAY-1043.
--------------------------------
Resolution: Fixed
> NPE in ConnectionWrapper on rollback
> ------------------------------------
>
> Key: CAY-1043
> URL: https://issues.apache.org/cayenne/browse/CAY-1043
> Project: Cayenne
> Issue Type: Bug
> Components: Cayenne Core Library
> Affects Versions: 3.0
> Reporter: Andrus Adamchik
> Assignee: Andrus Adamchik
> Priority: Minor
> Fix For: 3.0
>
> Attachments: CAY-1043.patch.txt
>
>
> Just noticed an NPE in Cayenne connection pool, ConnectionWrapper.rollback(), line 301. It is a result of a failed transaction that blew up inside "commit" method (most blow up on actual operation, so we rarely if ever see this condition). "commit" calls "close()" in a finally block, which results in ConnectionWrapper resetting the internal connection to NULL, causing NPE in a rollback call downstream... The real problem here of course is that calling "close" before "rollback" prevents correct state rollback and may result in unpredictable behavior in those rare situations.
-- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
This archive was generated by hypermail 2.0.0 : Tue Apr 29 2008 - 17:37:37 EDT