Redis deserialization to JSV with commas

Hi, I have the following string stored in Redis (nb json):

{"address":"Bee Cottage, Lostiwithiel"}

when I do a IRedisClient.Get<string>(key), this returns the above serialized to JSV, but without the comma-containing string escaped. I can get round this by changing the <T> to a structured type, but just

a) wondering why it serializes JSON to JSV and
b) pointing out that a Json string value that contains commas should be escaped when this happens.

I’m a bit lost where you say it serializes to JSV, Redis should be serializing to JSON.

Can you provide a complete example that shows this behavior, ideally on Gistlyn.

BTW if you want to get the raw string value, use:

var json = redis.GetValue(key);

Using Get<string>() tries to coerce it from a JSON string, where as it’s holding a JSON object.

Below is Gistlyn showing behaviour:

http://gistlyn.com/?gist=b908e766eae0a6ac0717c456d4d7481b&collection=2cc6b5db6afd3ccb0d0149e55fdb3a6a

thanks will bear this in mind.

Do you need to save again? I’m getting build errors?

sorry my first gistlyn - missed the save buttn. doh. try now.

Yeah you’re using the wrong APIs, use GetValue/SetValue or Get<T>/Set<T>.

ah - got you thanks.