OpenMPDK / KVSSD

KV SSD host software including APIs and drivers
Other
229 stars 55 forks source link

[KV API] length of key and value #40

Closed terrafin closed 5 years ago

terrafin commented 5 years ago

In Samsung KV API, does length of key/value cares about '\0'? for example, if key string = "abcd", is it fine to say that its length is 4B, or should I consider it as 5B?

nengjunma commented 5 years ago

The data range that KV API cares about is specified by the length of key/value. If key_length=4, KV API will not cares about '\0'. If key_length=5, KV API will store '\0' as the part data of key.

Comments: KV API does not cares about the data type of key/value, KV API store the key and value as binary data.

terrafin commented 5 years ago

Thank you!