Hi.

I'm a programmer from the same group, and I would like to elaborate more, as 
this is a pressing issue for us. So I'm sorry in advance for the length of the 
response ( - :

We currently are using a system that has an implementation
of a cache that uses several static hashmaps in order to manage all in-memory 
static objects. We're trying to use jbosscache (AOP) behind the scenes to make 
the move to a distributed application. We chose jbosscache because it offers 
(or at least claims to offer) a way to work with distributed applications with 
very little added code. 

The idea was to put all our hashmaps on an instance of treecacheAOP,
and to let the cacheMapInterceptor (and of course all aspectized sub POJOs) do 
all the distributed work behind the scenes. Our module includes a load which 
consists of non-frequent put actions, but a very heavy load of get actions. 

We joined two servers as a cluster and ran the following test: Server number 1 
performed a put of a hashmap on the cache once in the initialization stage of 
the server. It also ran a thread that changed a member of the map every 30 
seconds (just to add some noise). Server 2 did  map = cahce.cache.getObject  on 
 its initialization routine and then performed a map.get(object) on each 
transaction. 

After debugging the code we learned that the MapInterceptor.get calls getObject 
which goes to the network each time. As we need to perform for each user 
transaction several get operations on diffrent hash maps, this is not 
acceptable. 

The question is: why does getObject goes to the network each time? 
And, if this is a bug, what can we do? (A side from dropping jbosscache). We 
thought about creating our own implementation of a cached map, which holds all 
aspectized pojos localy, and performs getObject only if the local key does not 
exist. But then we will have to deal with the removal of objects from the cache 
(Unless the POJO reference itself will become null?). 

Any suggestions (Please)?


View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3881208#3881208

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3881208


-------------------------------------------------------
This SF.Net email is sponsored by: NEC IT Guy Games.  How far can you shotput
a projector? How fast can you ride your desk chair down the office luge track?
If you want to score the big prize, get to know the little guy.  
Play to win an NEC 61" plasma display: http://www.necitguy.com/?r=20
_______________________________________________
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to