You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@spark.apache.org by do...@apache.org on 2022/01/14 17:23:14 UTC
[spark] branch master updated: [SPARK-37372][K8S] Removing redundant label addition
This is an automated email from the ASF dual-hosted git repository.
dongjoon pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/spark.git
The following commit(s) were added to refs/heads/master by this push:
new 6f908de [SPARK-37372][K8S] Removing redundant label addition
6f908de is described below
commit 6f908de99b8f486996d77f0dfab6ba0577ea93ba
Author: Yikun Jiang <yi...@gmail.com>
AuthorDate: Fri Jan 14 09:21:24 2022 -0800
[SPARK-37372][K8S] Removing redundant label addition
### What changes were proposed in this pull request?
Remove redundant Pod label addtions in driver and executor.
### Why are the changes needed?
These labels are already included by conf.labels as preset labels, we don't need do a extra addition.
### Does this PR introduce _any_ user-facing change?
NO
### How was this patch tested?
UT passed:
Especially:
https://github.com/apache/spark/blob/a3886ba976469bef0dfafc3da8686a53c5a59d95/resource-managers/kubernetes/core/src/test/scala/org/apache/spark/deploy/k8s/KubernetesConfSuite.scala#L157-L164
Closes #34646 from Yikun/SPARK-labels-improve.
Authored-by: Yikun Jiang <yi...@gmail.com>
Signed-off-by: Dongjoon Hyun <do...@apache.org>
---
.../apache/spark/deploy/k8s/features/BasicDriverFeatureStep.scala | 1 -
.../apache/spark/deploy/k8s/features/BasicExecutorFeatureStep.scala | 5 -----
2 files changed, 6 deletions(-)
diff --git a/resource-managers/kubernetes/core/src/main/scala/org/apache/spark/deploy/k8s/features/BasicDriverFeatureStep.scala b/resource-managers/kubernetes/core/src/main/scala/org/apache/spark/deploy/k8s/features/BasicDriverFeatureStep.scala
index 49681dc..925f9dc 100644
--- a/resource-managers/kubernetes/core/src/main/scala/org/apache/spark/deploy/k8s/features/BasicDriverFeatureStep.scala
+++ b/resource-managers/kubernetes/core/src/main/scala/org/apache/spark/deploy/k8s/features/BasicDriverFeatureStep.scala
@@ -142,7 +142,6 @@ private[spark] class BasicDriverFeatureStep(conf: KubernetesDriverConf)
.editOrNewMetadata()
.withName(driverPodName)
.addToLabels(conf.labels.asJava)
- .addToLabels(SPARK_APP_NAME_LABEL, KubernetesConf.getAppNameLabel(conf.appName))
.addToAnnotations(conf.annotations.asJava)
.endMetadata()
.editOrNewSpec()
diff --git a/resource-managers/kubernetes/core/src/main/scala/org/apache/spark/deploy/k8s/features/BasicExecutorFeatureStep.scala b/resource-managers/kubernetes/core/src/main/scala/org/apache/spark/deploy/k8s/features/BasicExecutorFeatureStep.scala
index 3f0a21e..6a339ef 100644
--- a/resource-managers/kubernetes/core/src/main/scala/org/apache/spark/deploy/k8s/features/BasicExecutorFeatureStep.scala
+++ b/resource-managers/kubernetes/core/src/main/scala/org/apache/spark/deploy/k8s/features/BasicExecutorFeatureStep.scala
@@ -276,11 +276,6 @@ private[spark] class BasicExecutorFeatureStep(
.editOrNewMetadata()
.withName(name)
.addToLabels(kubernetesConf.labels.asJava)
- .addToLabels(SPARK_RESOURCE_PROFILE_ID_LABEL, resourceProfile.id.toString)
- .addToLabels(
- SPARK_APP_NAME_LABEL,
- KubernetesConf.getAppNameLabel(kubernetesConf.appName)
- )
.addToAnnotations(kubernetesConf.annotations.asJava)
.addToOwnerReferences(ownerReference.toSeq: _*)
.endMetadata()
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@spark.apache.org
For additional commands, e-mail: commits-help@spark.apache.org