Josh Rosen created SPARK-39636:
----------------------------------

             Summary: Fix multiple small bugs in JsonProtocol, impacting 
StorageLevel and Task/Executor resource requests
                 Key: SPARK-39636
                 URL: https://issues.apache.org/jira/browse/SPARK-39636
             Project: Spark
          Issue Type: Improvement
          Components: Spark Core, Web UI
    Affects Versions: 1.0.0
            Reporter: Josh Rosen
            Assignee: Josh Rosen


While working on SPARK-39489, I spotted three pre-existing bugs in JsonProtocol:
 * {{TaskResourceRequest}} loses precision for values < 0.5. The {{amount}} is 
a floating point number which is either between 0 and 0.5 or is a positive 
integer, but the read path assumes it is an integer.
 * {{ExecutorResourceRequest}} integer overflows for values larger than an 
integer because the write path writes longs but the read path assumes integers.
 * The {{OFF_HEAP}} storage level is not handled properly: the {{offHeap}} 
field isn't included in the JSON, so this StorageLevel cannot be round-tripped 
through JSON. This could cause the History Server to display inaccurate "off 
heap memory used" stats on the executors page.

I'm submitting a separate PR to fix those issues.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

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

Reply via email to