Re: [Exim] Opinions sought: Exim and MYSQL

Αρχική Σελίδα
Delete this message
Reply to this message
Συντάκτης: Philip Hazel
Ημερομηνία:  
Προς: Malcolm Beattie
Υ/ο: exim-users
Αντικείμενο: Re: [Exim] Opinions sought: Exim and MYSQL
On Tue, 13 Jul 1999, Malcolm Beattie wrote:

> If you don't want to rewrite the relevant Exim internals twenty times
> over or have non-portable database lookups (as happened to Perl before
> DBI became widespread) then I think you'll want to look before you
> leap. Once you release an Exim with a particular API for one database
> it may turn out to be very difficult to reengineer for other databases
> without breaking the API (both user-visible functions in the config
> file and whatever underlying C API you've chosen) or giving
> portability problems ("this config file only works for CoolDB").


Thank you for your useful comments. Unfortunately, the leap has already
happened - a long time ago - with the support for NIS+, and more
recently for LDAP. MYSQL is just "one more". I re-engineered Exim at one
point so that each database gets called from its own little set of C
functions which have a standard interface to the rest of Exim. Thus,
adding a new one does not require any rewriting inside the rest of Exim;
you just have to add the new functions, which are included in the binary
only if the build-time configuration requests it. Chapter 51 even tells
you how to do it!

The points you make about quoting are well-taken. Exim does have some
simple quoting functions, but probably not enough to handle MYSQL
"properly". I will think about generalized quoting capabilities.

Philip

-- 
Philip Hazel            University of Cambridge Computing Service,
ph10@???      Cambridge, England. Phone: +44 1223 334714.