Skip to content

Commit

Permalink
Privatize SparkConf.translateConfKey
Browse files Browse the repository at this point in the history
  • Loading branch information
Andrew Or committed Feb 26, 2015
1 parent b38dec2 commit 8fb43e6
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion core/src/main/scala/org/apache/spark/SparkConf.scala
Original file line number Diff line number Diff line change
Expand Up @@ -407,7 +407,7 @@ private[spark] object SparkConf extends Logging {
* @param warn Whether to print a warning if the key is deprecated. Warnings will be printed
* only once for each key.
*/
def translateConfKey(userKey: String, warn: Boolean = false): String = {
private def translateConfKey(userKey: String, warn: Boolean = false): String = {
deprecatedConfigs.get(userKey)
.map { deprecatedKey =>
if (warn) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,8 @@ private[history] class FsHistoryProvider(conf: SparkConf) extends ApplicationHis

// Interval between each check for event log updates
private val UPDATE_INTERVAL_MS = conf.getOption("spark.history.fs.update.interval.seconds")
.orElse(conf.getOption(SparkConf.translateConfKey("spark.history.fs.updateInterval", true)))
.orElse(conf.getOption(SparkConf.translateConfKey("spark.history.updateInterval", true)))
.orElse(conf.getOption("spark.history.fs.updateInterval"))
.orElse(conf.getOption("spark.history.updateInterval"))
.map(_.toInt)
.getOrElse(10) * 1000

Expand Down

0 comments on commit 8fb43e6

Please sign in to comment.