SQLite support (again)

Mark Johnston markjdb at gmail.com
Sun May 20 21:09:23 EDT 2012


On Wed, May 16, 2012 at 12:13:29AM -0700, Ade Lovett wrote:
> On 5/15/2012 07:20, Mark Johnston wrote:
> > I split them into four actual patches; patches 1-3 in the current set
> > are essentially identical to patches 2-4 in [1]. Patch 4 adds column
> > names to all the webui ds queries, and also replaces the MDB2 code. As
> > before, I'll be happy to maintain SQLite support, and I'll also be
> > willing to submit updates to the README.
> >
> > The patches are here:
> > http://www.student.cs.uwaterloo.ca/~m6johnst/patch/tb_sqlite/
> 
> I've looked at the patches, and they'd need to be somewhat reworked to 
> provide for a "better" upgrade path.
> 
> For example:
> 
> step 1:  conversion from MDB2->PDO.  this is a big step in its own right 
> (and one that I'd heartily support, and have even looked at doing 
> myself).  But more importantly, it should _only_ be MDB2->PDO 
> conversion, with no reference at all to new backend SQL drivers.
> 
> Part of this step would also to be changing the required dependencies in 
> order to implement a PDO-enabled webui, along with any appropriate 
> documentation changes.  Given the way in which PDO operates, part of the 
> conversion would also require the '... AS <foo>' changes to the SQL 
> statements that are then passed to the underlying TinderboxDS.pm calls.

Ok, I've posted a MDB2 -> PDO patch as [1]. It includes a change to the
README and doesn't contain any mention of SQLite. I did some basic
testing with both PostgreSQL and MySQL, and everything looks ok.

I'm a bit confused by your mention of TinderboxDS.pm - AFAIK, the webui
db access layer is completely independent of that.

Thanks,
-Mark

[1] www.student.cs.uwaterloo.ca/~m6johnst/patch/tb_sqlite/tb_MDB2_to_PDO.patch

> 
> step 2:  addition of the ability to use SQLite as a backend, in addition 
> to the existing mysql/postgresql backends.  This would include the 
> SQLite-specific schemas in sql/*, and tweaks to db_init _and_ the 
> (now-using-PDO webui) to allow SQLite to be used as a backend.
> 
> 
> This approach makes the relevant patches/commits that much more atomic 
> and easier to manage, rather than the existing set of 4 patches that 
> have lots of inter-dependencies amongst themselves.
> 
> If you can rework things this way, then I'm more than happy to set up 
> some test instances, verify that they work (first the MDB2->PDO 
> migration, and then the addition of an SQLite backend), and perform the 
> relevant commits.


More information about the tinderbox-list mailing list