I have just commited a major restructuring the dlr module.

Basicly my intention was to abstract the dlr_foobar() calls to allow
multiple different external storage types, i.e. MySQL.

There is a new multi group introduced called 'mysql-connection', which
looks like this:

  group = mysql-connection
  id = dlr-db 
  host = localhost
  mysql-username = foo
  mysql-password = bar
  database = dlr

and defines a gernal mysql database connection. This may be used not
only for DLRs like in this case, but also for dynamic retrievement of
sms-service, sendsms-user definitions and so on. (Basicly this is
usefull for anyone whos setup changes very dynamicaly).

For the DLR MySQL storage support there is a new single group called
'dlr-mysql' which holds all table field names that are required to
store the values to the specific table, it looks like this:

  group = dlr-mysql
  mysql-id = dlr-db
  table = dlr
  field-smsc = smsc
  field-timestamp = ts
  field-destination = destination
  field-service = service
  field-url = url
  field-mask = mask
  field-status = status

Hence there is no need to hardcode the values to gw/dlr.c.

Additionally I made the external DLR storage configuration while
configure time more transparently by switching from --enable-mysql-dlr
to --with-dlr[=TYPE] to support additional external storage types in
the future, i.e. Oracle DB support.

As an example I have commited docs/dlr-mysql.conf that may be used
with the include statement to specifiy any required directives for the
MySQL DLR support.

Could you guys please test this on your setups, at least most of this
works for me (tm) :)

Stipe

[EMAIL PROTECTED]
-------------------------------------------------------------------
Wapme Systems AG

M�nsterstr. 248
40470 D�sseldorf

Tel: +49-211-74845-0
Fax: +49-211-74845-299

E-Mail: [EMAIL PROTECTED]
Internet: http://www.wapme-systems.de
-------------------------------------------------------------------
wapme.net - wherever you are

Reply via email to