How to avoid Garbage Collection
Low garbage applicationFor low latency trading system, minimising GC time is important. The extreme case is avoid GCs all together.
If you reduce the garbage produced and increase your Eden size you can reduce your GCs to once per day (as an over night task) In the case of this application the Full GC triggered at 5 am every morning takes 1-2 seconds (during the overnight maintenance window)
It should be possible to extend the period between GCs to once a week.
Absolutely correct mate and if it comes to garbage string is number one because of its immutability :). I have also blogged about garbage collection java some time back. let me know how do you find it.ReplyDelete
Are you doing anything other than System.gc() to call the collection during the maintenance window? How often does the JVM follow your suggestion to collect?ReplyDelete