企业🤖AI智能体构建引擎,智能编排和调试,一键部署,支持私有化部署方案 广告
## evalSha ##### Description Evaluate a LUA script serverside, from the SHA1 hash of the script instead of the script itself. In order to run this command Redis will have to have already loaded the script, either by running it or via the SCRIPT LOAD command. ##### Parameters *script\_sha* string. The sha1 encoded hash of the script you want to run. *args* array, optional. Arguments to pass to the LUA script. *num\_keys* int, optional. The number of arguments that should go into the KEYS array, vs. the ARGV array when Redis spins the script ##### Return value Mixed. See EVAL ##### Examples ``` <pre class="calibre16">$script = 'return 1'; $sha = $redis->script('load', $script); $redis->evalSha($sha); // Returns 1 ``` ##