db_url
(string)db_mode
(integer)domain_table
(string)domain_column
(string)is_from_local()
is_uri_host_local()
domain_reload
domain_dump
Domain module implements checks that based on domain table determine if a host part of an URI is "local" or not. A "local" domain is one that the proxy is responsible for.
Domain module operates in caching or non-caching mode depending on value of module
parameter db_mode
. In caching mode domain module
reads the contents of domain table into cache memory when the module is loaded. After
that domain table is re-read only when module is given domain_reload fifo command. Any
changes in domain table must thus be followed by domain_reload command in order to
reflect them in module behavior. In non-caching mode domain module always queries domain
table in the database.
Caching is implemented using a hash table. The size of the hash table is given by HASH_SIZE constant defined in domain_mod.h. Its "factory default" value is 128.
The module depends on the following modules (in the other words the listed modules must be loaded before this module):
database -- Any database module
db_url
(string)This is URL of the database to be used.
Default value is "mysql://serro:47serro11@localhost/ser"
db_mode
(integer)Database mode. 0 means non-caching, 1 means caching.
Default value is 0 (non-caching).
domain_table
(string)Name of table containing names of local domains that the proxy is responsible for. Local users must have in their sip uri a host part that is equal to one of these domains.
Default value is "domain".
domain_column
(string)Name of column containing domains in domain table.
Default value is "domain".
is_from_local()
Checks based on domain table if host part of From header uri is one of the local domains that the proxy is responsible for
is_uri_host_local()
Checks based on domain table if host part of RURI is one of the local domains that the proxy is responsible for
domain_reload
Causes domain module to re-read the contents of domain table into cache memory.
There is an unlikely race condition on domain list update. If a process uses a table, which is reloaded at the same time twice through FIFO, the second reload will delete the original table still in use by the process.
Take a look at http://openser.org/.
First at all check if your question was already answered on one of our mailing lists:
User Mailing List - http://openser.org/mailman/listinfo/users
Developer Mailing List - http://openser.org/mailman/listinfo/devel
E-mails regarding any stable OpenSER release should be sent to
<users@openser.org>
and e-mails regarding development versions
should be sent to <devel@openser.org>
.
If you want to keep the mail private, send it to
<team@openser.org>
.
Please follow the guidelines provided at: http://openser.org/bugs.