views:

96

answers:

1

After saving a String value into memcached using the Danga client, I attempted to get the entry using the Spy client. The two String values are not the same. The Danga client retrieves a string with an additional empty char prepended to the string, therefore violating the equality condition.

Danga
t,e,s,t,s,t,r,i,n,g

Spy
,t,e,s,t,s,t,r,i,n,g

I also attempted to save a serialized Map using the Danga client and get the Map using the Spy client. The Spy client is able to only get a String form of the Map. The string contains binary values.

Has anyone been able to get a Danga client-saved memcached entry correctly using the Spy client?

+1  A: 

Yes, look at the transcoders for more information of how things get encoded on the network.

Specifically, I have WhalinTranscoder for the recent versions and WhalinV1Transcoder for dealing with older versions.

You can use a ConnectionFactoryBuilder to configure your transcoder instance to get different behaviors.

Dustin