rdettai commented on a change in pull request #1062:
URL: https://github.com/apache/arrow-datafusion/pull/1062#discussion_r724820652
##########
File path: datafusion/src/datasource/object_store/mod.rs
##########
@@ -86,11 +101,17 @@ pub trait ObjectStore: Sync + Send + Debug {
delimiter: Option<String>,
) -> Result<ListEntryStream>;
+ /// Get object reader for the path of one file
+ fn file_reader_from_path(&self, file_path: &str) -> Result<Arc<dyn
ObjectReader>>;
+
/// Get object reader for one file
fn file_reader(&self, file: FileMeta) -> Result<Arc<dyn ObjectReader>>;
}
-static LOCAL_SCHEME: &str = "file";
+lazy_static! {
+ static ref OBJECT_STORES: Box<ObjectStoreRegistry> =
+ Box::new(ObjectStoreRegistry::new());
+}
Review comment:
In #1072 the consensus seems to be that we should avoid using `static`
for the registry.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]