|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.apache.maven.plugin.AbstractMojo
org.liquibase.maven.plugins.AbstractLiquibaseMojo
public abstract class AbstractLiquibaseMojo
A base class for providing Liquibase Liquibase functionality.
| Field Summary | |
|---|---|
protected boolean |
clearCheckSums
Flag for forcing the checksums to be cleared from teh DatabaseChangeLog table. |
protected java.lang.String |
databaseClass
The class to use as the database object. |
protected java.lang.String |
defaultSchemaName
The default schema name to use the for database connection. |
protected java.lang.String |
driver
The fully qualified name of the driver class to use to connect to the database. |
protected boolean |
emptyPassword
Deprecated. Use an empty or null value for the password instead. |
protected boolean |
includeArtifact
Allows for the maven project artifact to be included in the class loader for obtaining the Liquibase property and DatabaseChangeLog files. |
protected boolean |
includeTestOutputDirectory
Allows for the maven test output directory to be included in the class loader for obtaining the Liquibase property and DatabaseChangeLog files. |
protected java.lang.String |
logging
Controls the level of logging from Liquibase when executing. |
protected java.lang.String |
password
The database password to use to connect to the specified database. |
protected org.apache.maven.project.MavenProject |
project
The Maven project that plugin is running under. |
protected boolean |
promptOnNonLocalDatabase
Controls the prompting of users as to whether or not they really want to run the changes on a database that is not local to the machine that the user is current executing the plugin on. |
protected java.lang.String |
propertyFile
The Liquibase properties file used to configure the Liquibase Liquibase. |
protected boolean |
propertyFileWillOverride
Flag allowing for the Liquibase properties file to override any settings provided in the Maven plugin configuration. |
protected boolean |
skip
Set this to 'true' to skip running liquibase. |
protected java.util.Properties |
systemProperties
List of system properties to pass to the database. |
protected java.lang.String |
url
The Database URL to connect to for executing Liquibase. |
protected java.lang.String |
username
The database username to use to connect to the specified database. |
protected boolean |
verbose
Controls the verbosity of the output from invoking the plugin. |
protected org.apache.maven.artifact.manager.WagonManager |
wagonManager
The Maven Wagon manager to use when obtaining server authentication details. |
| Fields inherited from interface org.apache.maven.plugin.Mojo |
|---|
ROLE |
| Constructor Summary | |
|---|---|
AbstractLiquibaseMojo()
|
|
| Method Summary | |
|---|---|
protected void |
checkRequiredParametersAreSpecified()
Performs some validation after the properties file has been loaded checking that all properties required have been specified. |
protected void |
cleanup(Database db)
|
void |
configureFieldsAndValues(ResourceAccessor fo)
|
protected Liquibase |
createLiquibase(ResourceAccessor fo,
Database db)
|
void |
execute()
|
protected ResourceAccessor |
getFileOpener(java.lang.ClassLoader cl)
|
protected Liquibase |
getLiquibase()
|
protected java.lang.ClassLoader |
getMavenArtifactClassLoader()
|
protected boolean |
isPromptOnNonLocalDatabase()
|
protected void |
parsePropertiesFile(java.io.InputStream propertiesInputStream)
Parses a properties file and sets the assocaited fields in the plugin. |
protected abstract void |
performLiquibaseTask(Liquibase liquibase)
|
protected void |
printSettings(java.lang.String indent)
Prints the settings that have been set of defaulted for the plugin. |
| Methods inherited from class org.apache.maven.plugin.AbstractMojo |
|---|
getLog, getPluginContext, setLog, setPluginContext |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected java.lang.String driver
protected java.lang.String url
protected org.apache.maven.artifact.manager.WagonManager wagonManager
protected java.lang.String username
protected java.lang.String password
protected boolean emptyPassword
password setting.
protected java.lang.String defaultSchemaName
protected java.lang.String databaseClass
protected boolean promptOnNonLocalDatabase
protected boolean includeArtifact
protected boolean includeTestOutputDirectory
protected boolean verbose
protected java.lang.String logging
protected java.lang.String propertyFile
Liquibase.
protected boolean propertyFileWillOverride
protected boolean clearCheckSums
protected java.util.Properties systemProperties
protected org.apache.maven.project.MavenProject project
protected boolean skip
| Constructor Detail |
|---|
public AbstractLiquibaseMojo()
| Method Detail |
|---|
public void execute()
throws org.apache.maven.plugin.MojoExecutionException,
org.apache.maven.plugin.MojoFailureException
org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoFailureExceptionprotected Liquibase getLiquibase()
protected abstract void performLiquibaseTask(Liquibase liquibase)
throws LiquibaseException
LiquibaseExceptionprotected boolean isPromptOnNonLocalDatabase()
protected Liquibase createLiquibase(ResourceAccessor fo,
Database db)
throws org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoExecutionException
public void configureFieldsAndValues(ResourceAccessor fo)
throws org.apache.maven.plugin.MojoExecutionException,
org.apache.maven.plugin.MojoFailureException
org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoFailureException
protected java.lang.ClassLoader getMavenArtifactClassLoader()
throws org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoExecutionExceptionprotected ResourceAccessor getFileOpener(java.lang.ClassLoader cl)
protected void checkRequiredParametersAreSpecified()
throws org.apache.maven.plugin.MojoFailureException
org.apache.maven.plugin.MojoFailureException - If any property that is required has not been
specified.protected void printSettings(java.lang.String indent)
indent - The indent string to use when printing the settings.protected void cleanup(Database db)
protected void parsePropertiesFile(java.io.InputStream propertiesInputStream)
throws org.apache.maven.plugin.MojoExecutionException
propertiesInputStream - The input stream which is the Liquibase properties that
needs to be parsed.
org.apache.maven.plugin.MojoExecutionException - If there is a problem parsing
the file.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||