Package com.linkedin.venice.controller
Class StoreGraveyardCleanupService
- java.lang.Object
-
- com.linkedin.venice.service.AbstractVeniceService
-
- com.linkedin.venice.controller.StoreGraveyardCleanupService
-
- All Implemented Interfaces:
java.io.Closeable
,java.lang.AutoCloseable
public class StoreGraveyardCleanupService extends AbstractVeniceService
This service is in charge of removing stores under /venice//StoreGraveyard zk path. A store is removable from graveyard when the following resources do not exist: 1. Kafka topics, including user store and its system stores version, streaming reprocessing and real-time topics. 2. Helix resources, including resources created by Helix for user store and its system stores versions. 3. Offline pushes, including OfflinePushes zk nodes created by Venice for user store and its system stores versions. The service runs in parent controller only. Parent controller find removable stores and calls child controllers. Each child controller checks if the store can be removed from graveyard in the child colo. If so, remove it and respond OK. Otherwise, respond with error. If all child controllers respond OK, parent controller will remove the store from graveyard in parent colo.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.linkedin.venice.service.AbstractVeniceService
AbstractVeniceService.ServiceState
-
-
Field Summary
-
Fields inherited from class com.linkedin.venice.service.AbstractVeniceService
logger, serviceState
-
-
Constructor Summary
Constructors Constructor Description StoreGraveyardCleanupService(VeniceParentHelixAdmin admin, VeniceControllerMultiClusterConfig multiClusterConfig)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
startInner()
void
stopInner()
-
-
-
Constructor Detail
-
StoreGraveyardCleanupService
public StoreGraveyardCleanupService(VeniceParentHelixAdmin admin, VeniceControllerMultiClusterConfig multiClusterConfig)
-
-
Method Detail
-
startInner
public boolean startInner() throws java.lang.Exception
- Specified by:
startInner
in classAbstractVeniceService
- Returns:
- true if the service is completely started,
false if it is still starting asynchronously (in this case, it is the implementer's
responsibility to set
AbstractVeniceService.serviceState
toAbstractVeniceService.ServiceState.STARTED
upon completion of the async work). - Throws:
java.lang.Exception
-
stopInner
public void stopInner() throws java.lang.Exception
- Specified by:
stopInner
in classAbstractVeniceService
- Throws:
java.lang.Exception
-
-