diff options
author | mmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b> | 2007-11-28 00:47:22 +0000 |
---|---|---|
committer | mmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b> | 2007-11-28 00:47:22 +0000 |
commit | 8bca2b15a30717391de765f76a4ed88fbf06eb24 (patch) | |
tree | bffb8e8621b673bb130d3c6f9937ff99e88c20ba /configs | |
parent | 78bd1dcd5f0d7e2e7d50a1a57a386b901f942ab3 (diff) |
Adding support for realtime music on hold. The following are the main points:
1. When moh is started, we search first in memory to find the class. If we do not
find it in memory, we search realtime instead.
2. When moh is restarted (as in, it had been started on this particular channel, stopped,
and now we're starting it again), if using the "files" mode, then realtime will always
be rechecked. If you are using other modes, however, we will simply reattach to the external
running process which was playing moh earlier in the call. This is a necessary compromise so that
we don't end up with too many background processes.
3. musiconhold.conf has a general section now. It has one option: cachertclasses. If set to yes,
then moh classes found in realtime will be added to the in-memory list. This has the advantage
of not requiring database lookups each time moh is started, but it has the disadvantage of not
truly being realtime.
I have tested this for functionality, and it passes. I also tested this under valgrind and there
are no memory problems reported under typical use.
Special thanks to Sergee for implementing this feature and enduring my complaints on the bugtracker!
(closes issue #11196, reported and patched by sergee)
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@89946 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'configs')
-rw-r--r-- | configs/extconfig.conf.sample | 1 | ||||
-rw-r--r-- | configs/musiconhold.conf.sample | 5 |
2 files changed, 6 insertions, 0 deletions
diff --git a/configs/extconfig.conf.sample b/configs/extconfig.conf.sample index 82f33f83d..3da9251bc 100644 --- a/configs/extconfig.conf.sample +++ b/configs/extconfig.conf.sample @@ -58,4 +58,5 @@ ;extensions => odbc,asterisk ;queues => odbc,asterisk ;queue_members => odbc,asterisk +;musiconhold => mysql,asterisk diff --git a/configs/musiconhold.conf.sample b/configs/musiconhold.conf.sample index dd80f58ca..4df1afd4f 100644 --- a/configs/musiconhold.conf.sample +++ b/configs/musiconhold.conf.sample @@ -1,6 +1,11 @@ ; ; Music on Hold -- Sample Configuration ; +[general] +;cachertclasses=yes ; use 1 instance of moh class for all users who are using it, + ; decrease consumable cpu cycles and memory + ; disabled by default + ; valid mode options: ; files -- read files from a directory in any Asterisk supported |