You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@seatunnel.apache.org by "DanielLeens (via GitHub)" <gi...@apache.org> on 2026/09/05 16:20:10 UTC

[I] [Improve][Zeta] Preserve pending-queue order across master failover [seatunnel]

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

   ## Description
   
   This is a design task for the pending-queue ordering contract across master failover. It is not a regression report, and the interrupted-insertion acknowledgement defect is tracked separately in #12010 / #12052; it is intentionally excluded here.
   
   Verified at `dev` commit `97d461bc0773399d632fd078735736ecd44f5f0b`:
   
   - `submitJob()` writes `JobInfo` into `runningJobInfoIMap` before queue insertion (`CoordinatorService.java:1374` path), so recoverable job metadata does exist.
   - The queue itself is in-heap: `PeekBlockingQueue.java:48` (`new LinkedBlockingQueue<>()`); `clearCoordinatorService()` (`CoordinatorService.java:1281`) calls `pendingJobQueue.clear()` (`:1311`) on step-down (`:1259`, `:1266`) and shutdown (`:2089`).
   - `restoreAllRunningJobFromMasterNodeSwitch()` (`:989`) iterates `runningJobInfoIMap.entrySet().stream()` with no ordering and rebuilds a `JobMaster` per job (`:1106-1160`). The original enqueue order is not preserved, and sorting by submit time would not reproduce it either because initialization is concurrent.
   
   Out of scope: disk durability or recovery after losing every `IMap` replica.
   
   ## Expected outcome
   
   - Define the FIFO/fairness contract that `WAIT` promises across a master failover.
   - Persist an enqueue sequence with the job metadata and re-queue in that order on restore.
   - Coordinate with the admission-contract work so restore does not eagerly re-plan every queued job.
   - Test: queue 50 jobs in `WAIT`, kill the active master, assert the same relative order after restore.
   


-- 
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: commits-unsubscribe@seatunnel.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Improve][Zeta] Preserve pending-queue order across master failover [seatunnel]

Posted by "jjj-n (via GitHub)" <gi...@apache.org>.
jjj-n commented on issue #12120:
URL: https://github.com/apache/seatunnel/issues/12120#issuecomment-5581474940

   I'd like to take this issue. I have a local implementation that persists enqueue sequences and restores the WAIT queue in order, with tests covering 50 queued jobs across two master failovers. I'm preparing a PR and would welcome feedback on the ordering contract.
   


-- 
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: commits-unsubscribe@seatunnel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Improve][Zeta] Preserve pending-queue order across master failover [seatunnel]

Posted by "DanielLeens (via GitHub)" <gi...@apache.org>.
DanielLeens commented on issue #12120:
URL: https://github.com/apache/seatunnel/issues/12120#issuecomment-5679936599

   The active implementation is already PR #12201 from @jjj-n, so there is no need for a parallel branch. I checked current dev, the recent failover history, and the open PR: current dev has no merged enqueue-sequence implementation, while #12201 carries the proposed replicated sequence, ordered restore, lazy waiting-job initialization, legacy metadata compatibility cases, and the requested two-failover queue-order coverage.
   
   Please link that PR to this issue and keep further work there. It has not completed a Build check and its merge state is blocked, so neither the FIFO contract nor the serialization extension is accepted yet. Review must specifically establish old-metadata recovery, rolling-master behavior, cancellation during lazy initialization, failover epochs, and preservation of existing WAIT admission semantics before this issue can move toward closure.


-- 
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: commits-unsubscribe@seatunnel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org