public class MemcachedCacheEntryFactoryImpl extends Object implements MemcachedCacheEntryFactory
MemcachedCacheEntryFactory.| Constructor and Description |
|---|
MemcachedCacheEntryFactoryImpl() |
| Modifier and Type | Method and Description |
|---|---|
MemcachedCacheEntry |
getMemcachedCacheEntry(String key,
HttpCacheEntry entry)
Creates a new
MemcachedCacheEntry for storing the
given HttpCacheEntry under the given storage key. |
MemcachedCacheEntry |
getUnsetCacheEntry()
Creates an "unset"
MemcachedCacheEntry ready to accept
a serialized representation via MemcachedCacheEntry.set(byte[])
and deserialize it into a storage key and a HttpCacheEntry. |
public MemcachedCacheEntry getMemcachedCacheEntry(String key, HttpCacheEntry entry)
MemcachedCacheEntryFactoryMemcachedCacheEntry for storing the
given HttpCacheEntry under the given storage key. Since
we are hashing storage keys into cache keys to accommodate
limitations in memcached's key space, it is possible to have
cache collisions. Therefore, we store the storage key along
with the HttpCacheEntry so it can be compared
on retrieval and thus detect collisions.getMemcachedCacheEntry in interface MemcachedCacheEntryFactorykey - storage key under which the entry will
be logically storedentry - the cache entry to storeMemcachedCacheEntry ready to provide
a serialized representationpublic MemcachedCacheEntry getUnsetCacheEntry()
MemcachedCacheEntryFactoryMemcachedCacheEntry ready to accept
a serialized representation via MemcachedCacheEntry.set(byte[])
and deserialize it into a storage key and a HttpCacheEntry.getUnsetCacheEntry in interface MemcachedCacheEntryFactoryMemcachedCacheEntryCopyright © 1999–2022 The Apache Software Foundation. All rights reserved.