fenfeng9 commented on code in PR #49334:
URL: https://github.com/apache/arrow/pull/49334#discussion_r2966746612


##########
cpp/src/parquet/bloom_filter_reader.cc:
##########
@@ -76,10 +83,39 @@ std::unique_ptr<BloomFilter> 
RowGroupBloomFilterReaderImpl::GetColumnBloomFilter
           "bloom filter length + bloom filter offset greater than file size");
     }
   }
-  auto stream = ::arrow::io::RandomAccessFile::GetStream(
-      input_, *bloom_filter_offset, file_size - *bloom_filter_offset);
+  std::unique_ptr<ColumnCryptoMetaData> crypto_metadata = 
col_chunk->crypto_metadata();
+  std::unique_ptr<Decryptor> header_decryptor =
+      
InternalFileDecryptor::GetColumnMetaDecryptorFactory(file_decryptor_.get(),
+                                                           
crypto_metadata.get())();
+  std::unique_ptr<Decryptor> bitset_decryptor =
+      
InternalFileDecryptor::GetColumnDataDecryptorFactory(file_decryptor_.get(),

Review Comment:
   > Why keeping two decryptors while they are the same? This looks odd and may 
mislead readers that they are different.
   
   Updated. I simplified this to use a single metadata decryptor for both the 
bloom filter header and bitset, and moved the encrypted path into 
`BlockSplitBloomFilter::DeserializeEncrypted(...)`.
   
   



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