You can use delimiter, marker, max-keys, and prefix query parameters, alone or in combination with each other, to limit the list of the current items in a bucket.
delimiter
You use the delimiter query parameter to request a bucket listing that includes a list of common prefixes, where a prefix is the name of an item up through the first occurrence of the character string specified by the delimiter parameter. Each common prefix is listed only once regardless of the number of items with matching names. The items with matching names are not included elsewhere in the listing.
The returned listing also contains items with names that do not include the character string specified by the delimiter parameter. In the listing, all the named items are listed first, followed by all the common prefixes.
For example, the bucket listing returned in response to a GET request with the delimiter=budget_proposals query parameter contains these items and common prefixes:
Items:
AcctgBestPractices.doc (current version)
acctg/
hum_res/
mktg/
mktg/campaign_GoGetEm_expenses.xls (current version)
mktg/campaign_LiveIt_expenses.xls
quarterly_rpts/
quarterly_rpts/Q2_2012.ppt
quarterly_rpts/Q3_2012.ppt
quarterly_rpts/Q4_2012.ppt
sales/
sales_quotas_2013.pdf
Common prefixes:
acctg/budget_proposals/
hum_res/budget_proposals/
mktg/budget_proposals/
sales/budget_proposals/
The lists of named items and common prefixes included in a listing are subject to any other criteria specified in the request.
Both named items and common prefixes count toward the maximum number of items that can be included in the bucket listing.
marker
You use the marker query parameter to start the returned bucket listing with the item following the first item with a name that starts with the character string specified by the marker parameter.
For example, the bucket listing returned in response to a GET request with the marker=quarterly_rpts/ query parameter contains these items:
quarterly_rpts/Q2_2012.ppt
quarterly_rpts/Q3_2012.ppt
quarterly_rpts/Q4_2012.ppt
sales/
sales/budget_proposals/
sales/budget_proposals/BudgProp-2013
sales_quotas_2013.pdf
The marker query parameter is useful when more than the requested number of items satisfy the request criteria. In this case, the response body includes the IsTruncated element with a value of true. You can request the next part of the listing by including the marker query parameter in a new request. As the parameter value, you specify either the name of the last item in the returned listing or the last common prefix in the returned listing, whichever is alphanumerically greater.
If the string you specify as the value of the marker query parameter is the name of a folder and does not end with a forward slash (/), items that begin with that string followed by a forward slash are omitted from the listing.
max-keys
You use the max-keys query parameter to limit the number of items in the returned bucket listing to fewer than one thousand.
For example, the bucket listing returned in response to a GET request with the max-keys=5 query parameter contains these items:
AcctgBestPractices.doc (current version)
acctg/
acctg/budget_proposals/
acctg/budget_proposals/BudgProp-2013
hum_res/
prefix
You use the prefix query parameter to request a bucket listing that contains only items with names that begin with a specified character string (the prefix) and, if applicable, common prefixes that begin that prefix.
For example, the bucket listing returned in response to a GET request with the prefix=sales query parameter contains only these items:
sales/
sales/budget_proposals/
sales/budget_proposals/BudgProp-2013
sales_quotas_2013.pdf
© 2016 Hitachi Data Systems Corporation. All rights reserved.