From ef1342f7588ce28933dd77288fff9908acff2034 Mon Sep 17 00:00:00 2001 From: congyi <15605187270@163.com> Date: Tue, 20 Feb 2024 16:56:20 +0800 Subject: [PATCH] some object store should set atomic_write_dir --- src/object_store/src/object/opendal_engine/fs.rs | 1 + src/object_store/src/object/opendal_engine/hdfs.rs | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/object_store/src/object/opendal_engine/fs.rs b/src/object_store/src/object/opendal_engine/fs.rs index 23d7dcbd503e8..7591501730a81 100644 --- a/src/object_store/src/object/opendal_engine/fs.rs +++ b/src/object_store/src/object/opendal_engine/fs.rs @@ -25,6 +25,7 @@ impl OpendalObjectStore { let mut builder = Fs::default(); builder.root(&root); + builder.atomic_write_dir(&root); let op: Operator = Operator::new(builder)? .layer(RetryLayer::default()) diff --git a/src/object_store/src/object/opendal_engine/hdfs.rs b/src/object_store/src/object/opendal_engine/hdfs.rs index b52be4094df80..39c089490d1dc 100644 --- a/src/object_store/src/object/opendal_engine/hdfs.rs +++ b/src/object_store/src/object/opendal_engine/hdfs.rs @@ -26,7 +26,7 @@ impl OpendalObjectStore { // Set the name node for hdfs. builder.name_node(&namenode); builder.root(&root); - + builder.atomic_write_dir(&root); let op: Operator = Operator::new(builder)? .layer(LoggingLayer::default()) .layer(RetryLayer::default())