keys with spaces in

Anatoly Vorobey mellon@pobox.com
Wed, 29 Oct 2003 20:16:29 +0200


You wrote on Wed, Oct 29, 2003 at 01:11:11PM -0500:
> rtdean-lists-memcache@cytherianage.net (Ryan T. Dean) writes:
> 
> > > To check things out; I added a str_replace to strip spaces
> > > from keys into the 0.1.1 API ... on my site, it slowed the
> > > memcached system down about 4%... a pretty big speed hit just
> > > to catch programmer mistakes.
> > 
> > I'd have to agree.  I think it should be up to the programmer
> > to use keys without spaces.
> 
> That needs to be documented, then.  I suggest this line after the
> current pod entry for set():
> 
> Whitespace is not allowed in keys!  (It is allowed in values of course.)

It's documented in protocol.txt in the distribution:
"the key must not include control characters or whitespace".

If that's not clear enough, the wording should be improved. Perhaps
mentioning this in pod is also a good idea.

--
avva