On Wed, Mar 9, 2011 at 1:00 PM, Jan Juno <janko...@gmail.com> wrote:
> I have One Array-list(with over 10000 objects in it) what is the best
> practice for caching it so I don't have to load it over and over again in
> each request?

Usually at our company we expect our ORM mapper (hibernate) to take
care of caching, so it is not a problem for us to ask the ORM for the
same query again and again and again.

I'd use a cache for that. Either something home grown (usually not a
great idea, but for a single use case it might work), or something
like ehcache. If the item can't be found in the cache, retrieve it
from data store and put it in cache.

I wouldn't keep the 10k objects in a page instance or the user session
since that will be serialized with each request.

Martijn

-- 
Become a Wicket expert, learn from the best: http://wicketinaction.com

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

Reply via email to