Page through large lists of containers or objects

If you have a large number of containers or objects, you can use the marker, limit, and end_marker parameters to control how many items are returned in a list and where the list starts or ends.

  • marker parameter. When you request a list of containers or objects, Object Storage returns a maximum of 10,000 names for each request. To get subsequent names, you must make another request with the marker parameter. Set the marker parameter to the name of the last item returned in the previous list. You must URL-encode the marker value before you send the HTTP request. Object Storage returns a maximum of 10,000 names again.

  • limit parameter. To return fewer than 10,000 names, use the limit parameter. If the number of names returned equals the specified limit (or 10,000 if you omit the limit parameter), you can assume there are more names to list. If the number of names in the list is exactly divisible by the limit value, the last request has no content.

  • end_marker parameter. Limits the result set to names that are less than the end_marker parameter value. You must URL-encode the end_marker value before you send the HTTP request.

For examples of how to page through large lists, see Chapter 3, Object Storage API examples.

Questions? Discuss on ask.openstack.org
Found an error? Report a bug against this page

loading table of contents...