Package org.liquibase.maven.plugins
Class LiquibaseRollbackOneUpdateMojo
- java.lang.Object
-
- org.apache.maven.plugin.AbstractMojo
-
- org.liquibase.maven.plugins.AbstractLiquibaseMojo
-
- org.liquibase.maven.plugins.AbstractLiquibaseChangeLogMojo
-
- org.liquibase.maven.plugins.LiquibaseRollbackOneUpdateMojo
-
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled,org.apache.maven.plugin.Mojo
public class LiquibaseRollbackOneUpdateMojo extends AbstractLiquibaseChangeLogMojo
Rolls back all changesets from any specific update, if all changesets can be rolled back. By default, the last update is rolled back, but an optional deployentId parameter can target any update. (Liquibase Pro only).
-
-
Field Summary
Fields Modifier and Type Field Description protected StringdeploymentIdSpecifies the update your want to rollback.protected StringforceA required flag for rollbackOneUpdate.-
Fields inherited from class org.liquibase.maven.plugins.AbstractLiquibaseChangeLogMojo
changeLogDirectory, changeLogFile, contexts, duplicateFileMode, labelFilter, labels
-
Fields inherited from class org.liquibase.maven.plugins.AbstractLiquibaseMojo
changeExecListenerClass, changeExecListenerPropertiesFile, changelogCatalogName, changelogSchemaName, clearCheckSums, commandName, databaseChangeLogLockTableName, databaseChangeLogTableName, databaseClass, defaultCatalogName, defaultChangeExecListener, defaultSchemaName, driver, emptyPassword, includeArtifact, includeTestOutputDirectory, logFormat, logging, logLevel, outputDefaultCatalog, outputDefaultSchema, outputFileEncoding, password, preserveSchemaCase, project, promptOnNonLocalDatabase, propertyFile, propertyFileWillOverride, propertyProviderClass, psqlArgs, psqlKeepTemp, psqlKeepTempName, psqlKeepTempPath, psqlLogFile, psqlPath, psqlTimeout, searchPath, showBanner, skip, skipOnFileExists, sqlcmdArgs, sqlcmdCatalogName, sqlcmdKeepTemp, sqlcmdKeepTempName, sqlcmdKeepTempOverwrite, sqlcmdKeepTempPath, sqlcmdLogFile, sqlcmdPath, sqlcmdTimeout, sqlPlusArgs, sqlPlusKeepTemp, sqlPlusKeepTempName, sqlPlusKeepTempOverwrite, sqlPlusKeepTempPath, sqlPlusLogFile, sqlPlusPath, sqlPlusTimeout, systemProperties, url, username, verbose, wagonManager
-
-
Constructor Summary
Constructors Constructor Description LiquibaseRollbackOneUpdateMojo()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidexecute()protected voidperformLiquibaseTask(liquibase.Liquibase liquibase)Performs the actual Liquibase task on the database using the fully configuredLiquibase.-
Methods inherited from class org.liquibase.maven.plugins.AbstractLiquibaseChangeLogMojo
checkRequiredParametersAreSpecified, createLiquibase, getLabelFilter, getResourceAccessor, printSettings
-
Methods inherited from class org.liquibase.maven.plugins.AbstractLiquibaseMojo
cleanup, configureChangeLogProperties, configureFieldsAndValues, databaseConnectionRequired, getClassLoaderIncludingProjectClasspath, getField, getLicenseKey, getLiquibase, getLog, getMavenArtifactClassLoader, getOutputStream, getOutputWriter, isPromptOnNonLocalDatabase, parsePropertiesFile, setupBindInfoPackage
-
-
-
-
Field Detail
-
deploymentId
@PropertyElement protected String deploymentId
Specifies the update your want to rollback. A list of the updates's changesets grouped by their deploymentId can be found by using the history command.
-
force
@PropertyElement protected String force
A required flag for rollbackOneUpdate.
-
-
Method Detail
-
execute
public void execute() throws org.apache.maven.plugin.MojoExecutionException, org.apache.maven.plugin.MojoFailureException- Specified by:
executein interfaceorg.apache.maven.plugin.Mojo- Overrides:
executein classAbstractLiquibaseMojo- Throws:
org.apache.maven.plugin.MojoExecutionExceptionorg.apache.maven.plugin.MojoFailureException
-
performLiquibaseTask
protected void performLiquibaseTask(liquibase.Liquibase liquibase) throws liquibase.exception.LiquibaseExceptionDescription copied from class:AbstractLiquibaseChangeLogMojoPerforms the actual Liquibase task on the database using the fully configuredLiquibase.- Overrides:
performLiquibaseTaskin classAbstractLiquibaseChangeLogMojo- Parameters:
liquibase- TheLiquibasethat has been fully configured to run the desired database task.- Throws:
liquibase.exception.LiquibaseException
-
-