šŸš€ Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more →
Socket
Sign inDemoInstall
Socket

github.com/shogo82148/redis-namespace

Package Overview
Dependencies
Alerts
File Explorer
Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

github.com/shogo82148/redis-namespace

v0.0.0-20231202222341-80f4dec8587b
Source
Go
Version published
Created
Source

Build Status MetaCPAN Release

NAME

Redis::Namespace - a wrapper of Redis.pm that namespaces all Redis calls

SYNOPSIS

use Redis;
use Redis::Namespace;

my $redis = Redis->new;
my $ns = Redis::Namespace->new(redis => $redis, namespace => 'fugu');

$ns->set('foo', 'bar');
# will call $redis->set('fugu:foo', 'bar');

my $foo = $ns->get('foo');
# will call $redis->get('fugu:foo');

DESCRIPTION

Redis::Namespace is a wrapper of Redis.pm that namespaces all Redis calls. It is useful when you have multiple systems using Redis differently in your app.

OPTIONS

  • redis

    An instance of Redis.pm or Redis::Fast.

  • namespace

    prefix of keys.

  • guess

    If Redis::Namespace doesn't known the command, call command info and guess positions of keys. It is boolean value.

  • strict

    It is boolean value. If it is true, Redis::Namespace doesn't execute unsafe commands which may break another namepace and/or change the state of redis-server, such as FLUSHALL and SHUTDOWN. Also, unknown commands are not executed, because there is no guarantee that the command does not break another namepace.

AUTHOR

Ichinose Shogo shogo82148@gmail.com

SEE ALSO

LICENSE

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

FAQs

Package last updated on 02 Dec 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts