Rickard Öberg schrieb:
On 8/2/11 18:08 , Falko Bräutigam wrote:
Yes, but what is "full"?
Pick a number as default, and then allow UseCase to override.
After some investigation on this I found this one:
http://bugs.sun.com/bugdatabase/view_bug.do;jsessionid=cfd518f51afc7780e5188276b5f9?bug_id=6912889
That's one of the issues. There are more. In essence: not worth it.
Forget you ever heard about SoftReferences, and life becomes easier.
It turns out that the GC policy for SoftReferences itself is the
problem. But on the other hand, memory management is clearly the job of
the VM/GC. Doing this "by hand" via a separate thread, checking memory
and releasing references, introduces a bunch of other problems *and* is
probably less efficient.
somewhat perplexed...
I think Ehcache does this already, so just go with that I guess is easiest.
I'm about to implement this. Seems to work well. Strong references for
timestamps and a (valid) cache for the states.
But now, after a ConcurrentEntityStateModificationException occurred and the
user has "merged" the entity versions, I don't see a way to tell the
ConcurrentModificationCheckConcern that this entity version is now "merged" and
hence "valid" (if it was not modified after this merge, which I cannot detect
either). Do I miss something?
-Falko
--
Falko Bräutigam
http://polymap.org
_______________________________________________
qi4j-dev mailing list
[email protected]
http://lists.ops4j.org/mailman/listinfo/qi4j-dev