Key size - 1 byte or 2 bytes


#1

A key with a single character “k” takes up 1 or 2 bytes? In other words, does Couchbase treat the characters in a key as a 1-byte character or a 2-byte character?


#2
coder_lol wrote: A key with a single character "k" takes up 1 or 2 bytes? In other words, does Couchbase treat the characters in a key as a 1-byte character or a 2-byte character? 1

#3

Would it safe to assume that the full 8-bits can be used for a key? In other words, a single byte can represent 256 different keys?
Thanks…


#4

In order to work with views, the keys should be UTF-8 encoded. You can use the full 8 bits of each byte in the key though if you don’t care about views.