db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Oystein Grovlen - Sun Norway <Oystein.Grov...@Sun.COM>
Subject Re: Clean up commit/rollback code at language/jdbc level by moving to a oo based callback scheme??
Date Wed, 21 Mar 2007 10:57:14 GMT
Daniel John Debrunner wrote:

> I was wondering if a callback system might be better. The LCC would 
> provide an api where objects could be added and have methods called on 
> rollback, commit or statement rollback. This then would make the 
> commit/rollback methods very clean, and ensure that the object was 
> notified in all situations, rather than relying on the coder to add in 
> all the various locations. Performance should be better as if there are 
> no LOBs or temp tables (or whatever) then the list would be empty rather 
> than having to explicit check that each type (LOBs, temp tables, log 
> statement text, DDL transaction) has no cleanup action to perform.

I think this is a very good idea.  In fact, when thinking about the 
locator cleanup, my first assumption was that such a framework already 
existed.  When looking at the code, I realized that it did not.  One of 
the good thing about such a framework, is that you do not have to worry 
about finding all places where a transaction may be committed/rolled back.

-- 
Øystein

Mime
View raw message