On Mon, Dec 12, 2005 at 12:55:38PM +0800, Yuan HOng wrote:
> I modified my patch so that only unchanged stales objects will be updated.
>
> Index: main.py
>
> ===================================================================
>
> --- main.py (revision 1386)
>
> +++ main.py (working copy)
>
> @@ -960,6 +960,13 @@
>
> cache.put(id, cls, val)
> finally:
> cache.finishPut(cls)
> + elif selectResults and not val.dirty:
> + val._SO_writeLock.acquire()
> + try:
> + val._SO_selectInit(selectResults)
> + val.sqlmeta.expired = False
> + finally:
> + val._SO_writeLock.release()
> return val
>
> get = classmethod(get)
Applied at the revision 1425 to the trunk, 1426 to the 0.7-branch. Thank
you.
Oleg.
--
Oleg Broytmann http://phd.pp.ru/ phd@...
Programmers don't die, they just GOSUB without RETURN.
|