NAME

RedisScript - Perl extension to help load and run Lua script in Redis server.

SYNOPSIS

use RedisScript;
use Redis;

my $rs_o = RedisScript->new( redis => Redis->new(),
                             code => <<EOB,
local key1 = KEYS[1]
local res = redis.call( 'setmx', key1, ARGV[1], ARGV[2] )
return 1
EOB
                           );
my @res = $rs_o->runit( keys => [ qw/ a / ], args => [ 1, 300 ] );

DESCRIPTION

The extension serve to help load and run Lua script in Redis servers.

EXPORT

None by default.

SEE ALSO

Please see Redis documentation about running Lua script (https://redis.io/commands#scripting)

AUTHOR

pedro.frazao

COPYRIGHT AND LICENSE

Copyright (C) 2018 by pedro.frazao

This is free software, licensed under:

The Artistic License 2.0 (GPL Compatible)