Apache DataFusion SQL Query Engine
docs: Remove stale "temporary fix" note from `get_record_batch_memory_size` (#24674)
Andrew Lamb9617fdfee12b
diff --git a/datafusion/common/src/utils/memory.rs b/datafusion/common/src/utils/memory.rsindex c68640d0fa..b842c7e21f 100644--- a/datafusion/common/src/utils/memory.rs+++ b/datafusion/common/src/utils/memory.rs@@ -142,10 +142,9 @@ pub fn estimate_memory_size<T>(num_elements: usize, fixed_size: usize) -> Result/// In the above case, `get_record_batch_memory_size` will return the size of/// the buffer, instead of the sum of `col1` and `col2`'s actual memory size.///-/// Note: The current [`RecordBatch::get_array_memory_size`] will double count-/// the buffer memory size if multiple arrays within the batch are sharing the-/// same `Buffer`. This method provides a temporary fix until the issue is-/// resolved: <https://github.com/apache/arrow-rs/issues/6439>+/// Note: [`RecordBatch::get_array_memory_size`] double counts the buffer+/// memory size if multiple arrays within the batch are sharing the same+/// `Buffer`, while this function counts each `Buffer` exactly once.pub fn get_record_batch_memory_size(batch: &RecordBatch) -> usize {RecordBatchMemoryCounter::new().count_batch(batch)}