Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Extract JFR information from Linux Command Line #592

Open
tricnex opened this issue Jul 28, 2024 · 2 comments
Open

Extract JFR information from Linux Command Line #592

tricnex opened this issue Jul 28, 2024 · 2 comments

Comments

@tricnex
Copy link

tricnex commented Jul 28, 2024

Hello,
First of all, thanks to all the developers who continue to keep this project alive. I would like to ask if there is a way to extract information from a JFR file via the command line. My JFR file is generated automatically during the execution of software I wrote. Through the GUI on the Sampler Tab, I can see all the processes that have been executed, along with their respective functions, execution times, and CPU usage. Is it possible to get the same information in a text file extracted via the command line?
I need to extract this information dynamically during the mass execution of my software to check if execution times and resource usage remain consistent. Thank you very much for your support.
Marco

@thurka
Copy link
Member

thurka commented Jul 29, 2024

I guess you can try to use JDK command line utility jfr. https://docs.oracle.com/en/java/javase/21/docs/specs/man/jfr.html

@tricnex
Copy link
Author

tricnex commented Jul 30, 2024

Hi Thurka,
Thank you for your response.

I used the jfr command to first extract the summary of events and then for each event, the related stack trace. I was able to identify what I was looking for, but my problem remains as I don't have a correlation with the CPU time used. Below, I will provide the output from the jfr command with the related stack trace and the output from the VisualVM software with the specific information I am looking for.

Is there a way to extract the information directly from the VisualVM software? If the information is already displayed in the GUI, can it also be estracted via CLI?
Output from JFR Command
VisualVm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants