hesam-oxe commented on PR #11077:
URL: https://github.com/apache/seatunnel/pull/11077#issuecomment-5652548846

   F1–F8 status on the new head `a9d8464`, as requested — one item needed code, 
one needed docs, the rest were already addressed on earlier heads:
   
   - **F1 (destination-key collisions)** — sharing stays strictly opt-in: 
`DestinationKey` = connector class + connector-provided identifier + replica 
index, and sinks that do not opt in remain isolated by sink-instance identity 
(`testSamePhysicalIdentifierDoesNotShareAcrossConnectorClasses` pins the 
cross-connector case). The missing "validated" half is F3, now implemented 
below.
   - **F2 (state fan-out / restore-time union)** — the snapshot path persists 
under one canonical identifier and `getRestoredState()` merges legacy per-alias 
checkpoints; both directions are covered by 
`testSharedWriterRoundTripRestoresOneCanonicalState` and 
`testRestoreMergesStateFromAllAliasedTables` (verified by @DanielLeens on 
`153355ce8c`).
   - **F3 (schema/config divergence)** — **implemented in `a9d8464`**: 
`MultiTableSink` now validates at construction that every sink resolving to the 
same physical destination declares an equal `CatalogTable` write schema, and 
fails fast with an error naming both table paths, the shared destination 
identifier and the connector class. Sinks exposing no catalog table cannot be 
validated and are trusted (spelled out in the javadoc). Tests: 
`testSharedDestinationWithDivergentSchemasFailsFast`, 
`testSharedDestinationWithCompatibleSchemasSharesOneWriter`.
   - **F4/F6 (docs)** — `SeaTunnelSink#getPhysicalDestinationIdentifier()` now 
documents that the coordinator validates schema compatibility at construction 
and that a shared writer receives the merged state of all aliases in a single 
call; `SeaTunnelSink#restoreWriter(...)` gained its missing contract javadoc 
(states may combine entries from several aliased tables, exactly like a 
parallelism rescale).
   - **F5 (proxyContexts / containsValue)** — every alias retains its proxy 
(`proxyContexts.put` per identifier on both the create and restore paths), and 
the O(n) `containsValue` walk is gone (keyed lookups via `groupByIdentity` + 
`proxyContexts.get`).
   - **F7 (IOException inside computeIfAbsent)** — writer creation happens 
outside `computeIfAbsent`; only the proxy construction (which cannot throw) 
remains inside.
   - **F8 (getDestinationKey Javadoc)** — `@param`/`@return` tags are present.
   
   All 407 seatunnel-api tests pass locally on this head. Happy to adjust any 
of the choices above — in particular whether non-catalog-table sinks should be 
trusted or rejected.
   
   P.S. @davidzollo — no pressure and purely for the record: whenever 
convenient, a one-liner on where the two "[Chore] Retrigger CI" commits of 
2026-09-07 originated would close the last open loop from earlier in this 
thread. Either way, thank you for keeping CI moving on this branch.


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