Aug 4 2008

Sun JVM 1.6 Heap Memory Behavior with ColdFusion Frameworks

Posted by Mike Brunt at 7:29 AM
43 comments
- Categories: ColdFusion | JRun-J2EE

I am pretty sure that dry title means that many will not read this post but it is fairly important.  We have worked with several clients who use ModelGlue/Mach-ii-ColdSpring-Reactor/Transfer as a triumvirate of co-working frameworks and each have had JVM memory problems.  There is a fairly healthy debate which advises the rolling back of the default JVM which comes with ColdFusion 8 when ModelGlue/Mach-ii-ColdSpring-Reactor/Transfer are used.  Sun 1.6, or 6 as it also known, is the default JVM with CF8 and many have rolled back to the Sun JVM 1.5 or 5.  This is because of the class loader behavior in the 1.6 JVM which can mean that the instantiation time for heavy applications can take a long time, some have reported this taking minutes.  This will supposedly be fixed when the latest beta of the 1.6 JVM is released. Our findings in several load tests with several clients show that the 1.6 JVM is more efficient over the ongoing application use, typically 15-20% more efficient.

There is another behavioral difference in the 1.6 JVM which is important to note.  We found that in all previous JVM's there was a default behavior which ran explicit Full Garbage Collections (Full GC's) every 60 seconds. It appears this is part of the Remote Method Invocation (RMI) mechanism.  As Full GC's cause the JVM to pause completely (know as stop-the-world events) too many Full GC's is not a good thing.  So in the 1.6 JVM it appears that this Full GC behavior is no longer there, which is a better thing.  However and as I mentioned above, we have several clients using ModelGlue/Mach-ii-ColdSpring-Reactor/Transfer and in that case we have observed memory problems which often resulted in the heap running out of memory.  Whatever default Full GC behavior in is the 1.6 JVM it appears inadequate for some CF applications.  Through endurance load testing (up to 12 hours) we have found that causing explicit Full GC's every 10 minutes is an optimal setting.  To enable this you need to add these two arguments to the JVM arguments in the jvm.config file located either in {drive-letter}\ColdFusion8\runitime\bin or {drive-letter}\JRun4\bin, depending on your install:

-Dsun.rmi.dgc.client.gcInterval=600000 -Dsun.rmi.dgc.server.gcInterval=600000

This will run explicit  Full GC's every 10 minutes.  Considering what we have found we strongly advise that you do not disable explicit Full GC's and if you have done so we suggest you replace that with the arguments shown here.  All instances will need to be restarted after adding these arguments.

Comments

Brian

Brian wrote on 08/05/08 5:10 AM

Mike -- little off topic ... have you seen any evidence that similar setups and java settings that Linux v Windows performs any better or worse?
Michael Sharman

Michael Sharman wrote on 08/05/08 5:39 AM

Hi Mike, thanks for posting your findings.

>This will supposedly be fixed when the latest beta of the 1.6 JVM is released.

Is this correct? Isn't CF8 already (by default) using JVM 1.6?
Mike Brunt

Mike Brunt wrote on 08/05/08 10:52 AM

@Brian it depends if we are talking 32 bit then Unix-Linux has an advantage over Windows in that you can use up to 3GB for the heap, in Windows that is effectively 1.5GB. On 64 bit systems I feel the difference in terms of heap memory goes away because so much is available irrespective of OS.
Mike Brunt

Mike Brunt wrote on 08/05/08 10:55 AM

@Micheal, thanks for your kind comments. Yes CF is using Sun JVM 1.6 but there is an update to the 1.6 JVM in beta and also a 1.7 in the works both of which supposedly fix the class loader issue. You can find more information here...

http://java.sun.com/javase/downloads/index.jsp
Wil Genovese

Wil Genovese wrote on 08/05/08 1:52 PM

"-Dsun.rmi.dgc.client.gcInterval=600000 -Dsun.rmi.dgc.server.gcInterval=600000"

We've been doing this for years now with JVM 1.4 and now with JVM 1.6
Mike Brunt

Mike Brunt wrote on 08/05/08 5:26 PM

Yes Wil it is definitely good practice and seems even moreso for ModelGlue/Mach-ii-ColdSpring-Reactor/Transfer apps.
games

games wrote on 03/13/10 3:26 AM

why my comment dont submitted??
Atulesh khantwal

Atulesh khantwal wrote on 09/26/10 8:00 AM

I have tried to download the SUN JVM 1.6 for IFFCO entrance test but unable to find that. Please send me a link / show me the way to download that link
Atulesh khantwal

Atulesh khantwal wrote on 09/26/10 8:00 AM

I have tried to download the SUN JVM 1.6 for IFFCO entrance test but unable to find that. Please send me a link / show me the way to download that link.
device brrip

device brrip wrote on 10/12/10 12:20 AM

Works for me i didn't have this problem.
qiudong

qiudong wrote on 03/17/11 7:05 PM

unless http://feiyue.eu.com/feiyue-low-cut-cancas you have more than guests.
superdry sale

superdry sale wrote on 11/18/11 6:07 PM

Every superdry sale fans convinced superdry will be next huge designer. The colors of superdry uk are just amazing because they are universally flattering! It is a great alternative for people who are tired of buying out the entire superdry outlet line and are finished shopping at Our Superdry uk sale store.
business name suggestions

business name suggestions wrote on 04/15/12 11:27 PM

Good to see this idea, I am actually newbie in learning this field, hopefully I could get ideas from here.
Tutaj

Tutaj wrote on 05/22/12 12:21 PM

Great post Mike, keep it up man!
Best,
Tutaj
boysshoppingonline.com

boysshoppingonline.com wrote on 12/27/12 8:44 AM

Thanks for sharing so significative article with us. I agree with your idea competely.I am looking forward to another great article from you.
www.boysshoppingonline.com
ustopcreditcards.com

ustopcreditcards.com wrote on 01/04/13 3:12 AM

I want to know more about Fibromyalgia Network. Please make a note on that.
401kloansguide.com

401kloansguide.com wrote on 01/04/13 3:17 AM

I would like to say thank for sharing this great article. We can’t get this kind of information from anywhere.
wedding photography

wedding photography wrote on 01/15/13 1:49 AM

How can we avoid Fibromyalgia? It is very painful diseases.
Star wedding

Star wedding wrote on 01/15/13 1:50 AM

Can you share some more detail of chronic pain? I really like to see.
Beverly Clark Wedding

Beverly Clark Wedding wrote on 01/15/13 1:50 AM

I have read your post and I am waiting for another interesting post. Please update useful information on your blog.
promo video music

promo video music wrote on 05/07/13 2:50 AM

Really your post is really very good and I appreciate it. It’s hard to sort the good from the bad sometimes, but I think you’ve nailed it. You write very well which is amazing. I really impressed by your post. I like this shop. Im continually obtaining new issues that I want
?????? ?????

?????? ????? wrote on 05/29/13 10:37 AM

Really your post is really very good and I appreciate it. It’s hard to sort the good from the bad sometimes, but I think you’ve nailed it. You write very well which is amazing. I really impressed
isabel marant sneakers

isabel marant sneakers wrote on 10/21/13 8:09 AM

Thank you expressing the knowledge there would turn out to be quite a few concerns from group.
Uch - Sys Ope

Uch - Sys Ope wrote on 01/01/14 1:37 PM

Thanks for the write up, I program, well not in this particular language, but I'm piecing together a few things now.
formatting ebook

formatting ebook wrote on 01/03/14 9:44 PM

This test had no caching and no BigMemory. We then enabled caching and BigMemory and ran the same test again, this time there was no hanging and we actually hit over 200 busy threads so we were able to show that BigMemory is beneficial.
essay writing

essay writing wrote on 01/24/14 7:54 AM

Considering what we bear institute we strongly recommend that you do hardly incapacitate categorical Resonant GC's besides if you contain ended so we recommend you renew that along the tiffs shown here. Many occasions determination demand to be restarted later adding these contentions.
cheaphomesecurity

cheaphomesecurity wrote on 03/07/14 5:14 AM

The first thing that we recommend is that you look at your house from the exterior in much the same way that a burglar would. Burglars case neighborhoods looking for targets of opportunity. Those are homes that look, to them, to be easy targets.
thevirtualprivateserver

thevirtualprivateserver wrote on 03/07/14 5:14 AM

Virtual Private Server is better known as VPS and is also commonly known as Virtual Dedicated Server or VDS. Are you familiar with this type of a server? This involves a process through which a physical server computer is divided into various servers;
office2010professional

office2010professional wrote on 03/07/14 5:14 AM

Microsoft Office 2010 is definitely an exciting package which will truly create a lasting impact of innovative beauty as well as maximum efficiency at its best overall performance.
Roman Shades

Roman Shades wrote on 03/10/14 5:10 AM

I really enjoy to read all the content is posted on your blog. It's easy to read, the content is great, and you’re an educated writer unlike most of the blogs.thanks for the post.
financial adviser tips

financial adviser tips wrote on 03/27/14 5:54 AM

There are some fairly decent analytics too and allow traders to view performance in a progressive manner as well as other stats to make better-informed trading decisions.
flight and hotel deals

flight and hotel deals wrote on 03/27/14 5:54 AM

On this site I’ll be providing a person with ideas and ways that will help you decide about the best journey pillow that will help improve your own travel encounter.
masculine shopping

masculine shopping wrote on 03/27/14 5:55 AM

A poor reaction doesn’t suggest that your pet and clothing are incompatible, but it will mean you may want to reconsider the precise choice associated with clothes chosen.
thesis writers

thesis writers wrote on 04/22/14 1:56 AM

We possess worked beside various consumers who custom ModelGlue/Mach-ii-ColdSpring-Reactor/Delegate as a triumvirate of co-employed trestles also apiece possess had JVM rote enigmas. There is a fairly fit argument which informs the rolling posterior of the failure JVM which befalls along ColdFusion 8 whereas ModelGlue/Mach-ii-ColdSpring-Reactor/Give are worn.
freedebtconsolidationquotes.com

freedebtconsolidationquotes.com wrote on 05/02/14 2:49 AM

This is therefore of the variety loader manner in the 1.6 JVM which can low that the instantiation age for dull efforts can choose a lust tour, any enjoy reported this taking tinys.
glashandel amsterdam

glashandel amsterdam wrote on 05/05/14 3:33 AM

As Full GC's source the JVM to breath entirely (experience as arrest-the-creation contingencys) also numerous Full GC's is negative a beneficial fad. So in the 1.6 JVM it arrives that this Full GC mien is no longer there, which is a amend article.
general electric stock

general electric stock wrote on 05/28/14 3:11 AM

This is since of the species loader protocol in the 1.6 JVM which can humble that the instantiation phase for sluggish diligences can commandeer a lust cycle, part experience reported this taking insignificants.
Dissertation Proposal Writing Service

Dissertation Proposal Writing Service wrote on 05/31/14 7:28 AM

Interesting topic. I simply determine it a minute strange that the aspect of "framework" about the ColdFusion is one of the factors why it is not integrated on the TIOBE index.
scope of dissertation writing

scope of dissertation writing wrote on 07/25/14 8:09 PM

This bypass's the part of the framework and allow me to imagine what parts ..... This is one thing I love about the ColdFusion community.
law dissertation

law dissertation wrote on 07/25/14 8:38 PM

The best quickly easily just want show go one category inkjet report statement
Tiget

Tiget wrote on 07/26/14 7:45 AM

Very interesting research and experiment. <a href="http://dissertationadvice.co.uk/">uk dissertation writers</a> I'll recommend this article to my friends.
Mona

Mona wrote on 07/28/14 2:23 AM

I agree with you. <a href="http://dissertationadvice.co.uk/">dissertationadvice</a>; It is fairly important for everyone. Thanks.
Online Pharmacy

Online Pharmacy wrote on 08/21/14 12:27 PM

I like reading this. You have given me a good solution of my work. Thanks.

Write your comment



(it will not be displayed)



Leave this field empty: