You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2021/12/20 19:29:54 UTC

[GitHub] [arrow-rs] alamb commented on a change in pull request #1035: Improve parquet performance: Skip levels computation for required struct arrays in parquet

alamb commented on a change in pull request #1035:
URL: https://github.com/apache/arrow-rs/pull/1035#discussion_r772614253



##########
File path: parquet/src/arrow/array_reader.rs
##########
@@ -1149,68 +1155,75 @@ impl ArrayReader for StructArrayReader {
             return Err(general_err!("Not all children array length are the same!"));
         }
 
-        // calculate struct def level data
-        let buffer_size = children_array_len * size_of::<i16>();
-        let mut def_level_data_buffer = MutableBuffer::new(buffer_size);
-        def_level_data_buffer.resize(buffer_size, 0);
+        // Now we can build array data
+        let mut array_data = ArrayDataBuilder::new(self.data_type.clone())

Review comment:
       Maybe calling this variable `array_data_builder` would be clearer as it not `ArrayData`?




-- 
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-unsubscribe@arrow.apache.org

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