On Tue, Sep 08, 2009 at 10:41:20AM +0200, Sophana K wrote:
> > The only place I could suspect is the call dbConnection.getConnection()
> > in Transaction.__init__().
> >
> I don't understand how this code works.
> Why is the transaction stored into the threadlocal (in doInTransaction)?
To allow different threads to assign different connections to one
ConnectionHub instance.
> Why doesn't the transaction stay local to the doInTransaction function?
So that the transaction is propagated to all classes that use the
ConnectionHub instance.
> >> I forgot to say. It looks that once this happened once, all upcoming
> >> transactions fail the same way.
> Why do I have to restart my application to stop this?
How could I guess?..
Oleg.
--
Oleg Broytmann http://phd.pp.ru/ ph...@ph...
Programmers don't die, they just GOSUB without RETURN.
|