Skip to content
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

Reorganize linkable spec modules #1143

Merged
merged 3 commits into from
Apr 23, 2024
Merged

Conversation

tlento
Copy link
Contributor

@tlento tlento commented Apr 23, 2024

As of this moment the LinkableSpecResolver drives our group by resolution, and
the LinkableElementSet is the least objectionable way to move group by
resolution information across the boundary between the resolver and the
DataflowPlanBuilder. Doing so will eventually require us to be able to operate
on LinkableSpecs and LinkableElements in interchangeable ways.

This PR breaks up the cumbersome linkable_spec_resolver module into components
consisting of a type specification module (which also subsumes the separate
module for LinkableElementProperties), a module for the LinkableElementSet,
and the original module which still contains the resolver itself. This makes
it possible to unify LinkableElements and ElementPathKeys with LinkableSpecs
in a step-wise manner without introducing circular dependencies.

@cla-bot cla-bot bot added the cla:yes label Apr 23, 2024
Copy link
Contributor Author

tlento commented Apr 23, 2024

tlento added 3 commits April 23, 2024 12:16
The linkable_spec_resolver module is quite unwieldy with all of
these type-spec dataclasses inlined with the resolver itself.

Historically, this made sense, because these classes were generally
not used outside of contexts where we'd need the resolver itself.
However, predicate pushdown will change this calculus, as the
classes in the new linkable_elements module are the least objectionable
way of propagating resolution-time metadata into the DataflowPlanBuilder.
Splitting these out proactively helps us avoid inevitable circular
dependencies in the runtime components when we start moving the
metadata these classes represent across that boundary.
Now that we have a module for enumerations and dataclass type
definitions we might as well consolidate.
This is now being returned through methods in the MetricLookup,
which means it can be used independently of the LinkableSpecResolver.

As such it merits its own module. This will also be useful for the
short term need to access this class in the predicate pushdown
implementation, and longer term might make it easier to consolidate
this class with the LinkableSpecSet.
@tlento tlento force-pushed the reorganize-linkable-spec-modules branch from 0ba2a01 to aaca4b7 Compare April 23, 2024 19:19
@tlento tlento merged commit d4a475f into main Apr 23, 2024
19 checks passed
@tlento tlento deleted the reorganize-linkable-spec-modules branch April 23, 2024 21:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants