Direct Reading
Scenarios
You can enable direct reading if you want to obtain Archive objects immediately or if there are interface compatibility issues when OBS is interconnected with other systems. You can enable direct reading for Archive objects, so that you can download or read them, configure their ACL, change their storage class, and access them with URLs, without having to restore them first.
With direct reading enabled for a bucket, you can access objects in the Archive storage class without restoring them first. However, downloading or copying Archive objects will incur costs for directly reading these objects. For details, see Product Pricing Details.
This section describes how to enable direct reading for objects in an existing bucket. If you want to enable Direct Reading when creating a bucket, see Creating a Bucket.
Object Retrieval Comparison Before and After Direct Reading Is Enabled
| Item | Direct Reading Disabled (Default) | Direct Reading Enabled |
|---|---|---|
| Retrieval method | Objects are restored and then read. | Objects are directly read. |
| Retrieval cost | Low | High |
| Retrieval time | Minutes | Milliseconds |
Billing
After enabling direct reading for a bucket, you can access objects in the Archive storage class without restoring them first. Downloading or copying Archive objects will incur direct reading traffic costs. For details about the billing and pricing, see Table 1 and OBS Pricing Details.
| Action | Billing Item | Description | Billing Mode |
|---|---|---|---|
| Direct reading | Requests | You are billed for the number of successfully read objects. If N objects are successfully read, you are billed for N requests. | Pay-per-use |
| Direct reading traffic | Traffic for downloading and replicating Archive objects from a bucket with direct reading enabled. For more information, see Direct Reading. The amount of data retrieved is determined by the range specified in the request header when the HTTP connection is established. Even if the transmission is interrupted early, the system calculates usage based on the full range defined in the original request. For example, if the request specifies a range from 50 MB to 100 MB, the system still bills you for the range of 50 MB to 100 MB, even if only one byte is actually transmitted. | Pay-per-use | |
| Outbound Internet traffic (when objects are accessed over the Internet) | If you download or replicate objects over the Internet, the outbound Internet traffic costs will be incurred based on the object size. | Pay-per-use |
Example: Billing for downloading objects from a bucket with or without direct reading enabled
Assume that you need to download 100 Archive objects (100 GB in total) over the Internet. The following table compares the billing for downloading these objects from a bucket with direct reading enabled or disabled.
| Billing Item | A Bucket Without Direct Reading Enabled | A Bucket With Direct Reading Enabled |
|---|---|---|
| Restore requests | 100 PUT requests | N/A |
| Download requests | 100 GET requests | 100 GET requests |
| Temporary storage | Storage for 100 GB of Standard copies, which is charged once | N/A |
| Restore traffic | Assume that you use expedited restore, there will be traffic for restoring 100 GB of data at an expedited speed. | N/A |
| Direct reading traffic | N/A | Direct reading traffic for 100 GB of data |
| Outbound Internet traffic | Outbound Internet traffic for 100 GB of data | Outbound Internet traffic for 100 GB of data |
Constraints
- You must have the obs:object:restoreObject permission. For details, see Granting Permissions to an IAM User Under the Current Account.
- Direct reading applies only to data stored in the Archive storage class. Data stored in the Deep Archive storage class does not support direct reading. After direct reading is enabled, you can download Archive data without restoring it first.
- If direct reading is enabled for a bucket but the bucket contains static websites, restore data before accessing the static websites. Otherwise, the access will fail.
Ways to Configure Direct Reading
You can use OBS Console or APIs to configure direct reading.
Logging and Monitoring
You can use CTS and OBS logging to record direct reading operations on a bucket.
Using CTS to audit OBS operations: CTS records events for configuring, obtaining, or deleting direct reading access. It stores these records and provides query capabilities for security analysis, compliance auditing, resource tracking, and fault locating. For details, see Using CTS to Audit OBS.
Configuring logging: You can enable logging to record operations for configuring, obtaining, or deleting direct reading access. Detailed logs can be queried for further auditing or analysis. For details, see Using Logging to Record OBS Logs.
What is your overall rating for this page?
Thank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot
