-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Minor: Add `RuntimeEnvBuilder::build_arc() #12213
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
Conversation
.build() | ||
.unwrap(), | ||
); | ||
let runtime = RuntimeEnvBuilder::new() |
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.
this is a pretty good example of how the new API makes the code simpler
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.
I like the simplification.
Is this an established naming pattern in the ecosystem?
I am not aware of this being an established pattern (I think DataFusion uses Arc's a bit more than many Rust purists would prefer) |
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.
👍
I also have the same thought, maybe we don't really need Arc in some cases. We could gradually cleanup them later on |
Which issue does this PR close?
N/A
Rationale for this change
Small follow on to #12157 from @devanbenz
It is still somewhat awkward to make RuntimeEnv's, so let's make it slightly easier
What changes are included in this PR?
Adds a convenience method to
RuntimeEnvBuilder
to build anArc<RuntimeEnv>
Are these changes tested?
Yes, by CI
Are there any user-facing changes?
A new method