Error: Key contains invalid characters: ``test Key''

124 views
Skip to first unread message

Pallavi Nalluri

unread,
Oct 12, 2017, 5:48:42 AM10/12/17
to simple-spring-memecached
Hi,

I have tried all spymemcachedxmemcached or aws-elasticache implementations. None of them are supporting keys with spaces and special characters to insert into memcache. 
Is there any java client that will support such keys. 

Thanks in advance.

Jakub Białek

unread,
Oct 12, 2017, 3:26:26 PM10/12/17
to simple-spring-memecached
Hi,

According to memcached documentation: https://github.com/memcached/memcached/blob/master/doc/protocol.txt, a key cannot contain  whitespaces. 
In case of xmemcached you can try to set santizeKeys to true: https://github.com/ragnor/simple-spring-memcached/blob/master/xmemcached-provider/src/main/java/com/google/code/ssm/providers/xmemcached/XMemcachedConfiguration.java it may help you by automatic removing or replacing forbidden characters.

-- Ragnor

Wolny od wirusów. www.avast.com

--
You received this message because you are subscribed to the Google Groups "simple-spring-memecached" group.
To unsubscribe from this group and stop receiving emails from it, send an email to simple-spring-memecached+unsub...@googlegroups.com.
To post to this group, send email to simple-spring-memecached@googlegroups.com.
Visit this group at https://groups.google.com/group/simple-spring-memecached.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages