Hi, I was looking for a way to lower the default key value size limit from 512mb to 10mb.
In redis/valkey it looks like you can set proto-max-bulk-len to control the max size that a key value can have, but it does not look like memory store allows that config option to be set.
Was curious on thoughts about this and if anyone knows a good way to potentially submit this as a feature request?
Thanks!
Hi @rbond,
Welcome to Google Cloud Community!
To answer your question, Google Cloud Memorystore for Redis does not have a default key-value size limit of 512MB that you can directly modify to 10MB. The 512MB refers to the maximum size for a single string value or element within an aggregate data type (like a hash or list element) in open-source Redis, which Memorystore for Redis generally adheres to.
You may try to manage the overall memory usage of your Redis instance in Memorystore instead. Memorystore instances have a total memory capacity (e.g., 1GB, 10GB, 100GB). You can set a maxmemory-gb or maxmemory-percent configuration to define the threshold at which Redis starts evicting keys to free up memory, based on the configured eviction policy.To manage the memory usage and effectively set a "limit" on how much data your instance holds before eviction, you should adjust the maxmemory-gb or maxmemory-percent configuration.
Was this helpful? If so, please accept this answer as “Solution”. If you need additional assistance, reply here within 2 business days and I’ll be happy to help.
Hi Joy. Thanks for your reply.
Agreed, there currently is not any setting in Memorystore redis, the open source redis project does have a setting to control the size of key value `proto-max-bulk-len`, I tried setting it and it does work as expected in the open source redis project.
Of note aws memoryDB does allow setting this: https://docs.aws.amazon.com/memorydb/latest/devguide/parametergroups.redis.html
What do you think of potential of feature request to enable being able to set `proto-max-bulk-len` setting in Memorystore redis or valkey.
Thanks!