Login | Register
My pages Projects Community openCollabNet

Discussions > users > [argouml-users] Heap limits in OS X

argouml
Discussion topic

Hide all messages in topic

All messages in topic

Re: [argouml-users] Heap limits in OS X

Author tfmorris
Full name Tom Morris
Date 2011-10-03 20:13:54 PDT
Message On Wed, Sep 14, 2011 at 10:58 PM, Tom Morris <tfmorris at gmail dot com> wrote:

> Hi Jack. It's been a while since I coded this up, but
> On Wed, Sep 14, 2011 at 8:53 PM, Jack Repenning <jrepenning at collab dot net>
> wrote:
> > I suppose a "warn at 500 for a limit of 600" is not unduly alarmist … but
> I gave it 1024, not just 600, why's it whining at me?
>
> I hope it's not whining too loudly, but, as I remember it, the orange
> line limit is arbitrary (ie picked out of the air by me) and full
> scale on the graph is the *current* (not max) heap size. Typical JVM
> behavior is for heap allocations to ratchet up towards some limit
> (e.g. 90% of the current heap) which triggers a garbage collection and
> when heap usage stays too close to the total heap size for a period of
> time to increase the size of the heap (by asking the O/S for more
> memory) and, finally, when the heap has been expanded as much as
> possible, to give an OutOfMemory error.
>
> > Should I have set this elsewhere? Should I adjust my execrations? Are
> there things (like, say, extensions) I can remove to free some heap?
> >
> > And, is this heap usage reasonable? I only have one diagram (a Sequence
> diagram), with four Classifiers, and 22 Actions.
>
> Pretty much impossible to say without more info.

...


> The real warning size to watch for is that the heap indicator, instead
> of going from 90% to 50% continually, stays pegged at 90%+ (which will
> also mean that you've maxed out your heap expansion opportunities.
>
> With the limited time I have available to commit, I'm much more
> focused on ArgoEclipse than ArgoUML, but I'd be happy to tweak the
> current implementation of the heap monitor dispaly if folks can come
> up with a consensus for a more valuable display (e.g. don't show the
> alarming orange color at whatever the threshold is set at).


 So, I reviewed the implementation recently because I wanted to reuse
aspects of it for Google Refine.

Despite the lack of feedback on the current implementation, I've tweaked the
display protocol to use the max possible heap size, as opposed to the
current allocated heap size for the full range display. This will sometimes
be misleading since the operating system may not honor requests for memory
up to the max size, but, hopefully, it should be accurate more often than
the previous implementation (particularly in these days of copious RAM).

Tom
Attachments

Re: [argouml-users] Heap limits in OS X

Author tfmorris
Full name Tom Morris
Date 2011-09-14 19:58:16 PDT
Message Hi Jack. It's been a while since I coded this up, but

On Wed, Sep 14, 2011 at 8:53 PM, Jack Repenning <jrepenning at collab dot net> wrote:

> Contents/Info.plist includes a dict key [Java][VMOptions] that contains an -Xmx value, so I changed that and restarted ArgoUML … but it doesn't seem like the change had the expected effect: I set it to 1024M, but the little heap indicator in the bottom right of the main window is saying "503M used of 600M total" and showing a warning orange band.
>
> I suppose a "warn at 500 for a limit of 600" is not unduly alarmist … but I gave it 1024, not just 600, why's it whining at me?

I hope it's not whining too loudly, but, as I remember it, the orange
line limit is arbitrary (ie picked out of the air by me) and full
scale on the graph is the *current* (not max) heap size. Typical JVM
behavior is for heap allocations to ratchet up towards some limit
(e.g. 90% of the current heap) which triggers a garbage collection and
when heap usage stays too close to the total heap size for a period of
time to increase the size of the heap (by asking the O/S for more
memory) and, finally, when the heap has been expanded as much as
possible, to give an OutOfMemory error.

> Should I have set this elsewhere? Should I adjust my execrations? Are there things (like, say, extensions) I can remove to free some heap?
>
> And, is this heap usage reasonable? I only have one diagram (a Sequence diagram), with four Classifiers, and 22 Actions.

Pretty much impossible to say without more info. If that's 500 MB out
of 600 MB, of which, 250 MB could be garbage collected if needed, I'd
say it's not an issue. There used to be a menu command to force a
garbage collection, but I'm not sure it's still there. Even if it is,
it's really only a way to establish a benchmark of actual heap usage
-- it's not a way to reduce memory usage or improve efficiency.

The real warning size to watch for is that the heap indicator, instead
of going from 90% to 50% continually, stays pegged at 90%+ (which will
also mean that you've maxed out your heap expansion opportunities.

With the limited time I have available to commit, I'm much more
focused on ArgoEclipse than ArgoUML, but I'd be happy to tweak the
current implementation of the heap monitor dispaly if folks can come
up with a consensus for a more valuable display (e.g. don't show the
alarming orange color at whatever the threshold is set at).

Tom

[argouml-users] Heap limits in OS X

Author jrepenning
Full name Jack Repenning
Date 2011-09-14 17:53:42 PDT
Message The FAQ mentions tweaking the heap limits "in the command line." I'm familiar with Java and command lines and -Xmx, but on OS X I don't actually *have* a command line, just

 ArgoUML.app/Contents​/MacOS/JavaApplicati​onStub

Contents/Info.plist includes a dict key [Java][VMOptions] that contains an -Xmx value, so I changed that and restarted ArgoUML … but it doesn't seem like the change had the expected effect: I set it to 1024M, but the little heap indicator in the bottom right of the main window is saying "503M used of 600M total" and showing a warning orange band.

I suppose a "warn at 500 for a limit of 600" is not unduly alarmist … but I gave it 1024, not just 600, why's it whining at me?

Should I have set this elsewhere? Should I adjust my execrations? Are there things (like, say, extensions) I can remove to free some heap?

And, is this heap usage reasonable? I only have one diagram (a Sequence diagram), with four Classifiers, and 22 Actions.
Messages per page: