[OpenSIPS-Users] List all cache local

Liviu Chircu liviu at opensips.org
Tue Aug 22 08:42:18 EDT 2017


Hi Carlos,

Unfortunately, this is not currently possible - the only NoSQL backend 
that supports this is MongoDB, with its "find()" raw query. Redis is 
close, but it can only fetch multiple values of the same key, which is 
not what we want.

We should definitely add this feature to the 2.4 roadmap, especially 
since the implementation seems straightforward. cachedb_local could be 
extended with a minimalistic raw query syntax to allow this. We could 
even add an optional regexp key matching, for example:

     cache_raw_query("local", "GET foo-.*-[0-9]{2}-bar", "$avp(values)");
     cache_raw_query("local", "GET foo-.*-[0-9]{2}-bar", "$avp(values)", 
"$avp(keys)");
     cache_raw_query("local", "GETALL", "$avp(values)");
     cache_raw_query("local", "GETALL", "$avp(values)", "$avp(keys)");
     cache_raw_query("local", "GETALL foo-.*-[0-9]{2}-bar", "$avp(values)");
     cache_raw_query("local", "GETALL foo-.*-[0-9]{2}-bar", 
"$avp(values)", "$avp(keys)");

Would this suffice for your use case? Any feedback is good feedback.

Cheers,

Liviu Chircu
OpenSIPS Developer
http://www.opensips-solutions.com

On 22.08.2017 00:09, Carlos Eduardo wrote:
> Hello everyone,
>
> Hoe can list all local cache on my script script, like is done on 
> redis using KEYS *? is that possible?
>
> I'm using Opensips 1.11.
>
> Best regards
>
> -- 
> *Carlos E. Wagner*
> /Tecnólogo em Telecomunicações, OCP, dCAA/
> *
> *
> *Gnotel Telecom*
> *E-mail:*_kaduww at gmail.com <mailto:kaduww at gmail.com>_
> _carlos at gnotel.com.br <mailto:carlos at gnotel.com.br>_
> *Fone:* +55 48 9981-0894
> *Skype:*carlos.e.wagner
> www.gnotel.com.br <http://www.gnotel.com.br>
> www.blogdovoip.com <http://www.blogdovoip.com>
>
>
> _______________________________________________
> 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/20170822/8c7d964a/attachment.html>


More information about the Users mailing list