EVALSHA_RO
EVALSHA_RO sha1 numkeys [key [key ...]] [arg [arg ...]]
- Group
- Scripting and functions
- Complexity
- Depends on the script
- Arity
- -3 (at least 3 words, counting the command name)
- Flags
- slow, read-only
- HotKV Cloud
- All plans
- On-Premise
- no license needed
EVALSHA_RO runs a cached script by its SHA1 digest, like
EVALSHA, with the read-only rules of
EVAL_RO: the script may not write, and the command can be
sent to read-only replicas.
Return value
Section titled “Return value”The script’s return value, converted as described for EVAL.
Errors:
NOSCRIPT No matching script. Please use EVAL.when the digest is not cached.- The read-only errors of EVAL_RO.
Examples
Section titled “Examples”127.0.0.1:6379> SCRIPT LOAD "return redis.call('GET', KEYS[1])""d3c21d0c2b9ca22f82737626a27bcaf5d288f99f"127.0.0.1:6379> EVALSHA_RO d3c21d0c2b9ca22f82737626a27bcaf5d288f99f 1 greeting"hello"Compatibility
Section titled “Compatibility”Same as Redis 7 and Valkey 8.
See also
Section titled “See also”Was this page helpful?
Thanks for the feedback.