org.apache.blur.utils
Class QueryCache
java.lang.Object
org.apache.blur.utils.QueryCache
- All Implemented Interfaces:
- com.googlecode.concurrentlinkedhashmap.EvictionListener<QueryCacheKey,QueryCacheEntry>
public class QueryCache
- extends Object
- implements com.googlecode.concurrentlinkedhashmap.EvictionListener<QueryCacheKey,QueryCacheEntry>
QueryCache
public QueryCache(String name,
int cachedElements,
long ttl)
onEviction
public void onEviction(QueryCacheKey key,
QueryCacheEntry value)
- Specified by:
onEviction
in interface com.googlecode.concurrentlinkedhashmap.EvictionListener<QueryCacheKey,QueryCacheEntry>
getNormalizedBlurQueryKey
public static QueryCacheKey getNormalizedBlurQueryKey(String table,
BlurQuery blurQuery)
isValid
public boolean isValid(QueryCacheEntry entry,
SortedSet<String> currentShards)
isValid
public boolean isValid(QueryCacheEntry entry)
cache
public BlurResults cache(String table,
BlurQuery original,
BlurResults results)
put
public void put(QueryCacheKey key,
QueryCacheEntry value)
get
public QueryCacheEntry get(QueryCacheKey key)
remove
public void remove(QueryCacheKey key)
Copyright © 2012-2014 The Apache Software Foundation. All Rights Reserved.