dongjoon-hyun opened a new pull request, #56945:
URL: https://github.com/apache/spark/pull/56945

   ### What changes were proposed in this pull request?
   
   This PR proposes to stop reserving off-heap memory pools 
(`spark.memory.offHeap.size`) in the driver's `MemoryManager` in non-`local` 
deployments. `SparkEnv.initializeMemoryManager` takes a new `offHeapAllowed` 
parameter, and `SparkContext` passes `offHeapAllowed = isLocal` for the driver. 
The executor path and `local` mode are unchanged.
   
   ### Why are the changes needed?
   
   With `spark.memory.offHeap.enabled=true`, the Executors UI and REST API show 
the driver with `spark.memory.offHeap.size` of `Off Heap Storage Memory`, which 
is misleading. The driver in non-local deployments never uses it: it runs no 
tasks, stores no off-heap blocks, and its container memory request does not 
include `spark.memory.offHeap.size` (only executors' do).
   
   ### Does this PR introduce _any_ user-facing change?
   
   Yes. In non-local deployments, the driver now reports 0 off-heap memory in 
the Executors UI and REST API instead of the configured size.
   
   ### How was this patch tested?
   
   Added two test cases to `SparkContextSuite` checking the driver's 
`maxOffHeapStorageMemory` is 0 under `local-cluster[1,1,1024]` and positive 
under `local`.
   
   ### Was this patch authored or co-authored using generative AI tooling?
   
   Generated-by: Claude Fable 5


-- 
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.

To unsubscribe, e-mail: [email protected]

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