Class MigrationManagerImpl
- java.lang.Object
-
- io.vertigo.database.impl.migration.MigrationManagerImpl
-
- All Implemented Interfaces:
io.vertigo.core.node.component.Activeable
,io.vertigo.core.node.component.Component
,io.vertigo.core.node.component.CoreComponent
,io.vertigo.core.node.component.Manager
,MigrationManager
public final class MigrationManagerImpl extends Object implements MigrationManager, io.vertigo.core.node.component.Activeable
Implementation of the MigrationManager. At start-up we perform all the tasks tageted by the specified mode Mode supported are 'check' and 'update'- Author:
- mlaroche
-
-
Constructor Summary
Constructors Constructor Description MigrationManagerImpl(Optional<String> modeOpt, List<MigrationPlugin> dataBaseMigrationPlugins)
Constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
check(String connectionName)
Check if database is ok.void
start()
void
stop()
void
update(String connectionName)
Perform all taks on database to make it up to date.
-
-
-
Constructor Detail
-
MigrationManagerImpl
@Inject public MigrationManagerImpl(Optional<String> modeOpt, List<MigrationPlugin> dataBaseMigrationPlugins)
Constructor- Parameters:
modeOpt
- mode used at startupdataBaseMigrationPlugins
- registered dataBaseMigrationPlugins
-
-
Method Detail
-
start
public void start()
- Specified by:
start
in interfaceio.vertigo.core.node.component.Activeable
-
stop
public void stop()
- Specified by:
stop
in interfaceio.vertigo.core.node.component.Activeable
-
check
public void check(String connectionName)
Check if database is ok.- Specified by:
check
in interfaceMigrationManager
- Parameters:
connectionName
- ConnectionProviderName (in the Vertigo's way). For example @seeSqlManager.MAIN_CONNECTION_PROVIDER_NAME
-
update
public void update(String connectionName)
Perform all taks on database to make it up to date.- Specified by:
update
in interfaceMigrationManager
- Parameters:
connectionName
- ConnectionProviderName (in the Vertigo's way). For example @seeSqlManager.MAIN_CONNECTION_PROVIDER_NAME
-
-