blackmwk commented on code in PR #2247:
URL: https://github.com/apache/iceberg-rust/pull/2247#discussion_r2963582885


##########
crates/iceberg/src/io/storage/mod.rs:
##########
@@ -128,6 +129,19 @@ pub trait Storage: Debug + Send + Sync {
 /// ```
 #[typetag::serde(tag = "type")]
 pub trait StorageFactory: Debug + Send + Sync {
+    /// Create a new factory instance enriched with table metadata.
+    ///
+    /// This allows storage factories to incorporate table-level metadata
+    /// (e.g., table properties) into the storage initialization.
+    ///
+    /// Implementations that don't need table metadata should return
+    /// a clone of themselves: `Ok(Arc::new(self.clone()))`.
+    ///
+    /// # Arguments
+    ///
+    /// * `metadata` - The table metadata to incorporate
+    fn with_metadata(&self, metadata: &TableMetadata) -> Result<Arc<dyn 
StorageFactory>>;

Review Comment:
   I think this should be part of `build` method?



-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to