DanielLeens commented on issue #12624:
URL: https://github.com/apache/seatunnel/issues/12624#issuecomment-6037523558

   Thanks — the shared-queue finding is a merge blocker, not a follow-up. 
#12625 says it fixes #12624, but a per-`JdbcOutputFormat` marker cannot protect 
the single manual-commit transaction shared by the writers for tables A and B 
on one queue index.
   
   Please move the transaction state to the queue/connection owner in 
`ConnectionPoolManager` (or an equivalent object shared by all writers for that 
queue), and keep it in #12625. It needs to record both the connection identity 
that owns flushed work and whether the checkpoint interval has already lost 
work. A full rollback does end that JDBC transaction, so it may clear the 
*pending-on-that-transaction* fact; however, if it rolls back any flushed work, 
it must also poison the shared checkpoint interval. Otherwise another table can 
flush/commit the same or a replacement connection successfully after table A's 
rows have been discarded.
   
   Please add deterministic coverage with two tables on the same queue index:
   
   1. Table A flushes a manual-commit batch; a full rollback occurs on that 
shared connection; table B's `prepareCommit` and `close` paths must both fail 
rather than commit a partial result.
   2. A dead shared connection is replaced after table A flushes; table B must 
not commit the replacement.
   3. A savepoint rollback still keeps the pre-savepoint transaction state 
visible, while a successful shared commit is the only normal path that clears 
the interval for every writer.
   
   The current `close()` path also calls `connection.commit()` directly rather 
than the new `commitIfNeeded()` guard, so it needs the same protection and a 
regression. Until the queue-scoped state and all commit exits are covered, the 
checkpoint can still report success with rows from another table lost. Please 
keep the PR draft and update the stated known limitation only after this 
invariant is closed.
   


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