diff options
author | CodingCat <zhunansjtu@gmail.com> | 2014-04-18 10:05:00 -0700 |
---|---|---|
committer | Reynold Xin <rxin@apache.org> | 2014-04-18 10:05:11 -0700 |
commit | 171cea8eadbce71e438ffee9b49dd6cece4a4e3f (patch) | |
tree | 6ce3f6cea72008209616fd70a8a292fddbdaa4bd /core | |
parent | 1a304297f6490653a8e0ef556222640a57b09202 (diff) | |
download | spark-171cea8eadbce71e438ffee9b49dd6cece4a4e3f.tar.gz spark-171cea8eadbce71e438ffee9b49dd6cece4a4e3f.tar.bz2 spark-171cea8eadbce71e438ffee9b49dd6cece4a4e3f.zip |
SPARK-1523: improve the readability of code in AkkaUtil
Actually it is separated from https://github.com/apache/spark/pull/85 as suggested by @rxin
compare
https://github.com/apache/spark/blob/master/core/src/main/scala/org/apache/spark/util/AkkaUtils.scala#L122
and
https://github.com/apache/spark/blob/master/core/src/main/scala/org/apache/spark/util/AkkaUtils.scala#L117
the first one use get and then toLong, the second one getLong....better to make them consistent
very very small fix........
Author: CodingCat <zhunansjtu@gmail.com>
Closes #434 from CodingCat/SPARK-1523 and squashes the following commits:
0e86f3f [CodingCat] improve the readability of code in AkkaUtil
(cherry picked from commit 3c7a9bae965bac68aba66e8ea28bb4d750e66baa)
Signed-off-by: Reynold Xin <rxin@apache.org>
Diffstat (limited to 'core')
-rw-r--r-- | core/src/main/scala/org/apache/spark/util/AkkaUtils.scala | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/core/src/main/scala/org/apache/spark/util/AkkaUtils.scala b/core/src/main/scala/org/apache/spark/util/AkkaUtils.scala index d0ff17db63..8afe09a117 100644 --- a/core/src/main/scala/org/apache/spark/util/AkkaUtils.scala +++ b/core/src/main/scala/org/apache/spark/util/AkkaUtils.scala @@ -119,7 +119,7 @@ private[spark] object AkkaUtils extends Logging { /** Returns the default Spark timeout to use for Akka remote actor lookup. */ def lookupTimeout(conf: SparkConf): FiniteDuration = { - Duration.create(conf.get("spark.akka.lookupTimeout", "30").toLong, "seconds") + Duration.create(conf.getLong("spark.akka.lookupTimeout", 30), "seconds") } /** Returns the configured max frame size for Akka messages in bytes. */ |