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

Add a histogram panel to show the GC pause time distribution #43

Open
ryangardner opened this issue Nov 2, 2012 · 10 comments
Open

Add a histogram panel to show the GC pause time distribution #43

ryangardner opened this issue Nov 2, 2012 · 10 comments

Comments

@ryangardner
Copy link
Contributor

Having a histogram would be very helpful.

I hacked together something quickly using JFreeChart to do this - but someone who is better with Swing could likely do it much better.

JFreeChart makes it easy to do the histogram part - you could also have it have different colors for the different kind of pause events.

https://github.com/ryangardner/GCViewer/commit/1926f74d65aa1004bce40c9441db90ce894b7f74

@ryangardner
Copy link
Contributor Author

If you have suggestions for how to do things better, I can try my hand at cleaning up the hack I put in place to do it - but having the distribution of pause times displayed visually alongside the other visualization really helps me see at a glance what's going on.

@rupeshr-zz
Copy link
Contributor

Have you looked at GCHisto?
http://java.net/projects/gchisto

  • Rupesh

On Nov 1, 2012, at 7:49 PM, Ryan Gardner notifications@github.com wrote:

If you have suggestions for how to do things better, I can try my hand at cleaning up the hack I put in place to do it - but having the distribution of pause times displayed visually alongside the other visualization really helps me see at a glance what's going on.


Reply to this email directly or view it on GitHub.

@ryangardner
Copy link
Contributor Author

I've seen gchist, yes. Afaik it isn't being maintained anymore so it can't
parse modern gc log files

Adding a jfreechart-based histogram to gcviewer is almost trivial to do and.

(If you aren't interested in putting it in the main gcviewer that's fine,
I'll just keep it on my github fork.)
On Nov 2, 2012 6:37 PM, "Rupesh Ramachandran" notifications@github.com
wrote:

Have you looked at GCHisto?
http://java.net/projects/gchisto

  • Rupesh

On Nov 1, 2012, at 7:49 PM, Ryan Gardner notifications@github.com
wrote:

If you have suggestions for how to do things better, I can try my hand
at cleaning up the hack I put in place to do it - but having the
distribution of pause times displayed visually alongside the other
visualization really helps me see at a glance what's going on.


Reply to this email directly or view it on GitHub.


Reply to this email directly or view it on GitHubhttps://github.com//issues/43#issuecomment-10032496.

@rupeshr-zz
Copy link
Contributor

I meant look at GCHisto in terms of requirements. I think it's a great idea to add a histogram feature and make GCviewer more comprehensive.

If JFreeChart does the job and is easy to maintain, I don't see why it's a problem. However, I'm not a GUI expert and will let the experts chime in.

-Rupesh

On Nov 2, 2012, at 3:57 PM, Ryan Gardner notifications@github.com wrote:

I've seen gchist, yes. Afaik it isn't being maintained anymore so it can't
parse modern gc log files

Adding a jfreechart-based histogram to gcviewer is almost trivial to do and.

(If you aren't interested in putting it in the main gcviewer that's fine,
I'll just keep it on my github fork.)
On Nov 2, 2012 6:37 PM, "Rupesh Ramachandran" notifications@github.com
wrote:

Have you looked at GCHisto?
http://java.net/projects/gchisto

  • Rupesh

On Nov 1, 2012, at 7:49 PM, Ryan Gardner notifications@github.com
wrote:

If you have suggestions for how to do things better, I can try my hand
at cleaning up the hack I put in place to do it - but having the
distribution of pause times displayed visually alongside the other
visualization really helps me see at a glance what's going on.


Reply to this email directly or view it on GitHub.


Reply to this email directly or view it on GitHubhttps://github.com//issues/43#issuecomment-10032496.


Reply to this email directly or view it on GitHub.

@ryangardner
Copy link
Contributor Author

Oh, ok.

If you look at my fork I've got something kind of working. You have to
expand the window out fairly wide to get the histogram to display - but it
has cool options that show up if you right click on it (save to the png,
adjust scale of axis, etc)

If you are on os x, I also adjusted the pom to use the bundle plugin and
automatically include the required jars - so a mvn clean package will
create the executable bundle and it is easy to see in action
On Nov 2, 2012 7:05 PM, "Rupesh Ramachandran" notifications@github.com
wrote:

I meant look at GCHisto in terms of requirements. I think it's a great
idea to add a histogram feature and make GCviewer more comprehensive.

If JFreeChart does the job and is easy to maintain, I don't see why it's a
problem. However, I'm not a GUI expert and will let the experts chime in.

-Rupesh

On Nov 2, 2012, at 3:57 PM, Ryan Gardner notifications@github.com
wrote:

I've seen gchist, yes. Afaik it isn't being maintained anymore so it
can't
parse modern gc log files

Adding a jfreechart-based histogram to gcviewer is almost trivial to do
and.

(If you aren't interested in putting it in the main gcviewer that's
fine,
I'll just keep it on my github fork.)
On Nov 2, 2012 6:37 PM, "Rupesh Ramachandran" notifications@github.com

wrote:

Have you looked at GCHisto?
http://java.net/projects/gchisto

  • Rupesh

On Nov 1, 2012, at 7:49 PM, Ryan Gardner notifications@github.com
wrote:

If you have suggestions for how to do things better, I can try my
hand
at cleaning up the hack I put in place to do it - but having the
distribution of pause times displayed visually alongside the other
visualization really helps me see at a glance what's going on.


Reply to this email directly or view it on GitHub.


Reply to this email directly or view it on GitHub<
https://github.com/chewiebug/GCViewer/issues/43#issuecomment-10032496>.


Reply to this email directly or view it on GitHub.


Reply to this email directly or view it on GitHubhttps://github.com//issues/43#issuecomment-10033062.

@chewiebug
Copy link
Owner

Hi Ryan

I like the idea of having a histogram of the pause time distribution in
GCViewer. I agree with Rupesh that Gchisto has a good example of a chart
showing pause time distribution.

I haven't used JFreeChart yet. Do you have experience using it? It looks
like a very good chart library with little documentation apart from the
commercial developer's guide. The features like saving to png / zooming
... look very nice indeed.

On my wishlist for your histogram I have the following items:

  • also show full gcs (model.getFullGCEvents())
  • make the differenty types of events appear in different colours
    (like gchisto)
  • possibility to switch the differenty types of events off
    individually (like gchisto)
  • show the histogram in its own tab like the current "chart" tab

Looking forward to seeing more of your histogram!

Regards, Jörg

@ryangardner
Copy link
Contributor Author

I haven't used JFreeChart much before, but getting those additional GC
things and putting them into their own tab should (I think) be relatively
easy to do.

The documentation for JFreeChart does seem lacking - the stuff I've found
from code samples of open source apps seems a lot better than what they
have on their site.

What would be really interesting would be to have both it on its own tab -
and another smaller one on the sidebar showing the current view of the
GCViewer timeline that is displayed (so you can see the distribution of GC
pauses for the time window you are currently examining) - but getting the
total set done first makes more sense.

On Mon, Nov 5, 2012 at 1:16 PM, chewiebug notifications@github.com wrote:

Hi Ryan

I like the idea of having a histogram of the pause time distribution in
GCViewer. I agree with Rupesh that Gchisto has a good example of a chart
showing pause time distribution.

I haven't used JFreeChart yet. Do you have experience using it? It looks
like a very good chart library with little documentation apart from the
commercial developer's guide. The features like saving to png / zooming
... look very nice indeed.

On my wishlist for your histogram I have the following items:

  • also show full gcs (model.getFullGCEvents())
  • make the differenty types of events appear in different colours
    (like gchisto)
  • possibility to switch the differenty types of events off
    individually (like gchisto)
  • show the histogram in its own tab like the current "chart" tab

Looking forward to seeing more of your histogram!

Regards, Jörg


Reply to this email directly or view it on GitHubhttps://github.com//issues/43#issuecomment-10081401.

@chewiebug
Copy link
Owner

Hi Ryan,

I begin to understand what you would like to see in GCViewer. It might
be possible to have both the current chart and your new one in the same
tab. On larger screen that would probably look good, on smaller it would
be a bit crowded I suppose.

There is another issue open partial log file
analysis
, which is a
prerequisite to what you would like to see - information on only a part
of a logfile.

Regards, Jörg

@chewiebug
Copy link
Owner

Hi Ryan

It is again not what you were looking for, but maybe a step closer. I have added support for simple gc logs. Using this export format you are able to use gchisto to show you a histogram.

Regards, Jörg

@mslama
Copy link

mslama commented Aug 28, 2018

Actually if you create graph histogram for real data you find it is rarely usefull. You will see many values localised around average and then some longer times. In graph you will not see much. So I suggest instead of creating graph just compute histogram as table where it is possible to set min,max and step - this can be also based on actual values so default values can be found from data. Besides count you can also compute percentage. And eventually also compute percentiles. This will be much easier as these are tabular data, no complications from graphics. Anyway as histogram data can be copy/pasted or exported then it is easy to use any graphical program to create graph histogram if desired. As this issue is pending for so long this could be step to implement it in some usefull way. It is what I am doing now - get GC times from GC Log and compute histogram to see gc pause distribution.

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

No branches or pull requests

4 participants