Commit f8b5eaf
committed
[SPARK-19824][Core] Standalone master JSON not showing cores for running applications
This fix tries to address the issue raised in SPARK-19824 where the
JSON API of the standalone master ("/json") does not show the number of
cores for a running (active) application, which is available on the
master UI.
The reason was that in master UI, `coresGranted` was used:
https://github.com/apache/spark/blob/v2.1.0/core/src/main/scala/org/apache/spark/deploy/master/ui/MasterPage.scala#L220
while in JSON API, the `desc.maxCores` was used. In case there is no limit on
`maxCores`, this filed will be missing on JSON API. (Master UI show cores granted
so the field is always available).
This fix address the discrepancy by changing JSON API to use `coredGranted`
so that UI and JSON API are consistent.
Signed-off-by: Yong Tang <[email protected]>1 parent 207067e commit f8b5eaf
File tree
1 file changed
+1
-1
lines changed- core/src/main/scala/org/apache/spark/deploy
1 file changed
+1
-1
lines changedLines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
44 | 44 | | |
45 | 45 | | |
46 | 46 | | |
47 | | - | |
| 47 | + | |
48 | 48 | | |
49 | 49 | | |
50 | 50 | | |
| |||
0 commit comments