-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add API changes for statistics information in table metadata #5021
Conversation
a593574
to
b37e321
Compare
@rdblue thank you for your review. Updated accordingly. |
@@ -216,6 +216,11 @@ public DeleteFiles newDelete() { | |||
throw new UnsupportedOperationException("Cannot delete from a metadata table"); | |||
} | |||
|
|||
@Override | |||
public UpdateTableStatistics updateTableStatistics() { | |||
throw new UnsupportedOperationException("Cannot update statistics of a metadata table"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you add this as a default implementation rather than adding it in this class? That way, if anyone is using the interface it doesn't break them.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, added default method and removed impl stubs from BaseTable and BaseTransaction.
Impl in BaseMetadataTable stays because it includes "a metadata table" in the exc msg (consistently with all other methods in this class).
b37e321
to
74bd319
Compare
Currently, based on #4978 |
9791c86
to
92e88c4
Compare
@rdblue updated this to have one stats file for a table. |
92e88c4
to
f5e3f8f
Compare
f5e3f8f
to
3c1e5c6
Compare
42b0dfa
to
0f451b8
Compare
22d6e91
to
b899566
Compare
b899566
to
07418e2
Compare
07418e2
to
0c9eb05
Compare
Updated to apply #5450 (comment). |
Build failure
looks unrelated. Let me push amended commit to restart the build. |
1bba34e
to
21f012f
Compare
Currently, depends on #5450 |
21f012f
to
20d6c0d
Compare
api/src/main/java/org/apache/iceberg/UpdateTableStatistics.java
Outdated
Show resolved
Hide resolved
3f50ce0
to
1c66ccb
Compare
* | ||
* @return this for method chaining | ||
*/ | ||
UpdateStatistics setStatisticsFile(long snapshotId, @Nullable StatisticsFile statisticsFile); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you remove the @Nullable
annotation?
How about naming this setStatistics
like in TableMetadata.Builder
?
Also, I thought we needed a removeStatistics
method as well?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
@findepi, this is looking close. I think we just need to finalize the |
91d98c6
to
6d5c136
Compare
I have applied the requested changes. @rdblue please take another look |
6d5c136
to
81706c8
Compare
Thank you for the merge! |
API for #4945
Implementation PR: #4741
Extracted from #4741 per #4741 (comment)