Get Blob Service Stats

4 minutes to read

Contributors

In this article

The Get Blob Service Stats operation retrieves statistics related to replication for the Blob service. It is only available on the secondary location endpoint when read-access geo-redundant replication is enabled for the storage account.

Request

The Get Blob Service Stats request may be constructed as follows. HTTPS is recommended. Replace myaccount with the name of your storage account, and note that the -secondary suffix is required:

Request Body

None.

Response

The response includes an HTTP status code, a set of response headers, and a response body

Status Code

A successful operation returns status code 200 (OK). When called on secondary location endpoint which is not enabled for secondary read, it will return Http status code of 403 with InsufficientAccountPermissions error.

- live: Indicates that the secondary location is active and operational.- bootstrap: Indicates initial synchronization from the primary location to the secondary location is in progress. This typically occurs when replication is first enabled.- unavailable: Indicates that the secondary location is temporarily unavailable.

LastSyncTime

A GMT date/time value, to the second. All primary writes preceding this value are guaranteed to be available for read operations at the secondary. Primary writes after this point in time may or may not be available for reads.

The value may be empty if LastSyncTime is not available. This can happen if the replication status is bootstrap or unavailable.

Although geo-replication is continuously enabled, the LastSyncTime result may reflect a cached value from the service that is refreshed every few minutes.

Authorization

Only the account owner may call this operation.

Remarks

The location where you read, create, update, or delete data is the primary storage account location. The primary location exists in the region you choose at the time you create an account via the Azure Management Azure classic portal, for example, North Central US. The location to which your data is replicated is the secondary location. The secondary location is automatically determined based on the location of the primary; it is in a second data center that resides in the same region as the primary location. Read-only access is available from the secondary location, if read-access geo-redundant replication is enabled for your storage account. For more details about read-access geo-redundant replication, see the Azure Storage Team Blog.

To construct a request for a read operation against the secondary endpoint, append -secondary as a suffix to the account name in the URI that you use to read from Blob storage. For example, a secondary URI for the Get Blob operation will be similar to https://myaccount-secondary.blob.core.windows.net/mycontainer/myblob.

Sample Request and Response

The following is a sample request for the Get Blob Service Stats operation:

GET http://myaccount-secondary.blob.core.windows.net/?restype=service&comp=stats HTTP/1.1

See Also

The feedback system for this content will be changing soon. Old comments will not be carried over. If content within a comment thread is important to you, please save a copy. For more information on the upcoming change, we invite you to read our blog post.