nada-attia opened a new issue, #18245:
URL: https://github.com/apache/hudi/issues/18245

   ### Problem Statement
   
   Currently, Hudi only supports pre-commit validators that run after data has 
been written but before commit. There's no way to validate and fail early 
before write operations begin, which can waste resources on writes that will 
eventually fail validation.
   
   ### Proposed Solution
   
   Add a pluggable pre-write validation framework that allows custom validators 
to run before write operations begin. This enables:
   - Early detection of validation failures before any write work begins
   - Resource savings by preventing unnecessary write operations
   - Custom business logic validation at the pre-write stage
   
   ### Implementation Details
   
   The implementation includes:
   - `PreWriteValidator` interface for implementing custom pre-write validators
   - `PreWriteValidatorUtils` utility class to load and run configured 
validators
   - `HoodiePreWriteValidatorConfig` configuration class with 
`hoodie.prewrite.validators` property
   - Integration into `BaseHoodieWriteClient.preWrite()` to invoke configured 
validators
   - Configuration property: `hoodie.prewrite.validators` (comma-separated list 
of validator class names)
   
   ### Related PR
   
   #18239
   
   ### Impact
   
   - New public API that users can implement for custom validators
   - Opt-in feature via configuration
   - No breaking changes or performance impact when disabled
   - Risk Level: Low


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