You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by "mridulm (via GitHub)" <gi...@apache.org> on 2023/06/24 15:27:20 UTC
[GitHub] [spark] mridulm commented on a diff in pull request #41709: [SPARK-44153][CORE][UI] Support `Heap Histogram` column in `Executors` tab
mridulm commented on code in PR #41709:
URL: https://github.com/apache/spark/pull/41709#discussion_r1240849467
##########
core/src/main/scala/org/apache/spark/util/Utils.scala:
##########
@@ -2287,6 +2287,22 @@ private[spark] object Utils extends Logging with SparkClassUtils {
}.map(threadInfoToThreadStackTrace)
}
+ /** Return a heap dump. Used to capture dumps for the web UI */
+ def getHeapHistogram(): Array[String] = {
+ val pid = String.valueOf(ProcessHandle.current().pid())
+ val builder = new ProcessBuilder("jmap", "-histo:live", pid)
Review Comment:
@dongjoon-hyun This is an issue - we should use `$JAVA_HOME/bin/jmap`, not the first `jmap` which happens to be in the `PATH`. It is common to override `JAVA_HOME` to specify the java version to be used explicitly (or even to not have jdk in the PATH at all).
--
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: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org