Uploaded image for project: 'Apache NiFi'
  1. Apache NiFi
  2. NIFI-6416

WriteAheadFlowFileRepository.swapFlowFilesIn() not removing swapLocationSuffixes

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 1.9.2
    • 1.10.0
    • Core Framework
    • None

    Description

      WriteAheadFlowFileRepository maintains a list of swapLocationSuffixes.  This is added to when records are swapped out, and removed from when records are swapped in when the repo is updated[1].  However, the swapFlowFilesIn method[2] appears to be adding instead of removing the specified swap location. 

      Specifically:

      synchronized (this.swapLocationSuffixes) {
          this.swapLocationSuffixes.add(normalizeSwapLocation(swapLocation));
      }

      Should be:

      synchronized (this.swapLocationSuffixes) {
          this.swapLocationSuffixes.remove(normalizeSwapLocation(swapLocation));
      }

       

       

      [1] https://github.com/apache/nifi/blob/f08c2ee43f39584b7d4e76d61d7d4aaa889068fd/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/repository/WriteAheadFlowFileRepository.java#L372-L377

      [2]  https://github.com/apache/nifi/blob/f08c2ee43f39584b7d4e76d61d7d4aaa889068fd/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/repository/WriteAheadFlowFileRepository.java#L518

      Attachments

        Issue Links

          Activity

            People

              devriesb Brandon Rhys DeVries
              devriesb Brandon Rhys DeVries
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 20m
                  20m