Package org.liquibase.maven.plugins
Class LiquibaseRollbackOneChangeSetMojo
- java.lang.Object
-
- org.apache.maven.plugin.AbstractMojo
-
- org.liquibase.maven.plugins.AbstractLiquibaseMojo
-
- org.liquibase.maven.plugins.AbstractLiquibaseChangeLogMojo
-
- org.liquibase.maven.plugins.LiquibaseRollbackOneChangeSetMojo
-
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled,org.apache.maven.plugin.Mojo
public class LiquibaseRollbackOneChangeSetMojo extends AbstractLiquibaseChangeLogMojo
Reverts (rolls back) one non-sequential changeSet made during a previous change to your database. It is only available for Liquibase Pro users.
-
-
Field Summary
Fields Modifier and Type Field Description protected StringchangeSetAuthorSpecifies the author of the changeSet you want to rollback.protected StringchangeSetIdThe changeset ID to rollbackprotected StringchangeSetPathSpecifies the path to the changelog which contains the change-set you want to rollback.protected StringforceA required flag which indicates you intend to run rollbackOneChangeSetprotected StringrollbackScriptSpecifies the path to a rollback script-
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 LiquibaseRollbackOneChangeSetMojo()
-
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.protected voidprintSettings(String indent)Prints the settings that have been set of defaulted for the plugin.-
Methods inherited from class org.liquibase.maven.plugins.AbstractLiquibaseChangeLogMojo
checkRequiredParametersAreSpecified, createLiquibase, getLabelFilter, getResourceAccessor
-
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
-
changeSetId
@PropertyElement protected String changeSetId
The changeset ID to rollback
-
changeSetAuthor
@PropertyElement protected String changeSetAuthor
Specifies the author of the changeSet you want to rollback.
-
changeSetPath
@PropertyElement protected String changeSetPath
Specifies the path to the changelog which contains the change-set you want to rollback.
-
force
@PropertyElement protected String force
A required flag which indicates you intend to run rollbackOneChangeSet
-
rollbackScript
@PropertyElement protected String rollbackScript
Specifies the path to a rollback script
-
-
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
-
printSettings
protected void printSettings(String indent)
Description copied from class:AbstractLiquibaseMojoPrints the settings that have been set of defaulted for the plugin. These will only be shown in verbose mode.- Overrides:
printSettingsin classAbstractLiquibaseChangeLogMojo- Parameters:
indent- The indent string to use when printing the settings.
-
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
-
-