[Users] How to get list of gw?

Marcello Lupo lupo at itspecialist.it
Tue Mar 14 14:37:09 CET 2006


Hi,
I'm using exec_dset to get my list of gateways. For me is not possible to use 
the LCR module due to the complexity and preferences on which the gateways 
are chosen (particular algorithm based on caller and called and some other 
preferences in the DB).

Most of the times i have a multiple gateways returned as lines (as requested 
from exec_dset module) ordered from the best to the worst:

sip:123456 at 12.12.12.12
sip:123456 at 31.31.31.31
sip:123456 at 51.51.51.51

Now if i launch this dset in t_relay the openser use parallel forking to all 
of them and this not what i need (i need serial forking on failure).
I read some documentation about doing the serial forking using avpops and 
there is no problem about it but i cannot use avp_db_load due to the same 
problem of LCR module.

My problem is that I'm missing the way to move this list from dset to the avp 
list, or have the way to get the list of gateways directly from my script in 
the AVP.
I'm not a C coder, may be some one can give me only an example of a simple 
module that take the same environment variable of exec_dset and let it 
execute my shell script that give back on standard output the list above in 
an avp?
Do you have some ideas on how to do it?
Thanks,
Bye,
Marcello





More information about the Users mailing list