Skip to content
This repository has been archived by the owner on Jan 9, 2020. It is now read-only.

Commit

Permalink
Removed unused parameter in parsePrefixedKeyValuePairs
Browse files Browse the repository at this point in the history
  • Loading branch information
liyinan926 committed Nov 22, 2017
1 parent b75b413 commit 3b587b4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,11 @@ private[spark] object ConfigurationUtils {
*
* @param sparkConf Spark configuration
* @param prefix the given property name prefix
* @param configType a descriptive note on the type of entities of interest
* @return a Map storing the configuration property keys and values
*/
def parsePrefixedKeyValuePairs(
sparkConf: SparkConf,
prefix: String,
configType: String): Map[String, String] = {
prefix: String): Map[String, String] = {
sparkConf.getAllWithPrefix(prefix).toMap
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,7 @@ private[spark] class ExecutorPodFactoryImpl(sparkConf: SparkConf)

private val executorLabels = ConfigurationUtils.parsePrefixedKeyValuePairs(
sparkConf,
KUBERNETES_EXECUTOR_LABEL_PREFIX,
"executor label")
KUBERNETES_EXECUTOR_LABEL_PREFIX)
require(
!executorLabels.contains(SPARK_APP_ID_LABEL),
s"Custom executor labels cannot contain $SPARK_APP_ID_LABEL as it is reserved for Spark.")
Expand All @@ -69,13 +68,11 @@ private[spark] class ExecutorPodFactoryImpl(sparkConf: SparkConf)
private val executorAnnotations =
ConfigurationUtils.parsePrefixedKeyValuePairs(
sparkConf,
KUBERNETES_EXECUTOR_ANNOTATION_PREFIX,
"executor annotation")
KUBERNETES_EXECUTOR_ANNOTATION_PREFIX)
private val nodeSelector =
ConfigurationUtils.parsePrefixedKeyValuePairs(
sparkConf,
KUBERNETES_NODE_SELECTOR_PREFIX,
"node selector")
KUBERNETES_NODE_SELECTOR_PREFIX)

private val executorDockerImage = sparkConf.get(EXECUTOR_DOCKER_IMAGE)
private val dockerImagePullPolicy = sparkConf.get(DOCKER_IMAGE_PULL_POLICY)
Expand Down

0 comments on commit 3b587b4

Please sign in to comment.