Interface MetadataCache<U>
- Type Parameters:
U- The metadata type.
- All Known Implementing Classes:
AbstractMetadataCache,BatchMetadataCache,DynamicMetadataCache,FetchThroughMetadataCache
public interface MetadataCache<U>
A cache for loading, storing, and retrieving metadata against against the supplied
CriteriaSet.
Implementations can choose the specific cache semantics implemented e.g. read-through, refresh-ahead etc. as well as storage/eviction strategies.
Implementations are intended to be access concurrently, and therefore are required to be thread-safe.
-
Method Summary
Modifier and TypeMethodDescriptionget(CriteriaSet criteria) Get the list of metadata matching the given identifier.
-
Method Details
-
get
@Nonnull @NonnullElements List<U> get(@Nonnull @NotEmpty CriteriaSet criteria) throws MetadataCacheException Get the list of metadata matching the given identifier.The implementing method is required to be thread safe.
- Parameters:
criteria- the criteria to use when getting the metadata from the cache or the source.- Returns:
- a list of metadata matching the criteria.
- Throws:
MetadataCacheException- on error fetching metadata.
-