Add support to change storage class (e.g. to warm-up data)
- Dominant language
- Rust
- Stars
- 5.4k
- Forks
- 825
- Avg merge
- 1d 14m
- Merged PRs (30d)
- 127
Description
Opendal already supports specifying storage classes, e.g. for AWS S3:
```
default_storage_class = "DEEP_ARCHIVE"
```
Now, sometimes you want or need to change the storage class. In this example, before being able to access the data in AWS Glacier Deep Archive, you need to warm-up the data by requesting to change the storage class to "STANDARD".
It would be very nice if the opendal service directly supports this kind of storage class change, e.g. something like
```
let mut builder = S3::default();
builder.bucket("test");
builder.default_storage_class("DEEP_ARCHIVE");
let op: Operator = Operator::new(builder)?.finish();
op.change_state("hello.txt", "STANDARD")?.await?;
```
There are some cases to consider:
- The changing might need/supportextra options. E.g. it could be a temporally storage class transition only for a given time period
- The actual transition might take some time (especially in the case of warming-up data), so the command in fact might return a result from the service.
As a reference, where such things are useful, see https://github.com/rustic-rs/rustic/discussions/692.
Contributor guide
Research direction
Start by reviewing the Operator API and the S3 builder entry points shown in the issue, then compare how storage classes are currently specified. Define the change operation's options and result behavior, including asynchronous transitions and temporary changes. Done means a consistent API can request a storage-class change for the relevant services and its behavior is covered by tests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, rust
- Domain
- cloud
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100