object-api/v1/section_object-api-large-li...

59 lines
2.9 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE section [
<!-- Some useful entities borrowed from HTML -->
<!ENTITY ndash "&#x2013;">
<!ENTITY mdash "&#x2014;">
<!ENTITY hellip "&#x2026;">
]>
<section xmlns="http://docbook.org/ns/docbook"
xmlns:xi="http://www.w3.org/2001/XInclude"
xmlns:xlink="http://www.w3.org/1999/xlink" version="5.0"
xml:id="large-lists">
<title>Page through large lists of containers or objects</title>
<para>If you have a large number of containers or objects, you can
use the <parameter>marker</parameter>,
<parameter>limit</parameter>, and
<parameter>end_marker</parameter> parameters to control
how many items are returned in a list and where the list
starts or ends.</para>
<itemizedlist>
<listitem>
<para><emphasis role="bold"><parameter>marker</parameter>
parameter</emphasis>. 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 <parameter>marker</parameter> parameter. Set the
<literal>marker</literal> parameter to the name of
the last item returned in the previous list. You must
URL-encode the <parameter>marker</parameter> value
before you send the HTTP request. Object Storage
returns a maximum of 10,000 names again.</para>
</listitem>
<listitem>
<para><emphasis role="bold"><parameter>limit</parameter>
parameter</emphasis>. To return fewer than 10,000
names, use the <parameter>limit</parameter> parameter.
If the number of names returned equals the specified
<parameter>limit</parameter> (or 10,000 if you
omit the <parameter>limit</parameter> parameter), you
can assume there are more names to list. If the number
of names in the list is exactly divisible by the
<parameter>limit</parameter> value, the last
request has no content.</para>
</listitem>
<listitem>
<para><emphasis role="bold"
><parameter>end_marker</parameter>
parameter</emphasis>. Limits the result set to
names that are less than the
<parameter>end_marker</parameter> parameter value.
You must URL-encode the
<parameter>end_marker</parameter> value before you
send the HTTP request.</para>
</listitem>
</itemizedlist>
<para>For examples of how to page through large lists, see <xref
linkend="examples"/>.</para>
</section>