|
|
Learning goals of this exercise
In this exercise you will learn:
Background for this exercise
Please see Exercise 1 for an overview of running
the javaperf GUI launcher.
In this exercise we want to get the benefits of AggressiveHeap that we learned about in Exercise 11, but want to override certain defaults -- especially the maximum memory usage.
Steps to follow
-server -XX:+AggresiveHeap and our best heap tuning from Exercise 9 (perm gen 12 MB, max heap 16 MB and disable explicit GC's).
compiler=-server
|
. You will see the Java 2D Demo application start.... ![[Stop]](Stop.png)
Summary
Should I always use
AggressiveHeap for server workloads? It's a good test to include
in your test plan. It's a hint to the JVM that your application
will have a lot of 'server-like' properties.
Do I have to take
AggressiveHeap as an "all or nothing" option? No, you can set
AggressiveHeap and override it as necessary (for maximum heap size and
you can even change to a different garbage collector).
What if I want the parallel
collector (but not necessarily everything with AggressiveHeap)?
You certainly can evaluate the impact of just changing the collector on
its own. The option to select the parallel collector is -XX:+UseParallelGC as described in the
Tuning
Garbage Collection with the 5.0 Java™ Virtual Machine
document.
Next Steps
This lab documentation is licensed under a
Creative Commons Attribution-NonCommercial-ShareAlike 2.5 License.