danny0405 opened a new pull request, #19543:
URL: https://github.com/apache/hudi/pull/19543

   ### Describe the issue this Pull Request addresses
   
   The experimental Flink Sink V2 path had no unit coverage for its clustering 
commit, compaction commit, cleaning, and pipeline composition classes. This 
left checkpoint-driven cleaning, commit buffering and rollback behavior, and 
topology routing unverified even though the V2 API is available for 
experimentation.
   
   This PR adds operator-level tests and raises every targeted V2 class above 
70% line coverage. It does not change storage formats, public APIs, 
configuration defaults, or runtime behavior.
   
   ### Summary and Changelog
   
   - Add `ProcessOperator` and `OneInputStreamOperatorTestHarness` coverage for 
`CleanFunctionV2`, including asynchronous cleaning, checkpoint completion, 
disabled cleaning, and fail-safe snapshot behavior.
   - Add commit harness tests for `ClusteringCommitSinkV2`, covering missing 
plans, partial buffering, failed-event rollback, write errors, successful 
commits, and inline cleaning.
   - Add equivalent commit harness tests for `CompactionCommitSinkV2`.
   - Add topology and routing coverage for `PipelinesV2`, including bulk 
insert, append, clustering, cleaning, compaction, and plain write modes.
   - Raise line coverage from 0% to 91.5% for `ClusteringCommitSinkV2`, 91.5% 
for `CompactionCommitSinkV2`, 89.4% for `PipelinesV2`, and 100% for 
`CleanFunctionV2`.
   - Reuse the existing V1 sink test scenario structure within Hudi and adapt 
it to the V2 `ProcessOperator` harness; no external code was copied.
   
   ### Impact
   
   Test-only change in `hudi-flink`. There is no public API, configuration, 
compatibility, performance, storage-format, or user-facing behavior impact.
   
   ### Risk Level
   
   low
   
   The change only adds unit tests. It was verified with the focused 15-test V2 
suite and the full `hudi-flink` unit suite (1,555 tests passed, 1 skipped), and 
all four targeted classes exceed the requested 70% line-coverage threshold.
   
   ### Documentation Update
   
   none. This PR does not introduce or change user-facing functionality or 
configuration.
   
   ### Contributor's checklist
   
   - [x] Read through [contributor's 
guide](https://hudi.apache.org/contribute/how-to-contribute)
   - [x] Enough context is provided in the sections above
   - [x] Adequate tests were added if applicable


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