-
Notifications
You must be signed in to change notification settings - Fork 374
[AMORO-4037] Add support for dynamic refresh interval for table metadata refreshing in TableRuntimeRefreshExecutor #4038
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
base: master
Are you sure you want to change the base?
Conversation
60e829e to
298152d
Compare
|
@zhoujinsong @turboFei @xxubai Could you help me review it when you are free? Thanks! |
298152d to
4fec76a
Compare
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.
Pull request overview
This PR implements a dynamic refresh interval feature for table metadata refreshing in TableRuntimeRefreshExecutor. The feature uses an AIMD (Additive Increase Multiplicative Decrease) algorithm to adjust refresh intervals based on whether tables need optimization, helping to reduce resource consumption for healthy tables while maintaining responsiveness for tables requiring optimization.
Changes:
- Added configuration properties for adaptive refresh intervals with configurable maximum interval and increase step
- Implemented adaptive interval calculation logic that increases intervals for healthy tables and decreases them for tables needing optimization
- Added comprehensive test coverage for the adaptive interval functionality
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| docs/user-guides/configurations.md | Added documentation for three new configuration properties related to adaptive refresh intervals |
| amoro-format-iceberg/src/main/java/org/apache/amoro/table/TableProperties.java | Defined constants for adaptive refresh table properties and their default values |
| amoro-common/src/main/java/org/apache/amoro/config/OptimizingConfig.java | Added fields, getters, setters, and updated equals/hashCode/toString methods for adaptive refresh configuration |
| amoro-ams/src/main/java/org/apache/amoro/server/table/TableConfigurations.java | Integrated parsing of adaptive refresh properties from table properties into OptimizingConfig |
| amoro-ams/src/main/java/org/apache/amoro/server/table/DefaultTableRuntime.java | Added fields and methods to track latest refresh interval and optimization evaluation status |
| amoro-ams/src/main/java/org/apache/amoro/server/scheduler/inline/TableRuntimeRefreshExecutor.java | Implemented core adaptive interval logic with AIMD algorithm and updated execute method to apply adaptive intervals |
| amoro-ams/src/test/java/org/apache/amoro/server/scheduler/inline/TestTableRuntimeRefreshExecutor.java | Added comprehensive test cases covering various adaptive interval scenarios including boundary conditions |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
…g in the TableRuntimeRefreshExecutor.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
c83edf5 to
16b59c2
Compare
Why are the changes needed?
Close #4037.
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