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

Fix inconsistent spark driver and executor image #3996

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions paasta_tools/tron_tools.py
Original file line number Diff line number Diff line change
Expand Up @@ -348,8 +348,6 @@ def build_spark_config(self) -> Dict[str, str]:
f"tron_spark_{self.get_service()}_{self.get_instance()}",
)

docker_img_url = self.get_docker_url(system_paasta_config)

spark_conf_builder = SparkConfBuilder(is_driver_on_k8s_tron=True)
spark_conf = spark_conf_builder.get_spark_conf(
cluster_manager="kubernetes",
Expand All @@ -359,7 +357,7 @@ def build_spark_config(self) -> Dict[str, str]:
paasta_pool=self.get_spark_executor_pool(),
paasta_service=self.get_service(),
paasta_instance=self.get_instance(),
docker_img=docker_img_url,
docker_img="$PAASTA_DOCKER_IMAGE",
chi-yelp marked this conversation as resolved.
Show resolved Hide resolved
extra_volumes=self.get_volumes(
system_paasta_config.get_volumes(),
uses_bulkdata_default=system_paasta_config.get_uses_bulkdata_default(),
Expand Down
2 changes: 1 addition & 1 deletion tests/test_tron_tools.py
Original file line number Diff line number Diff line change
Expand Up @@ -1322,7 +1322,7 @@ def test_format_tron_action_dict_spark(
"--conf spark.executorEnv.PAASTA_INSTANCE_TYPE=spark "
"--conf spark.executorEnv.SPARK_EXECUTOR_DIRS=/tmp "
"--conf spark.kubernetes.pyspark.pythonVersion=3 "
"--conf spark.kubernetes.container.image=docker-registry.com:400/my_service:paasta-123abcde "
"--conf spark.kubernetes.container.image=$PAASTA_DOCKER_IMAGE "
"--conf spark.kubernetes.namespace=paasta-spark "
"--conf spark.kubernetes.executor.label.yelp.com/paasta_service=my_service "
"--conf spark.kubernetes.executor.label.yelp.com/paasta_instance=my_job.do_something "
Expand Down