JeremyXin commented on PR #11841:
URL: https://github.com/apache/seatunnel/pull/11841#issuecomment-5724313564

   @DanielLeens Thanks for the follow-up. I would like to clarify the current 
implementation against the Option 1 we discussed earlier.
   
   In your previous comment, Option 1 was described as:
   > “Always derive `isStartWithSavePoint` from `JobImmutableInformation`, then 
remove the extra re-derivation in `submitJob(...)`.”
   
   The latest change follows that approach.
   
   All currently reachable in-repository submission callers derive the legacy 
boolean from `JobImmutableInformation`:
   - `ClientJobProxy` passes `jobImmutableInformation.isSavepointRestore()`.
   - The cross-node submission path in `BaseService` passes 
`jobImmutableInformation.isSavepointRestore()`.
   - The direct submission path in `BaseService` also passes 
`jobImmutableInformation.isSavepointRestore()`.
   
   On the receiving side, `SubmitJobOperation` and the generated client 
protocol still preserve the legacy `isStartWithSavePoint` field and its 
serialization order. This is intentional because the field is still required 
for rolling-upgrade compatibility.
   
   The change in `CoordinatorService.submitJob` only removes the redundant 
second derivation from the deserialized payload. The method now uses the value 
supplied by its caller for the savepoint-specific cleanup and job-metrics 
branches. 
   
   `JobImmutableInformation` is still the source of truth when the value is 
constructed, while the legacy boolean remains the compatibility representation 
carried through the existing RPC path.
   
   The deserialization itself has not been removed. `JobImmutableInformation` 
is still deserialized because it is required by
   `validateCheckpointRestoreSourceJobIsTerminal(...)`. Only the duplicated 
restore-mode decision was removed.
   
   Therefore, reverting this change would restore the internal re-derivation 
that Option 1 was intended to eliminate. It would also make the method continue 
to ignore a parameter that all current callers already derive from 
`JobImmutableInformation`.


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