Billing:Get Bucket Billing Sample

Search (SHIFT+S)




New in this release

Get Bucket Billing Sample

GET /object/billing/buckets/{namespace}/{bucketName}/sample

Gets billing details for the specified namespace, interval and bucket details. By default, buckets are sampled every 5 minutes. If the requested time range includes multiple samples, the data will be aggregated.

namespaceNamespace containing the bucket
bucketNameBucket name

Query Parameters

start_timeStarting time for the sample(s) in ISO-8601 minute format. Time must be a multiple of 5 minutes or an error will be returned.
end_timeEnding time for the sample(s) in ISO-8601 minute format. Time must be a multiple of 5 minutes or an error will be returned.
sizeunitUnit to be used for calculating the size on disk (KB,MB and GB. GB is default value).

Required Roles

Requires one of the following roles:

  • SYSTEM_ADMIN

  • SYSTEM_MONITOR

  • NAMESPACE_ADMIN


Prerequisites

The following conditions must be met in order to call this operation.

  • Namespace and Bucket should exist


Response Body

The bucket's usage for the requested time period.

Field Description Type Notes
<bucket_billing_sample>
<namespace> Namespace String
<name> Bucket name String
<vpool_id> Replication group identifier String
<sample_start_time> Sample start time String
<sample_end_time> Sample end time String
<objects_created> Number of objects created Long
<objects_deleted> Number of objects deleted Long
<bytes_delta> Bytes delta Long
<total_size> Total size Long
<total_size_unit> Total size unit String
<total_objects> Total objects Long
<ingress> Ingress Long
<egress> Egress Long
<tags>
<tag>     0-* Elements
<name> Name String
<ingress> Ingress Long
<egress> Egress Long
</tag>      
</tags>
<next_marker> Next marker String
</bucket_billing_sample>

Examples

Request
GET https://192.168.0.0:4443/object/billing/buckets/s3/standalone-bucket/sample?start_time=2015-01-16T22:20&end_time=2015-04-16T22:20 HTTP/1.1  

Concept-Type: application/xml 
X-SDS-AUTH-TOKEN: <AUTH_TOKEN>
Response
HTTP/1.1 200 OK
Content-Type: application/xml 

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<bucket_billing_sample>
    <namespace>s3</namespace>
    <name>standalone-bucket</name>
    <vpool_id>urn:storageos:ReplicationGroupInfo:b3bf2d47-d732-457c-bb9b-d260eb53a76b:global</vpool_id>
    <sample_start_time>2015-01-16T22:20:00Z</sample_start_time>
    <sample_end_time>2015-04-16T22:20:00Z</sample_end_time>
    <objects_created>0</objects_created>
    <objects_deleted>0</objects_deleted>
    <bytes_delta>0</bytes_delta>
    <total_size_in_gb>0.0</total_size_in_gb>
    <total_objects>0</total_objects>
    <ingress>0</ingress>
    <egress>0</egress>
</bucket_billing_sample>
Notes: