alamb commented on code in PR #16649: URL: https://github.com/apache/datafusion/pull/16649#discussion_r2180912655
########## datafusion/datasource-parquet/src/file_format.rs: ########## @@ -350,15 +352,17 @@ impl FileFormat for ParquetFormat { Some(time_unit) => Some(parse_coerce_int96_string(time_unit.as_str())?), None => None, }; - let config_file_decryption_properties = &self.options.crypto.file_decryption; + #[cfg(feature = "parquet_encryption")] Review Comment: It would be great if there wa ssome way to encapsulate this somehow into a function or something that could be cfg'd rather than sprinking them around For example, something like ``` #[cfg(..)] fn add_crypto_properties(...) ``` ########## datafusion/common/src/config.rs: ########## @@ -29,12 +29,16 @@ use std::error::Error; use std::fmt::{self, Display}; use std::str::FromStr; -#[cfg(feature = "parquet")] +#[cfg(feature = "parquet_encryption")] Review Comment: I wonder if we can move all the crypto code into its own module, so we only have to `#cfg` the module rather than so many individual lines 🤔 -- 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...@datafusion.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org For additional commands, e-mail: github-h...@datafusion.apache.org