Github user pwendell commented on a diff in the pull request:
https://github.com/apache/spark/pull/377#discussion_r11500049
--- Diff: core/src/main/scala/org/apache/spark/util/Utils.scala ---
@@ -1022,4 +1022,13 @@ private[spark] object Utils extends Logging {
def getHadoopFileSystem(path: URI): FileSystem = {
FileSystem.get(path, SparkHadoopUtil.get.newConfiguration())
}
+
+ /**
+ * Determine the system's effective maximum memory after taking into
account
+ * `spark.system.reservedMemorySize`
+ */
+ def effectiveMaxMemory(conf: SparkConf) = {
+ Runtime.getRuntime.maxMemory - (1024 * 1024 *
--- End diff --
Btw here is what it says in the style guide:
```
There are times when a single expression reaches a length where it becomes
unreadable to keep it confined to a single line (usually that length is
anywhere above 80 characters). In such cases, the preferred approach is to
simply split the expression up into multiple expressions by assigning
intermediate results to values.
```
http://docs.scala-lang.org/style/indentation.html#line_wrapping
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---