| « PreviousNext » | |
![]() ![]() | Did this page help you? Yes | No | Tell us about it... |
Note
Logging functionality is currently in beta.
This implementation of the GET operation uses the
logging subresource to return the logging status of a bucket
and the permissions users have to view and modify that status. To use GET,
you must be the bucket owner.
GET /?logging HTTP/1.1 Host:BucketName.s3.amazonaws.com Date:dateAuthorization:signature
This implementation of the operation does not use request parameters.
This implementation of the operation uses only request headers that are common to all operations. For more information, see Common Request Headers.
This implementation of the operation does not use request elements.
This implementation of the operation uses only response headers that are common to most responses. For more information, see Common Response Headers.
| Name | Description |
|---|---|
BucketLoggingStatus
|
Container for the response. Type: Container Ancestry: None |
EmailAddress
|
E-mail address of the person whose logging permissions are displayed. Type: String Ancestry: BucketLoggingStatus.LoggingEnabled.TargetGrants.Grant.Grantee |
Grant
|
Container for Type: Container Ancestry: BucketLoggingStatus.LoggingEnabled.TargetGrants |
Grantee
|
Container for Type: Container Ancestry: BucketLoggingStatus.LoggingEnabled.TargetGrants.Grant |
LoggingEnabled
|
Container for logging information. This element and its children are present when logging is enabled, otherwise, this element and its children are absent. Type: Container Ancestry: BucketLoggingStatus |
Permission
|
Logging permissions assigned to the Type: String Valid Values: FULL_CONTROL | READ | WRITE Ancestry: BucketLoggingStatus.LoggingEnabled.TargetGrants.Grant |
TargetBucket
|
Specifies the bucket whose logging status is being returned. This element specifies the bucket where server access logs will be delivered. Type: String Ancestry: BucketLoggingStatus.LoggingEnabled |
TargetGrants
|
Container for granting information. Type: Container Ancestry: BucketLoggingStatus.LoggingEnabled |
TargetPrefix
|
Specifies the prefix for the keys that the log files are being stored under. Type: String Ancestry: BucketLoggingStatus.LoggingEnabled |
This implementation of the operation does not return special errors. For general information about Amazon S3 errors and a list of error codes, see Error Responses.
The following request returns the logging status for mybucket.
GET ?logging HTTP/1.1 Host: mybucket.s3.amazonaws.com Date: Wed, 25 Nov 2009 12:00:00 GMT Authorization: AWS AKIAIOSFODNN7EXAMPLE:0RQf4/cRonhpaBX5sCYVf1bNRuU=
HTTP/1.1 200 OK
Date: Wed, 25 Nov 2009 12:00:00 GMT
Connection: close
Server: AmazonS3
<?xml version="1.0" encoding="UTF-8"?>
<BucketLoggingStatus xmlns="http://doc.s3.amazonaws.com/2006-03-01">
<LoggingEnabled>
<TargetBucket>mybucketlogs</TargetBucket>
<TargetPrefix>mybucket-access_log-/</TargetPrefix>
<TargetGrants>
<Grant>
<Grantee xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:type="AmazonCustomerByEmail">
<EmailAddress>user@company.com</EmailAddress>
</Grantee>
<Permission>READ</Permission>
</Grant>
</TargetGrants>
</LoggingEnabled>
</BucketLoggingStatus>HTTP/1.1 200 OK Date: Wed, 25 Nov 2009 12:00:00 GMT Connection: close Server: AmazonS3 <?xml version="1.0" encoding="UTF-8"?> <BucketLoggingStatus xmlns="http://doc.s3.amazonaws.com/2006-03-01" />