On Sat, 21 Feb 2004 16:02:54 +0100 Armin Waibel <[EMAIL PROTECTED]> wrote:
> "something working the next days", puh!
Nobody expects you to implement this "the next days" in OJB. This is a volunteer
effort, anyway. It is just me who needs a working application, whether it is based on
OJB or not.
> This is exactly what we want for 1.1. We have to introduce a real
> two-level cache.
> On first level we temporary buffer objects to resolve circular
> references, on second level we cache copies of objects without their
> references. This is nothing to make work in a few days ;-)
> In CVS you can find a ObjectCache (alpha-)implementation by Oliver Matz
> called TwoLevelCache which try to bypass current cache problems (but
> cause new problems).
Well, since I am under tight time pressure I am not free for any experiment that might
fail. For my concrete project I decided to do it The Hard Way, junk OJB and implement
everything with direct JDBC calls. This is not elegant, leaves room for bugs but it
does work and I have full control over what happens. And since I have only a handfull
of classes and a rather simple data model, switching to JDBC wasn't too hard.
I'd might get back to OJB later with other projects, though.
> hmm, you can use non-distributed ObjectCache implementation, e.g.
> ObjectCachePerBrokerImpl. This supports circular references and avoid
> concurrent object modification by other threads/broker instances.
> But you will loose all cached objects when broker was closed/rolled back.
> Nevertheless, if you have a fast DB and a fast network between OJB and
> DB this should be ok.
I tried the ObjectCachePerBrokerImpl but unfortunately lost the circular references.
> Or before start to modify make a deep copy of the object (e.g. introduce
> a CopyFactory or something similar), then lock the copy and start to modify.
That's just what I wanted to avoid. I'd like to retrieve an object from the DB, modify
it and then either persist the modifications or throw them away.
Okay, folks, thanks for your time and effort and good luck with forthcoming OJB
versions! I'll keep an eye on its development - but just not now.
Best regards
Rainer Klute
Rainer Klute IT-Consulting GmbH
Dipl.-Inform.
Rainer Klute E-Mail: [EMAIL PROTECTED]
K�rner Grund 24 Telefon: +49 172 2324824
D-44143 Dortmund Telefax: +49 231 5349423
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]