SEZ9 commented on PR #13041:
URL: https://github.com/apache/seatunnel/pull/13041#issuecomment-7024315037
Thanks @nzw921rx for the careful comparison of `34dfad39` against `89f91a89`
and for the reproductions. I agree these need to be fixed before this can move
forward. The earlier pass on the snapshot lifetime did not cover plugin key
selection or the cross-member reload case, so these are new gaps rather than a
repeat of the earlier blocker.
**1. [P1] `loadAllKeys()` semantics**
`FileMapStore.loadAllKeys()` has to keep honoring what
`IMapStorage.loadAllKeys()` returns. Deriving the keys from
`loadAllWithExpirationTime()` during initial loading changes which keys get
preloaded for any plugin that returns a subset, an empty set, or `null`.
Because the coordinator scans `engine_runningJobInfo` for jobs to restore
during Master failover, a record the plugin deliberately excluded can become a
recovery candidate, which is a correctness problem.
Remaining asks:
- Restore delegation to `IMapStorage.loadAllKeys()` for existing storage
plugins.
- Share the scan only for the built-in file store, where it can guarantee
that both methods select the same keys.
- Add a test with two live WAL entries covering the three cases in the table
(`{1}`, empty set, `null`), asserting the same loaded keys as the baseline.
**2. [P2] First explicit reload missing a key persisted by another member**
Once EAGER initialization has finished and `getMap()` has returned,
`map.loadAll(true)` should read fresh storage on the first call. In the
reproduction it returns `null` while the completion watcher on the enumerating
member is delayed, so releasing the snapshot currently depends on watcher
timing.
Remaining asks:
- Make the end of snapshot sharing independent of the watcher's timing, so
an explicit reload never serves the initial snapshot.
- Add a two-member test following the three reproduction steps (delay the
watcher, write and evict a key owned by the other member, one `loadAll(true)`),
asserting the persisted value is returned on the first reload.
**3. Third regression**
The review reports three regressions and I have only covered the first two
here. Please address the third one as well and reply to each item separately,
describing what changed and which test covers it.
<!-- streview-comment:2461 -->
--
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]