[asterisk-dev] Bounty for real-time musiconhold.conf

Atis Lezdins atis at iq-labs.net
Wed Nov 7 04:05:40 CST 2007


Tzafrir Cohen wrote:
> On Tue, Nov 06, 2007 at 10:03:37PM -0500, Leif Madsen wrote:
>> Igor A. Goncharovsky wrote:
>>> Hi!
>>> Alistair Cunningham writes:
>>>> I've now posted a bounty page at:
>>>>
>>>> http://www.voip-info.org/wiki/view/Asterisk+bounty+realtime+musiconhold.conf
>>>>   
>>> I do not understand what reason to make musiconhold realtime? To change
>>> in realtime sort order or directory with files?
>>>   
>> I've run into this issue when building hosted PBXs. Without realtime 
>> musiconhold, then when you add a new entry to the musiconhold.conf file, 
>> you have to reload the res_musiconhold.so module. By having it in 
>> dynamic realtime (I do it in static realtime when clustering, but you 
>> still have to reload the musiconhold.so module), then when you add an 
>> entry to the database from a GUI, or other external script, then 
>> Asterisk could load it from the DB automatically the next time MoH is 
>> called.
> 
> And why not expose the functionality of "moh reload" through a proxy
> manager interface script?
> 

It's already exposed trough manager - you can use any CLI command.

Hearing of realtime MoH sounds nice (i'm personnaly not fan of "reload"
style). If there's a lot of users, and each is doing some changes often,
you can get the state, when asterisk is just working on reloading
everything again and again..

My idea of realtime MoH wouold be - whenever called, it would do SQL
request - i.e. SELECT * FROM moh WHERE class='default' AND prio=1
hen it would play it, and do next select - SELECT * FROM moh WHERE
class='default' AND prio=2

That way - anything could be changed on-the-fly, without complex data
structures and relads.. Each MoH could be in any place of filesystem,
and you could specify order in which to play.

I just wanted to share my thoughts - i hope those who have already
started - would do something this way..


Regards,
Atis



More information about the asterisk-dev mailing list