How to get Java profiling dump for creating flame graphs on the mac?

前端 未结 4 1487
一个人的身影
一个人的身影 2021-02-04 15:45

I\'d like to collect stacktraces from my Java app for creating CPU Flame Graphs for profiling.

This is very similar to this question: How to get complete stack dump from

4条回答
  •  遥遥无期
    2021-02-04 16:29

    Try this: https://github.com/saquibkhan/javaFlameGraph

    Installation

    npm install javaflamegraph

    Usage

    1. cd javaflamegraph
    2. npm start - This will wait till it detects a process with name 'Java'. Can be best best used to start profiling at program startup.
    3. npm run start - This will start profiling for the given process id. e.g. npm run start 1234

提交回复
热议问题