Hi Adrian,

Maybe let's go a bit further towards pool of db connections and wrap a
bunch of lines importing backend into some function that depends on
engine argument?
And later call it with settings.DATABASE_ENGINE to import default backend.

http://code.djangoproject.com/browser/django/trunk/django/db/__init__.py?rev=10026
Lines 12-38.

On Wed, Mar 11, 2009 at 9:45 AM, Adrian Holovaty <adr...@holovaty.com> wrote:
>
> On Tue, Mar 10, 2009 at 9:15 PM, Alex Gaynor <alex.gay...@gmail.com> wrote:
>> I've posted a patch, but I'd like to here from one of the external DB
>> backend maintainers, I know we technically don't have any backwards
>> compatibility requirement here, but I don't think we want to jerk them
>> around too much.  Another thing is I want to encourage all external backends
>> to use DATABASE_OPTIONS for extra options, rather than additional settings,
>> that way they can be DB specific once we have multidb.
>
> Thanks for the patch, Alex. I had already started doing it on my own
> and was pleased to see we came up with almost exactly the same
> solution. The main differences are that I called it
> BaseDatabaseWrapper.settings_dict instead of
> BaseDatabaseWrapper.settings (to make it clear it's a dictionary and
> make it grepable) and I assigned to a local settings_dict variable
> whenever the code needed to refer to self.settings_dict many times.
>
> http://code.djangoproject.com/changeset/10026
>
> This will most probably break external database backends, so I'll send
> out a separate django-developers note about that, in hopes of getting
> their attention.
>
> Adrian
>
> >
>



-- 
Best regards, Yuri V. Baburov, ICQ# 99934676, Skype: yuri.baburov,
MSN: bu...@live.com

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django developers" group.
To post to this group, send email to django-developers@googlegroups.com
To unsubscribe from this group, send email to 
django-developers+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to