You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by "CTTY (via GitHub)" <gi...@apache.org> on 2026/01/29 02:05:01 UTC

Re: [PR] feat!(io): Implement Storage for OpenDal [iceberg-rust]

CTTY commented on code in PR #2080:
URL: https://github.com/apache/iceberg-rust/pull/2080#discussion_r2739394006


##########
crates/iceberg/src/io/file_io.rs:
##########
@@ -433,9 +377,7 @@ impl OutputFile {
     /// Calling `write` will overwrite the file if it exists.
     /// For continuous writing, use [`Self::writer`].
     pub async fn write(&self, bs: Bytes) -> crate::Result<()> {
-        let mut writer = self.writer().await?;
-        writer.write(bs).await?;
-        writer.close().await
+        self.storage.write(&self.path, bs).await

Review Comment:
   I think there is a minor behavior difference here. The new implementation calls `Operator::write` directly while the old one uses `Writer::write` and then explicitly closes it.
   
   According to [OpenDal's doc](https://docs.rs/opendal/latest/opendal/struct.Operator.html#method.write), the difference seems trivial



-- 
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: issues-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org