goutamadwant opened a new issue, #13774:
URL: https://github.com/apache/seatunnel/issues/13774

   ### Search before asking
   
   - [x] Searched open and closed issues and PRs for a separate 
early-validation follow-up.
   
   ### Description
   
   #13238 adds the positive-count rule for `multi_table_sink_replica` to the 
internal composite sink factory. The rule runs before the composite sink is 
constructed, but it can run after the engine has prepared the individual table 
sinks and applied their save modes. Connector option-rule discovery also does 
not expose the internal factory's constraint.
   
   For example, a Flink multi-table sink configured with 
`multi_table_sink_replica = 0` can reach per-table preparation and save-mode 
handling before composite factory validation rejects it. The job still fails, 
but connector setup may already have changed a destination table.
   
   ### Expected behavior
   
   - Reject `0` and negative replica counts at the applicable multi-table 
configuration entry point, before any per-table sink preparation or save-mode 
action. Report the option name and rejected value.
   - Make the positive-bound rule visible to option discovery for supported 
multi-table sink configurations. Reuse the same rule at the earlier entry point 
and at composite construction so the limits cannot drift.
   - Keep the option optional with type `int`, default `1`, and valid range `>= 
1`. Preserve valid create and restore behavior and the existing single-table 
and unsupported-connector paths.
   
   ### Validation
   
   Add a regression through an affected engine entry point that records sink 
preparation and save-mode calls. With `0` or `-1`, assert that the option is 
rejected and neither callback is invoked. Check omitted, `1`, and `4` values, 
the rule returned by option discovery, and a valid restore path. Cover other 
engine entry points where the validation is wired in.
   
   ### Related issues
   
   Follow-up to #13238 and part of #13232. See [the review 
discussion](https://github.com/apache/seatunnel/pull/13238#issuecomment-7263795690).
   
   - [Flink per-table setup and save-mode 
ordering](https://github.com/apache/seatunnel/blob/f5c412c967e6d62e4b1b365e0a07f6c074e99cd5/seatunnel-core/seatunnel-flink-starter/seatunnel-flink-starter-common/src/main/java/org/apache/seatunnel/core/starter/flink/execution/AbstractSinkExecuteProcessor.java#L145-L196)
   - [Composite factory 
validation](https://github.com/apache/seatunnel/blob/f5c412c967e6d62e4b1b365e0a07f6c074e99cd5/seatunnel-api/src/main/java/org/apache/seatunnel/api/table/factory/FactoryUtil.java#L271-L293)
   


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