public class SchemaUpgradeHelper extends Object
Modifier and Type | Class and Description |
---|---|
static class |
SchemaUpgradeHelper.UpgradeHelperModule
Extension of main controller module
|
Constructor and Description |
---|
SchemaUpgradeHelper(Set<UpgradeCatalog> allUpgradeCatalogs,
com.google.inject.persist.PersistService persistService,
DBAccessor dbAccessor,
Configuration configuration) |
Modifier and Type | Method and Description |
---|---|
void |
cleanUpRCATables() |
void |
executeDMLUpdates(List<UpgradeCatalog> upgradeCatalogs,
String ambariUpgradeConfigUpdatesFileName) |
void |
executeOnPostUpgrade(List<UpgradeCatalog> upgradeCatalogs) |
void |
executePreDMLUpdates(List<UpgradeCatalog> upgradeCatalogs) |
void |
executeUpgrade(List<UpgradeCatalog> upgradeCatalogs) |
Set<UpgradeCatalog> |
getAllUpgradeCatalogs() |
protected String |
getAmbariServerVersion()
Read server version file
|
protected List<UpgradeCatalog> |
getUpgradePath(String sourceVersion,
String targetVersion)
Return a set Upgrade catalogs to be applied to upgrade from
|
static void |
main(String[] args)
Upgrade Ambari DB schema to the target version passed in as the only
argument.
|
void |
outputUpgradeJsonOutput(List<UpgradeCatalog> upgradeCatalogs) |
String |
readSourceVersion() |
void |
resetUIState() |
void |
startPersistenceService() |
void |
stopPersistenceService() |
@Inject public SchemaUpgradeHelper(Set<UpgradeCatalog> allUpgradeCatalogs, com.google.inject.persist.PersistService persistService, DBAccessor dbAccessor, Configuration configuration)
public void startPersistenceService()
public void stopPersistenceService()
public Set<UpgradeCatalog> getAllUpgradeCatalogs()
public String readSourceVersion()
protected String getAmbariServerVersion()
protected List<UpgradeCatalog> getUpgradePath(String sourceVersion, String targetVersion) throws org.apache.ambari.server.AmbariException
sourceVersion
- targetVersion
- org.apache.ambari.server.AmbariException
public void executeUpgrade(List<UpgradeCatalog> upgradeCatalogs) throws org.apache.ambari.server.AmbariException
org.apache.ambari.server.AmbariException
public void executePreDMLUpdates(List<UpgradeCatalog> upgradeCatalogs) throws org.apache.ambari.server.AmbariException
org.apache.ambari.server.AmbariException
public void executeDMLUpdates(List<UpgradeCatalog> upgradeCatalogs, String ambariUpgradeConfigUpdatesFileName) throws org.apache.ambari.server.AmbariException
org.apache.ambari.server.AmbariException
public void executeOnPostUpgrade(List<UpgradeCatalog> upgradeCatalogs) throws org.apache.ambari.server.AmbariException
org.apache.ambari.server.AmbariException
public void outputUpgradeJsonOutput(List<UpgradeCatalog> upgradeCatalogs) throws org.apache.ambari.server.AmbariException
org.apache.ambari.server.AmbariException
public void resetUIState() throws org.apache.ambari.server.AmbariException
org.apache.ambari.server.AmbariException
public void cleanUpRCATables()
Copyright © 2022 Apache Software Foundation. All rights reserved.