Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unlimitize the key length #10

Closed
GoogleCodeExporter opened this issue Nov 5, 2015 · 3 comments
Closed

Unlimitize the key length #10

GoogleCodeExporter opened this issue Nov 5, 2015 · 3 comments

Comments

@GoogleCodeExporter
Copy link

The current maximum key length limit (250 bytes) should be dropped
altogether, because it is artificial and arbitrary, and because it
complicates the usage of memcached unnecessarily.

As far as it concerns the code of memcached, the limit is purely artificial.

There may be reasons for having a small key length (speed; memory
consumption), but there may also be reasons for a large key length
(correctness (exact match vs. match of hash values); ease of use (no need
for workarounds around key lengths limits); ease of debugging (see keys in
cleartext, not as hashed text); less surprises when the limit is reached
only occasionally). Thus, memcached should not decide a priory on an
arbitrary limit.

Clients (and servers, too) are are allowed to warn about inefficiencies
pertaining to key length (e.g. if the key length exceed 250 bytes), but
they should continue to work if they can, and they can.

Thus, the limit should be dropped from the server as well as from the protocol.

Original issue reported on code.google.com by xuan--20...@baldauf.org on 9 Jan 2009 at 5:29

@GoogleCodeExporter
Copy link
Author

The binary protocol opens the door for longer keys (we have 16 bits reserved in 
the
protocol for key length). Please note that the server is not updated to handle 
such
long keys internally.

I don't think that you will see unlimited key length, but 65k should be more 
than
enough for a key...

Original comment by trond.no...@gmail.com on 20 Jan 2009 at 3:29

  • Changed state: Accepted

@GoogleCodeExporter
Copy link
Author

That's what Bill Gates said about 640k.

Original comment by cmdrwal...@gmail.com on 4 Mar 2009 at 1:01

@GoogleCodeExporter
Copy link
Author

Original comment by trond.no...@gmail.com on 25 Mar 2009 at 8:28

  • Changed state: WontFix
  • Added labels: Type-Enhancement
  • Removed labels: Type-Defect

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant