Soham-Bhattacharjee-work commented on code in PR #21985: URL: https://github.com/apache/datafusion/pull/21985#discussion_r3184463259
########## docs/source/library-user-guide/upgrading/54.0.0.md: ########## @@ -447,6 +447,109 @@ let config_decryption_properties = ConfigFileDecryptionProperties::try_from(&dec See [#21602](https://github.com/apache/datafusion/issues/21602) and [PR #21603](https://github.com/apache/datafusion/pull/21603) for details. +### Conversion from `ConfigFileEncryptionProperties` / `ConfigFileDecryptionProperties` is now fallible + +Previously, `datafusion_common::config::ConfigFileEncryptionProperties` and +`datafusion_common::config::ConfigFileDecryptionProperties` implemented infallible +conversions into Parquet's encryption/decryption types: + +- `impl From<ConfigFileEncryptionProperties> for parquet::encryption::encrypt::FileEncryptionProperties` +- `impl From<ConfigFileDecryptionProperties> for parquet::encryption::decrypt::FileDecryptionProperties` + +These conversions may need to decode hex-encoded keys and other configuration values, which can fail. +They now use `TryFrom` and return a `Result`: + +- `impl TryFrom<ConfigFileEncryptionProperties> for FileEncryptionProperties` +- `impl TryFrom<ConfigFileDecryptionProperties> for FileDecryptionProperties` + +**Migration guide:** + +Replace `from()` / `into()` with `try_from()` / `try_into()` and handle the resulting `Result`. + +**Before:** + +```rust,ignore Review Comment: Done. -- 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] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
