On 05/04/13 20:28, Branko Čibej wrote:
On 05.04.2013 18:03, Gary Martin wrote:
On 04/04/13 17:37, Olemis Lang wrote:
On 4/4/13, Gary Martin <[email protected]> wrote:
It looks like there may be a few issues that will turn up with
PostgreSQL backends with the new multi-product setup. I have already
found problems with installation that I hope I have fixed now for
https://issues.apache.org/bloodhound/ticket/497 but there are bound to
be more.
I see some test cases for PostgreSQL ...
{{{
#!sh
$ ls bloodhound_multiproduct/tests/db/
api.py cursor.py __init__.py mysql.py postgres.py util.py
}}}
... but do not seem to fail ... o.O
That is not too surprising if they do not parse the sql statements to
determine whether quotes are for "quoted identifiers" or 'string
constants' - it is not completely unreasonable to call these
programmer errors as PostgreSQL follows the standards while SQLite
(and possibly MySQL?) relaxes these quoting rules. I found a
suggestion that it you shouldn't continue to rely on this for future
versions of SQLite either.
MySQL has to be explicitly put into strict ANSI mode in order to follow
the quoting rules. It's not by default.
Well, as long as non-strict mode doesn't do something crazy like only
accept quoting in exactly the opposite form, then we can't go far wrong!
These relaxed interpretations are encouraging us to be a bit too relaxed
about getting the SQL right.
I've just found some more problems associated with the postgres
backend so I will be looking into this kind of thing for a bit!
I suggest all testing should be done with at least two databases, pgsql
being one of them; although for actual installations, of the three
options mentioned, I'd only ever recommend PostgreSQL.
-- Brane
Yes, I completely agree with this. I do not want to see the PostgreSQL
support slipping.
Incidentally, if you want to run SQLite and PostgreSQL backends side by
side from the same tracd instance then, if you already have an
appropriate PostgreSQL user and 'bloodhound' database ready, you can do
something like this:
python bloodhound_setup.py -d sqlite --project=sqlite --admin-user=$ADUSER
--admin-password=$ADPASS
python bloodhound_setup.py -d postgres --project=postgres
--admin-user=$ADUSER --admin-password=$ADPASS -u $PGUSER -p $PGPASS
tracd --port=8000 bloodhound/environments/sqlite/
bloodhound/environments/postgres/
and these will then turn up at localhost:8000/sqlite/ and
localhost:8000/postgres/. I'll try to provide more information in the
wiki to help with a suggested dev setup soon.
Do we know if anyone has been looking at using MySQL with bloodhound?
Cheers,
Gary