etseidl commented on code in PR #10842:
URL: https://github.com/apache/arrow-rs/pull/10842#discussion_r3918644295


##########
parquet/src/file/metadata/mod.rs:
##########
@@ -2323,22 +2109,19 @@ mod tests {
         offset_index.append_row_count(1);
         offset_index.append_offset_and_size(2, 3);
         offset_index.append_unencoded_byte_array_data_bytes(Some(10));
-        let offset_index = Some(offset_index.build());
-
-        let page_index = PageIndex::new(
-            Some(vec![vec![Some(ColumnIndexMetaData::BOOLEAN(native_index))]]),
-            Some(vec![vec![offset_index]]),
-        );
+        let offset_index = offset_index.build();
+        page_index.put_offset_index(offset_index, 0, 0);
 
         let parquet_meta = ParquetMetaDataBuilder::new(file_metadata)
             .set_row_groups(row_group_meta)
-            .set_page_index(Some(page_index))
+            .set_page_index(Some(Arc::new(page_index.build())))
             .build();
 
+        // Size with page index (includes Arc overhead plus PageIndex heap 
size)
         #[cfg(not(feature = "encryption"))]
-        let bigger_expected_size = 3248;
+        let bigger_expected_size = 3280;

Review Comment:
   This increases due to the `PageIndex` now living on the heap along with Arc 
overhead



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

Reply via email to