tustvold commented on code in PR #3967: URL: https://github.com/apache/arrow-rs/pull/3967#discussion_r1150822070
########## parquet/src/arrow/async_writer/mod.rs: ########## @@ -135,64 +135,68 @@ impl<W: AsyncWrite + Unpin + Send> AsyncArrowWriter<W> { let metadata = self.sync_writer.close()?; // Force to flush the remaining data. - Self::try_flush(&self.shared_buffer, &mut self.async_writer, 0).await?; + Self::try_flush(&mut self.shared_buffer, &mut self.async_writer, 0).await?; Ok(metadata) } /// Flush the data in the [`SharedBuffer`] into the `async_writer` if its size /// exceeds the threshold. async fn try_flush( - shared_buffer: &SharedBuffer, + shared_buffer: &mut SharedBuffer, Review Comment: The use of try_lock here boils down to much the same thing - https://docs.rs/futures-util/0.3.27/src/futures_util/lock/mutex.rs.html#103 -- 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: github-unsubscr...@arrow.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org