Comment 1 for bug 1268739

Revision history for this message
Timur Alperovich (timur-alperovich) wrote : Re: For the Object Storage API, further describe subdir maker and delimiter

You probably should use the prefix parameter, rather than path. Setting prefix and delimiter resolves this for me: prefix "a/b/" and delimiter "/". This will return all objects that start with a/b/ and truncate to "/".

The documentation does mention that setting path is equivalent to setting prefix to "path" + "/" and delimiter to "/" (http://developer.openstack.org/api-ref-objectstorage-v1.html#showContainerDetails).

Note, however, that you may run into a relate issue: https://bugs.launchpad.net/swift/+bug/1475018
Essentially, if you create keys that start with "/" and want to list the contents under "/", it will not honor the delimiter setting and will list all keys in the container.