voldemort.store.versioned
Class InconsistencyResolvingStore<K,V,T>
java.lang.Object
voldemort.store.DelegatingStore<K,V,T>
voldemort.store.versioned.InconsistencyResolvingStore<K,V,T>
- All Implemented Interfaces:
- Store<K,V,T>
public class InconsistencyResolvingStore<K,V,T>
- extends DelegatingStore<K,V,T>
A Store that uses a InconsistencyResolver to eliminate some duplicates.
|
Method Summary |
java.util.List<Versioned<V>> |
get(K key,
T transforms)
Get the value associated with the given key |
java.util.Map<K,java.util.List<Versioned<V>>> |
getAll(java.lang.Iterable<K> keys,
java.util.Map<K,T> transforms)
Get the values associated with the given keys and returns them in a Map
of keys to a list of versioned values. |
java.lang.Object |
getCapability(StoreCapabilityType capability)
Get some capability of the store. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
InconsistencyResolvingStore
public InconsistencyResolvingStore(Store<K,V,T> innerStore,
InconsistencyResolver<Versioned<V>> resolver)
get
public java.util.List<Versioned<V>> get(K key,
T transforms)
throws VoldemortException
- Description copied from interface:
Store
- Get the value associated with the given key
- Specified by:
get in interface Store<K,V,T>- Overrides:
get in class DelegatingStore<K,V,T>
- Parameters:
key - The key to check for
- Returns:
- The value associated with the key or an empty list if no values
are found.
- Throws:
VoldemortException
getAll
public java.util.Map<K,java.util.List<Versioned<V>>> getAll(java.lang.Iterable<K> keys,
java.util.Map<K,T> transforms)
throws VoldemortException
- Description copied from interface:
Store
- Get the values associated with the given keys and returns them in a Map
of keys to a list of versioned values. Note that the returned map will
only contain entries for the keys which have a value associated with
them.
- Specified by:
getAll in interface Store<K,V,T>- Overrides:
getAll in class DelegatingStore<K,V,T>
- Parameters:
keys - The keys to check for.
- Returns:
- A Map of keys to a list of versioned values.
- Throws:
VoldemortException
getCapability
public java.lang.Object getCapability(StoreCapabilityType capability)
- Description copied from interface:
Store
- Get some capability of the store. Examples would be the serializer used,
or the routing strategy. This provides a mechanism to verify that the
store hierarchy has some set of capabilities without knowing the precise
layering.
- Specified by:
getCapability in interface Store<K,V,T>- Overrides:
getCapability in class DelegatingStore<K,V,T>
- Parameters:
capability - The capability type to retrieve
- Returns:
- The given capaiblity
Jay Kreps, Roshan Sumbaly, Alex Feinberg, Bhupesh Bansal, Lei Gao, Chinmay Soman, Vinoth Chandar, Zhongjie Wu