-
Notifications
You must be signed in to change notification settings - Fork 480
Move some timeline fns from Coordinator to Catalog #33335
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
Move some timeline fns from Coordinator to Catalog #33335
Conversation
src/adapter/src/catalog.rs
Outdated
let builtin_table_updates = self.state.apply_updates(updates)?; | ||
Ok(builtin_table_updates) | ||
} | ||
|
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.
Nit: The catalog.rs
file is already very large, so I think it'd make sense to have it split across several files. This seems like an opportunity to do so?
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.
Yeah, I'd say we can create a new module catalog/timeline
and move the methods there. Wdyt?
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!
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.
Btw., I've split off only the newly moved code now, but should I try to split off more stuff into separate files in a follow-up PR? Ideas:
CatalogPlans
and related methods (~200 lines)- expression cache stuff
ExprHumanizer
(~150 lines)ConnCatalog
- ...
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.
Excellent! But would be good to move to a new module as Moritz suggested before merging.
a58c0b8
to
c9660fb
Compare
c9660fb
to
55f756a
Compare
Merging! Can do more |
Works towards the Small Coordinator vision, specifically https://github.com/MaterializeInc/database-issues/issues/9593
These methods don't need to be on
Coordinator
, because they only work with theCatalog
. This PR moves them toCatalog
, making them easier to call outside theCoordinator
.This PR is purely code movement, no behavior change should happen from it.
Motivation
Tips for reviewer
Checklist
$T ⇔ Proto$T
mapping (possibly in a backwards-incompatible way), then it is tagged with aT-proto
label.