You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ojb-user@db.apache.org by CLARAMONTE Jean-Baptiste <jb...@aston.fr> on 2004/11/29 19:26:26 UTC

Is theTwoLevelCache stable ? Could someone share his feedback about it ?

I would like to know if some of you have already used (in a production
environnement would be great) the cache's implementation called
TwoLevelCache. What are your feedback about it ? I have found a post talking
about it (http://www.mail-archive.com/ojb-user@db.apache.org/msg08338.html)
and which was saying that this implementation was resolving some problems
(in particulary the one with circular references) but causes new problems :
I would like to know what are these new problems ...

Thanx in advance 

Regards 

JB 
 

---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org


Re: Is theTwoLevelCache stable ? Could someone share his feedback about it ?

Posted by Armin Waibel <ar...@apache.org>.
Hi JB,

CLARAMONTE Jean-Baptiste wrote:
> I would like to know if some of you have already used (in a production
> environnement would be great) the cache's implementation called
> TwoLevelCache. What are your feedback about it ? I have found a post talking
> about it (http://www.mail-archive.com/ojb-user@db.apache.org/msg08338.html)
> and which was saying that this implementation was resolving some problems
> (in particulary the one with circular references) but causes new problems :
> I would like to know what are these new problems ...
> 

the two-level cache will be introduced in OJB 1.1 (first version already 
in CVS head). The TwoLevelCache class in OJB 1.0.x branch is only a 
prototype. I never used it, so I can't recommend to use it in production 
environment.
The two-level cache will solve problems caused when using 
ObjectCacheDefaultImpl like:
- concurrent dirty read problems
- problems caused by use of different class-descriptor model
- problems caused when using auto-retrieve false (if you update objects 
without a deep materialization of the object).

The second level cache only returns a copy of the real object without 
any referenced objects. Problem: How to build the full materialized 
object (with all references) without DB access for the collection 
references? The cached "flat" object doesn't know which objects be in 
the 1:n/m:n reference. Another problem is materialization of a proxy 
object with circular references (A-->B-->A). If the proxy is an instance 
of A and materialize B, then B materialize an A instance again, because 
the proxy A instance wasn't in the first or second-level cache jet.

regards,
Armin


> Thanx in advance 
> 
> Regards 
> 
> JB 
>  
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
> For additional commands, e-mail: ojb-user-help@db.apache.org
> 
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org