Uploaded image for project: 'Sling'
  1. Sling
  2. SLING-6786

JCR Installer Provider doesn't rescan if exception happens during scan.

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: JCR Installer 3.1.24
    • Fix Version/s: JCR Installer 3.1.26
    • Component/s: Installer
    • Labels:
      None

      Description

      Currently, the JCR Installer Provider maintains a boolean flag needsScan which is set to true on start and when an event occurs in the JCR for a given watched folder.

      Subsequently, when a scan is requested because of that flag being true, it will set the flag to false at the beginning of the scan. In other words, the folder will not be rescanned until either the provider is restarted or something changes in the repository (indicated by an event), respectively.

      This is fine, however, it ignores the fact that an exception can occur during the scan (e.g., connection is gone, etc.). If that happens, it will not finish the scan but the needsScan will already be false - hence, until something changes, the folder will not be rescanned.

      The fix seems simple. The needsScan=false should be moved form the start of the scan method to the end of it.

        Attachments

        1. SLING-6786.patch
          0.8 kB
          Karl Pauls

          Activity

            People

            • Assignee:
              karlpauls Karl Pauls
              Reporter:
              karlpauls Karl Pauls
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: