[ https://issues.apache.org/jira/browse/SLING-1566?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Carsten Ziegeler closed SLING-1566. ----------------------------------- > Add ResourceResolver.isLive() method > ------------------------------------ > > Key: SLING-1566 > URL: https://issues.apache.org/jira/browse/SLING-1566 > Project: Sling > Issue Type: Improvement > Components: API, JCR > Affects Versions: JCR Prefs 1.0.0 > Reporter: Felix Meschberger > Assignee: Felix Meschberger > Fix For: JCR Resource 2.0.8, API 2.1.0 > > > SLING-1262 added a close() method to the ResourceResolver declaring that an > exception will be thrown if the ResourceResolver is used after it has been > closed. > To be able to check a ResourceResolver in application code, an isLive method > should be added. > In addition, the actual exception -- IllegalStateException -- being thrown if > the ResourceResolver has been closed should also be documented. > Finally, in the JcrResourceReslver, the live-check is mainly implemented in > the checkClosed() method. Probably this method should not only check the > close state of itself but also, whether the underlying primary session is > still alive. If the ResourceResolver has not been closed yet, but the session > has already been logged out, the JcrResourceResolver may choose to close > itself too (as a side effect). This is to be discussed. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.