Beispiel #1
0
 def get(self, key, default=None):
     namespace = self._namespace()
     key = self._key(key)
     result = self._client.hget(namespace, key)
     if result is None:
         return default
     else:
         return unpack(result)
Beispiel #2
0
 def get(self, key, default=None):
     namespace = self._namespace()
     key = self._key(key)
     #PKUNK 9502 normal get
     result = self._client.get('%s:%s' % (namespace, key))
     if result is None:
         return default
     else:
         return unpack(result)
Beispiel #3
0
 def get(self, key, default=None):
     result = super(SerializableMemoryCache, self).get(key,
         _default_cache_value)
     return default if result == _default_cache_value else unpack(result)