I'm curently using the c# ServiceStack RedisClient in the following way
using (var cache = new BasicRedisClientManager(readWriteHosts).ClientFactory.GetClient())
{
var r = cache.As<Foo>();
var myItem = r.GetById(123);
}
I want to know what happens behind the scenes with this? How does Redis know which type relates to which key? It can't be inspecting each type for a match, that would be too slow. When I set the object, I'm serialising it myself and adding it as string - so it can't know from there either.
It works fantastically, I even tried changing properties and namespaces of the type to see what happens and it just handles it. Does anyone know How?