-
Notifications
You must be signed in to change notification settings - Fork 289
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
[AMORO-3317]: Move optimizing planer and scan to iceberg/mixed-format module #3314
[AMORO-3317]: Move optimizing planer and scan to iceberg/mixed-format module #3314
Conversation
611c39a
to
4499ec1
Compare
83fe53e
to
097e958
Compare
# Conflicts: # amoro-ams/src/main/java/org/apache/amoro/server/optimizing/OptimizingProcessMeta.java # amoro-ams/src/main/java/org/apache/amoro/server/persistence/TableRuntimeMeta.java # amoro-ams/src/test/java/org/apache/amoro/server/optimizing/BaseOptimizingChecker.java
…r' into remove-table-runtime-from-planner
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.
@baiyangtx Thanks for the contribution!
It is very important to the new process API feature.
The PR look good to me in general, I left some minor suggestion, PTAL.
long lastMinor = tableRuntime.getLastMinorOptimizingTime(); | ||
long lastFull = tableRuntime.getLastFullOptimizingTime(); | ||
TableSnapshot snapshot = IcebergTableUtil.getSnapshot(table, tableRuntime); | ||
if (TableFormat.ICEBERG.in(table.format())) { |
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.
if (TableFormat.ICEBERG.in(table.format())) { | |
if (TableFormat.ICEBERG.equals(table.format())) { |
lastMinor, | ||
lastFull); | ||
} | ||
throw new IllegalStateException("Un-supported table-format:" + table.format().toString()); |
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.
throw new IllegalStateException("Un-supported table-format:" + table.format().toString()); | |
throw new IllegalStateException("Unsupported table format:" + table.format().toString()); |
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.
LGTM.
Question: After this refactoring, can Spark customize procedures to trigger optimization? (only depend on the plan and scan logical)
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.
LGTM.
|
Why are the changes needed?
close #3317
Currently, the Optimizing Plan has become a bottleneck of AMS. A feasible solution is to delegate the Optimizing Plan to the Optimizer for execution.
For this, some prerequisite refactoring work is required.
This PR moves the code of the Optimizing Plan from the AMS module to the iceberg/mixed-format module, and the relevant logic can be called by the optimizer in the future.
Brief change log
How was this patch tested?
Add some test cases that check the changes thoroughly including negative and positive cases if possible
Add screenshots for manual tests if appropriate
Run test locally before making a pull request
Documentation