Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-19500

Hibernate store should use Session#get and not Session#load to load documents

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Minor
    • 14.2-rc-1, 13.10.4
    • 13.10.3
    • Old Core
    • None
    • Unknown
    • N/A
    • N/A

    Description

      Session#load is designed specifically to load entities that you are supposed to know are there, but we actually have no idea if it's the case or not. According to the javadoc the exception we are relying on to know if a document exist or not might not always be thrown (even if we did not actually see that happen).

      For that, what we are supposed to use is Session#get.

      Attachments

        Activity

          People

            tmortagne Thomas Mortagne
            tmortagne Thomas Mortagne
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: