[Asterisk-Dev] Current database abstraction effort ?

Brian West brian at bkw.org
Wed Dec 31 15:15:07 MST 2003


> You config your res_odbc to query a particular DSN for a given identifier.
>  Something like this:
>
> [odbc]
> app_voicemail=dsn_mysql_voicemail
> chan_sip=dsn_db2
> chan_iax=dsn_mssql
> default=dsn_text_files


Good idea... but how can we fix this where we can flip a switch and change
between the two options... I was thinking of maybe replacing some of the
API with calls the emulate the standards asterisk calls and return the
values in the same manner.  If we did it like this then the core of
asterisk wouldn't have to be changed much if any at all in most cases.

example:

cfg = ast_load(config);

we have an #ifdef ODBC to use the odbc aware one.

But then again I'm not sure this is the best way.

or a config.c thats odbc aware?

bkw



More information about the asterisk-dev mailing list