mrob95 commented on code in PR #2812:
URL: https://github.com/apache/arrow-datafusion/pull/2812#discussion_r912168516
##########
datafusion/core/src/execution/context.rs:
##########
@@ -1041,6 +1041,22 @@ impl SessionConfig {
Default::default()
}
+ /// Create an execution config with config options read from the
environment
+ pub fn from_env() -> Self {
+ Self {
+ target_partitions: num_cpus::get(),
+ default_catalog: DEFAULT_CATALOG.to_owned(),
+ default_schema: DEFAULT_SCHEMA.to_owned(),
+ create_default_catalog_and_schema: true,
+ information_schema: false,
+ repartition_joins: true,
+ repartition_aggregations: true,
+ repartition_windows: true,
+ parquet_pruning: true,
+ config_options: ConfigOptions::from_env(),
+ }
Review Comment:
Ah yeah I meant to mention the copy-paste in the PR. The thinking behind
leaving it this way was that most of these options will (I presume) go away
soon as part of #2756. Your suggestion is cleaner though and building the hash
table twice isn't a big deal 👍
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]