warrenzhu25 commented on a change in pull request #28972:
URL: https://github.com/apache/spark/pull/28972#discussion_r450337248



##########
File path: 
core/src/main/scala/org/apache/spark/resource/ExecutorResourceRequests.scala
##########
@@ -54,6 +54,19 @@ class ExecutorResourceRequests() extends Serializable {
     this
   }
 
+  /**
+   * Specify off heap memory. The value specified will be converted to MiB.

Review comment:
       I have this line of code to only set offHeapMemory when 
`spark.memory.offHeap.enabled` is `true`:
   ```
       if (conf.get(MEMORY_OFFHEAP_ENABLED)) {
         // Explicitly add suffix b as default unit of offHeapMemory is Mib
         ereqs.offHeapMemory(conf.get(MEMORY_OFFHEAP_SIZE).toString + "b")
       }
   ```
   Is this enough? if its disabled, the method won't be called, the default 
value should be 0.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to