Uploaded image for project: 'jclouds'
  1. jclouds
  2. JCLOUDS-1422

LocalBlobStore.list ignores recursive flag when prefix set

    XMLWordPrintableJSON

Details

    • Patch

    Description

      While calling jclouds code to list a container I noticed that while the S3 implementation can handle both prefix and recursive on or off, when using the transient implementation the recursive flag seems to be ignored—the code always behaves as if it were on. I looked into LocalBlobStore.list and saw that indeed since JCLOUDS-930 the implementation just checks prefix before recursive and in that case calls filterPrefix which ignores recursive without calling extractCommonPrefixes like all other code branchs called when !recursive. It was tricky to see what exactly the desired behavior was (especially when the prefix does not end with the separator/delimiter), since the Javadoc of ListContainerOptions is sparse and vague, but I reasoned that the current behavior was wrong since

      • the S3 implementation behaves differently
      • the current implementation quietly fails to differentiate two option combinations, with no code in ListContainerOptions indicating that one implies the other

      Attachments

        Issue Links

          Activity

            People

              gaul Andrew Gaul
              jglick@netbeans.org Jesse Glick
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: