stevenzwu opened a new pull request, #4580:
URL: https://github.com/apache/iceberg/pull/4580

   During review of Flink FLIP-27 source PR #4329 , we agreed that the 
streaming start strategy should be inclusive. Hence we would need the 
`TableScan#appendsBetween` to support nullable `fromSnapshotId`. Right now, 
`fromSnapshotId` is a primitive type of `long`.
   https://github.com/apache/iceberg/pull/4329#discussion_r834877847
   
   Initially, @rdblue and I were thinking just add a new overload method 
`appendsBetween` with a `Long fromSnapshotId`. That would cause compiling error 
due to ambiguity of type resolution. As we want to maintain binary backward 
compatibility, I tried to add a new method name `appendsInRange` in PR #4529 , 
which is not as an intuitive name as `appendsBetween`.
   
   This is a different direction with PR #4529 that is suggested by @rdblue. 
Instead of modifying `TableScan` interface, maybe we can consider introduce a 
new `IncrementalTableScan` interface and `Table#newIncrementalScan` method.
   
   - We can decouple regular `TableScan` and `IncrementalTableScan`. This also 
help avoids the need of `UnsupportedOperationException` for some `TableScan` 
methods
   - We may have more complex incremental scan in the future like the CDC data 
that can be added to the new `IncrementalTableScan` API
   
   To avoid code duplication, a new interface of `Scan<T extends Scan` was 
extracted as the super interface for current `TableScan` and the new 
`IncrementalTableScan`. I ran `japi-compliance-checker` too check binary 
compatibility after the interface refactoring. Will attach the result
      


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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to