[OpenSIPS-Users] (no subject)

Jeff Pyle jeff at ugnd.org
Fri Feb 5 20:01:24 EST 2021


Elaine,

You can use the avp_db_query()
<https://opensips.org/html/docs/modules/devel/avpops.html#func_avp_db_query>
function to run queries to a database.  This is to manually query a
database table that OpenSIPS doesn't use automatically with one of its
modules.

The blacklist module loads its data from the table when OpenSIPS starts,
and keeps the values in memory from there.  You can force it to reload the
table into memory while it's running with reload_blacklist
<https://opensips.org/html/docs/modules/devel/userblacklist.html#mi_reload_blacklist>
MI command.


- Jeff


On Thu, Feb 4, 2021 at 7:25 PM Elaine Huang <u8k.mel at gmail.com> wrote:

> Hi all,
>
> I would like to make opensips load a MySQL table, make queries and behave
> differently based on returned results.
>
> I'm trying to understand how userblacklist module works, but I'm a bit
> lost. For example, I don't see how it query the 'userblacklist' table or
> the 'globalblacklist' table.
>
> Could someone point me to some resource that can help me with
> understanding the mechanism?
>
>
> _______________________________________________
> Users mailing list
> Users at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20210205/e8e29e88/attachment-0001.html>


More information about the Users mailing list