-
Notifications
You must be signed in to change notification settings - Fork 608
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
refactor(backends): split memtable existence check out #10053
refactor(backends): split memtable existence check out #10053
Conversation
@@ -33,7 +33,6 @@ class Backend(SQLBackend): | |||
name = "druid" | |||
compiler = sc.druid.compiler | |||
supports_create_or_replace = False | |||
supports_in_memory_tables = True |
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.
The default value of this flag is True
, hence the removal in a few places.
@@ -253,50 +253,47 @@ def _register_in_memory_table(self, op: ops.InMemoryTable) -> None: | |||
f"got null typed columns: {null_columns}" | |||
) | |||
|
|||
# only register if we haven't already done so | |||
if (name := op.name) not in self.list_tables(): |
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.
The only bits I changed here were to remove this conditional, and then dedent what was previously indented inside the branch.
63fe2b9
to
31372ea
Compare
31372ea
to
33bdc39
Compare
I'll split out the perf improvements to a separate PR. |
d05de5e
to
1b5dbb4
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.
LGTM (besides the method name).
c342081
to
9935cb9
Compare
…mization over time
e3341ae
to
1fa978c
Compare
First of
twoa few PRs to implement #10044. This one factors out memtable existence checks to allow a generic implementation of register-only-if-not-exists, as well as to allow improvement over time of this check as we discover faster existence check implementations.