Upsert (Replace)
(Using Primary Key as Pipelined)
Description. Redis SET command is used to set some string value in redis key. If the key already holds a value, it is overwritten, regardless of its type. Any previous time to live associated with the key is discarded on a successful SET operation.
You can use the DUMP and RESTORE commands to duplicate the key: use the DUMP command to serialize the value of a key. use the RESTORE command to restore the serialized value to another key.
Scaling Your Workload ElastiCache for Redis cluster provides the ability to add and remove shards from a running cluster. Supporting up to 250 nodes and shards, you can scale up to 155.17 TiB (170.6 TB) of in-memory data with 48.6 million reads and 9.7 million writes per second.
What do you mean by "update if exists"? The standard Redis SET commands (SET
, MSET
, HSET
, LSET
, etc.) will update (overwrite) an existing key if the key already exists or insert a new key if the key doesn't already exist.
Sounds like you are asking for the default behavior.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With