You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jdo-dev@db.apache.org by "Michael Bouschen (JIRA)" <ji...@apache.org> on 2017/03/12 18:18:04 UTC

[jira] [Updated] (JDO-735) Make PersistenceManager and Query support AutoCloseable (JDK1.7+)

     [ https://issues.apache.org/jira/browse/JDO-735?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Michael Bouschen updated JDO-735:
---------------------------------
    Attachment: JDO-735-patch4.txt

Attached you find a new patch for review: JDO-735-patch4.txt. 
It checks for JDOUserExceptions thrown by the JDO implementation to indicate a closed resouce is used and it checks isEmpty on a closed query result.

> Make PersistenceManager and Query support AutoCloseable (JDK1.7+)
> -----------------------------------------------------------------
>
>                 Key: JDO-735
>                 URL: https://issues.apache.org/jira/browse/JDO-735
>             Project: JDO
>          Issue Type: New Feature
>          Components: api, specification, tck
>            Reporter: Andy Jefferson
>            Assignee: Michael Bouschen
>             Fix For: JDO 3.2
>
>         Attachments: CloseWithActiveTxRollsBack.java, JDO-735-patch4.txt
>
>
> So then it can be used with JDK1.7+ try-with-resources, as per http://docs.oracle.com/javase/tutorial/essential/exceptions/tryResourceClose.html



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)