Details

    • Type: Enhancement
    • Status: Resolved (View Workflow)
    • Priority: Blocker
    • Resolution: Done
    • Affects Version/s: 4.0.0.Alpha1
    • Fix Version/s: 4.0.0.Alpha1
    • Component/s: API, Query
    • Labels:
      None

      Description

      Query results may be buffered in temporary storage, and this temporary storage is closed and garbage collected only when the session is closed. After all, none of the JCR query-related objects has any notion of a close method.

      While this works, it may cause problems in sessions that use lots of queries or a few queries with lots of results. A better way to would be to add a public "close()" method to the QueryResults, and in fact making QueryResults extend AutoCloseable to enable it to be used within a try-with-resources block. This would give clients more control over when resources are cleaned up, although it would be optional and fall back to having the session's close() method clean up all resources.

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  rhauch Randall Hauch
                  Reporter:
                  rhauch Randall Hauch
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  1 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved: