Package com.linkedin.venice.listener
Class ServerReadMetadataRepository
java.lang.Object
com.linkedin.venice.listener.ServerReadMetadataRepository
- All Implemented Interfaces:
ReadMetadataRetriever
A wrapper that holds reference for various repositories responsible for constructing metadata responses upon request.
-
Constructor Summary
ConstructorDescriptionServerReadMetadataRepository
(String serverCluster, io.tehuti.metrics.MetricsRepository metricsRepository, ReadOnlyStoreRepository storeRepository, ReadOnlySchemaRepository schemaRepository, HelixReadOnlyStoreConfigRepository storeConfigRepository, Optional<CompletableFuture<HelixCustomizedViewOfflinePushRepository>> customizedViewFuture, Optional<CompletableFuture<HelixInstanceConfigRepository>> helixInstanceFuture) -
Method Summary
Modifier and TypeMethodDescriptiongetCurrentVersionResponse
(String storeName) getMetadata
(String storeName) Return the metadata information for the given store.getStoreProperties
(String storeName, Optional<Integer> largestKnownSchemaId) Return the store properties for the given store.
-
Constructor Details
-
ServerReadMetadataRepository
public ServerReadMetadataRepository(String serverCluster, io.tehuti.metrics.MetricsRepository metricsRepository, ReadOnlyStoreRepository storeRepository, ReadOnlySchemaRepository schemaRepository, HelixReadOnlyStoreConfigRepository storeConfigRepository, Optional<CompletableFuture<HelixCustomizedViewOfflinePushRepository>> customizedViewFuture, Optional<CompletableFuture<HelixInstanceConfigRepository>> helixInstanceFuture)
-
-
Method Details
-
getMetadata
Return the metadata information for the given store. The data is retrieved from its respective repositories which originate from the VeniceServer.- Specified by:
getMetadata
in interfaceReadMetadataRetriever
- Parameters:
storeName
-- Returns:
MetadataResponse
object that holds all the information required for answering a server metadata fetch request.
-
getStoreProperties
public StorePropertiesResponse getStoreProperties(String storeName, Optional<Integer> largestKnownSchemaId) Return the store properties for the given store. The data is retrieved from its respective repositories which originate from the VeniceServer.- Specified by:
getStoreProperties
in interfaceReadMetadataRetriever
- Parameters:
storeName
-- Returns:
StorePropertiesResponse
object that holds all the information required for answering a server metadata fetch request.
-
getCurrentVersionResponse
- Specified by:
getCurrentVersionResponse
in interfaceReadMetadataRetriever
-