wwj6591812 commented on code in PR #8117:
URL: https://github.com/apache/paimon/pull/8117#discussion_r3504138536
##########
paimon-core/src/main/java/org/apache/paimon/table/source/AbstractDataTableScan.java:
##########
@@ -119,10 +120,48 @@ public InnerTableScan withFilter(Predicate predicate) {
@Override
public AbstractDataTableScan withBucket(int bucket) {
+ validateScanBucketOption(schema, options, bucket);
Review Comment:
Thanks for the review, @JingsongLi.
You're right — putting validation on the generic withBucket(int) path was
too restrictive for the existing public read API. I've moved the PK /
fixed-bucket checks back to the CoreOptions.SCAN_BUCKET auto-application path
only: AbstractFileStoreTable.newScan() / newStreamScan() now validate before
calling withBucket(), while AbstractDataTableScan.withBucket() again delegates
directly to the snapshot reader. I also added a regression test to confirm
fixed-bucket append tables can still use withBucket via both newScan() and
ReadBuilder.
Please take another look when you have a chance.
--
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]