Uploaded image for project: 'Jackrabbit Content Repository'
  1. Jackrabbit Content Repository
  2. JCR-3652

Bundle serialization broken

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 2.4.5, 2.6.4, 2.7.1
    • jackrabbit-core
    • None

    Description

      I have got a strange case where some node bundle is broken, seemingly because a byte is missing. I can't explain the missing byte, but it is reproducible, meaning that writing the bundles again will break them again. There are 11 broken bundles, 10 of them have the size 480 bytes and one is slightly larger. It is always a boolean property value that is missing, always the value for the property jcr:isCheckedOut.

      As a (temporary) solution, and to help analyze what the problem might be, I will create a patch that does the following:

      • When serializing a bundle, check if the byte array can be de-serialized. If not, then try again. Starting with the 3th try, use a slower variant where before and after writing the boolean value the buffer is flushed. I'm aware that ByteArrayOutputStream.flush doesn't do much, but maybe it solves the problem (let's see) if the problem is related to a JVM issue.
      • If de-serializing a bundle fails, check if it's because of a missing boolean property value. If yes, insert the missing byte.

      I have also added some log messages (warning / error) to help analyze the problem.

      Attachments

        1. JCR-3652-test-case.patch
          4 kB
          Thomas Mueller
        2. JCR-3652-b.patch
          20 kB
          Thomas Mueller
        3. JCR-3652.patch
          47 kB
          Thomas Mueller

        Activity

          People

            thomasm Thomas Mueller
            thomasm Thomas Mueller
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: