refactor: prune consumer storage compat paths (#3704)

This commit is contained in:
安正超
2026-06-22 02:31:30 +08:00
committed by GitHub
parent e528ee9452
commit d39815470e
14 changed files with 280 additions and 196 deletions
+8 -4
View File
@@ -13,9 +13,13 @@
// limitations under the License.
use rustfs_config::server_config::Config;
use rustfs_ecstore::api::{
config::com as ecstore_config_com, global::resolve_object_store_handle as ecstore_resolve_object_store_handle,
storage as ecstore_storage,
};
use std::sync::Arc;
type NotifyStore = rustfs_ecstore::api::storage::ECStore;
type NotifyStore = ecstore_storage::ECStore;
#[derive(Debug)]
pub(crate) enum NotifyConfigStoreError {
@@ -44,17 +48,17 @@ where
}
fn resolve_notify_object_store_handle() -> Option<Arc<NotifyStore>> {
rustfs_ecstore::api::global::resolve_object_store_handle()
ecstore_resolve_object_store_handle()
}
async fn read_notify_server_config_without_migrate(store: Arc<NotifyStore>) -> Result<Config, NotifyConfigStoreError> {
rustfs_ecstore::api::config::com::read_config_without_migrate(store)
ecstore_config_com::read_config_without_migrate(store)
.await
.map_err(|err| NotifyConfigStoreError::Read(err.to_string()))
}
async fn save_notify_server_config(store: Arc<NotifyStore>, config: &Config) -> Result<(), NotifyConfigStoreError> {
rustfs_ecstore::api::config::com::save_server_config(store, config)
ecstore_config_com::save_server_config(store, config)
.await
.map_err(|err| NotifyConfigStoreError::Save(err.to_string()))
}