tonbo-io / tonbo

A portable embedded database using Arrow.
https://tonbo.io
Apache License 2.0
795 stars 46 forks source link

Chore: add `DbOption` supports setting the s3 `FsOptions` of all sstables #239

Open KKould opened 1 day ago

KKould commented 1 day ago

What is the current?

Currently, tonbo needs to be able to set each level's sstables to be stored in different S3 configurations, but there is no option to set all sstables in the same S3 configuration at once.In many cases we only need to set it up in the same S3 configuration

options = options
                // TODO: We can add an option user to set all SSTables to use the same URL.
                .level_path(0, url.clone(), fs_option.clone())
                .unwrap()
                .level_path(1, url.clone(), fs_option.clone())
                .unwrap()
                .level_path(2, url.clone(), fs_option.clone())
                .unwrap()
                .level_path(3, url.clone(), fs_option.clone())
                .unwrap()
                .level_path(4, url.clone(), fs_option.clone())
                .unwrap()
                .level_path(5, url.clone(), fs_option.clone())
                .unwrap()
                .level_path(6, url, fs_option.clone())
                .unwrap();

What will it become?

options = options
                .all_level_path(url.clone(), fs_option.clone())
                .unwrap()

What are the benefits?

simple

Are there any alternatives?

maybe

Does it have a reference?

nope

linear[bot] commented 1 day ago

TON-95 Chore: add `DbOption` supports setting the s3 `FsOptions` of all sstables

ethe commented 1 day ago

As a good first issue, it is not clear to start, it should be added more description about it.