Hello,

I recently came accross the implementation of PageSourceImpl where PageImpl instances are softly refereneced into the pageCache:

private final Map<CachedPageKey, SoftReference<Page>> pageCache = CollectionFactory.newConcurrentMap();

This implementation caused troubles, when you bring your system into memory preassure. The JVM will start to throw away the PageImpl to free up memory - but during request processing he needs the PageImpl again and starts creating it again. So basically you end up loosing your pageCache at all and start creating the PageImpl instances on every request, which take way to much time and takes load onto the CPU. So basically you are hiding a memory problem by making the system slow and raise CPU load.

I would suggest to use "normal" references for the PageCache or at least only do SoftReferences only when not in production mode. Otherwise we are going to cover memory problems for too long.

What do you think about that?

Robert

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

Reply via email to