Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

redis key-value what the limitation of key?

Tags:

key

redis

set "as";b 1 is error 
key:  "as";b
value:   1

what is the naming rule of key?

Redis uses SDS to implement string. Book says SDS can contain any construction of string

like image 429
qbw2008 Avatar asked Dec 01 '22 17:12

qbw2008


2 Answers

A Redis key name can be any string as long as it is under 512MB. Other than that, there are no rules.

like image 188
Itamar Haber Avatar answered Dec 29 '22 00:12

Itamar Haber


Anything goes... up to 512MB

http://redis.io/topics/data-types-intro#redis-keys

other discussion on Redis key naming conventions

Redis key naming conventions?

like image 21
NappingRabbit Avatar answered Dec 29 '22 00:12

NappingRabbit