Skip to content

Commit 8526cf0

Browse files
authored
Cleanup jupyterhub dra logic and messages (#162)
1 parent c7a50c2 commit 8526cf0

File tree

1 file changed

+1
-11
lines changed

1 file changed

+1
-11
lines changed

service_configuration_lib/spark_config.py

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -487,19 +487,9 @@ def get_dra_configs(self, spark_opts: Dict[str, str]) -> Dict[str, str]:
487487
cached_executor_idle_timeout,
488488
)
489489

490-
# Min executors
490+
# Spark defaults
491491
min_executors = int(spark_opts.get('spark.dynamicAllocation.minExecutors', 0))
492-
493-
# Initial executors for Jupyter
494492
initial_executors = int(spark_opts.get('spark.dynamicAllocation.initialExecutors', min_executors))
495-
if is_jupyterhub and 'spark.dynamicAllocation.initialExecutors' not in spark_opts:
496-
initial_executors = int(spark_opts.get('spark.dynamicAllocation.minExecutors', 0))
497-
spark_opts['spark.dynamicAllocation.initialExecutors'] = str(initial_executors)
498-
log.info(
499-
f'\nSetting {TextColors.yellow("spark.dynamicAllocation.initialExecutors")} as {initial_executors}. '
500-
f'If you wish to change the value of initial executors, please provide the exact value of '
501-
f'spark.dynamicAllocation.initialExecutors in your spark args\n',
502-
)
503493

504494
# Max executors
505495
if 'spark.dynamicAllocation.maxExecutors' not in spark_opts:

0 commit comments

Comments
 (0)