Thanks for the response, Stefan. A simple BeanEditForm unfortunately won't 
suffice for me as indicated in my previous posts, I'm doing something a little 
more tricky. But thanks anyhow.

Using a ComponentSource to retrieve the components I need seems to be solving 
the problem. I re-ran the same load test mentioned in my first post after 
making the code changes (same config) and I got some good results.

JConsole Memory usage:
http://img5.imageshack.us/img5/5303/tapestryloadtestmemoryu.jpg

Memory Dump in YourKit:
http://img16.imageshack.us/img16/1663/memorydumpclasslistfixe.png

54K ComponentPageElement instances using 200MB seem to be so much better than 
392K ComponentPageElement instances using 1.5GB. With a hard limit of 10 and 8 
pages, that's still 675 component page elements / page though. Does that seem 
reasonable? (Helluva lot better than before, for sure). I only fixed this for 
the 2 pages that were used in the load test, if Tapestry loads all page and 
component combinations on first access then this may further improve when I fix 
the rest. 

So nobody has still answered my question whether ComponentSource is an 
acceptable way to retrieve a component instance you need? The interface is not 
internal, so I'd assume so, but the implementation is, and is it reasonable to 
expect that future implementations would continue to provide cached, non-new 
components when called?

Thanks.



----- Original Message ----
From: Stefan <ste...@wammel.com>
To: Tapestry users <users@tapestry.apache.org>
Sent: Thursday, September 17, 2009 2:58:09 AM
Subject: Re: [T5.0.18] Out of Memory Error / Potential Leak (doesn't reduce  
after forced GC)

I've tried it with a ComponentWrapper (or loader) too, but don't got it to work 
this way.
Now i use a simple BeanEditForm with an own simple BeanModel.
I pass a property with my custom datatype into the beanmodel and it does the 
rest.

Define and register your custom components with their corresponding datatypes 
as described here:
http://wiki.apache.org/tapestry/Tapestry5HowToCreateAPropertyEditBlock
and try it with the propertyEditor or a beanEditor.



      


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org

Reply via email to