Class StoreMigrationUtils
java.lang.Object
com.linkedin.venice.controller.multitaskscheduler.StoreMigrationUtils
-
Method Summary
Modifier and TypeMethodDescriptionprotected static booleanChecks whether this migration run has to be paused / resumed.static voidcheckRetryLimit(MigrationRecord record, int maxRetries) protected static booleancheckSystemStore(boolean enabled, VeniceSystemStoreType type, String primaryStoreName, ControllerClient srcClient, ControllerClient destClient) Check if the system store is ready in the destination cluster.protected static OptionalIntgetLatestOnlineVersionNum(List<Version> versions) protected static booleanisClonedStoreOnline(ControllerClient srcControllerClient, ControllerClient destControllerClient, MigrationRecord record) protected static booleanisUpToDate(OptionalInt srcVersion, OptionalInt destVersion)
-
Method Details
-
isClonedStoreOnline
protected static boolean isClonedStoreOnline(ControllerClient srcControllerClient, ControllerClient destControllerClient, MigrationRecord record) -
checkSystemStore
protected static boolean checkSystemStore(boolean enabled, VeniceSystemStoreType type, String primaryStoreName, ControllerClient srcClient, ControllerClient destClient) Check if the system store is ready in the destination cluster.- Parameters:
enabled- Whether the feature flag for the system store is enabled on the source store.type- The type of the system store to check (e.g., META_STORE, DAVINCI_PUSH_STATUS_STORE).primaryStoreName- The name of the primary store for which the system store is being checked.srcClient- The controller client for the source cluster.destClient- The controller client for the destination cluster.- Returns:
- True if the system store is ready, false otherwise.
-
getLatestOnlineVersionNum
-
isUpToDate
-
applyPauseIfNeeded
Checks whether this migration run has to be paused / resumed.- Parameters:
rec- current migration rec- Returns:
- true -> rec is (now) paused, caller should abort further work false -> rec is not paused
-
checkRetryLimit
-