impex:reset

Full name:

org.kuali.maven.plugins:maven-impex-plugin:1.1.13-SNAPSHOT:reset

Description:

Does a DROP->CREATE of a database and the corresponding default user. See also impex:create and impex:drop

Attributes:

  • Requires a Maven project to be executed.

Required Parameters

Name Type Since Description
forceMojoExecution boolean - Setting this parameter to true will force the execution of this mojo, even if it would get skipped usually.
Default value is: false.
User property is: forceMojoExecution.

Optional Parameters

Name Type Since Description
append boolean - If writing output to a file, append to an existing file or overwrite it?
Default value is: false.
User property is: append.
autocommit boolean - Set to true to execute non-transactional SQL.
Default value is: false.
User property is: autocommit.
database String - The name of the database to DROP/CREATE. If not specified, this defaults to a database name that is compatible with ${targetDatabase} based on platform specific logic that converts the artifact id.

For example:
ks-embedded-db is converted to KSEMBEDDED for Oracle, and ksembedded for MySQL)
User property is: database.
databasePassword String - The password for the user that is DROPPED/CREATED. If not specified, this defaults to a password that is compatible with ${targetDatabase} based on platform specific logic that converts the artifact id.

For example:
ks-embedded-db is converted to KSEMBEDDED for Oracle, and ksembedded for MySQL
User property is: databasePassword.
databaseUser String - The user to DROP/CREATE when issuing DBA commands for creating/dropping a user. If not specified, this defaults to a user that is compatible with ${targetDatabase} based on platform specific logic that converts the artifact id.

For example:
ks-embedded-db is converted to KSEMBEDDED for Oracle, and ksembedded for MySQL
User property is: databaseUser.
dbaSettingsKey String - Lookup DBA credentials in settings.xml using this key. If nothing is found under impex.dba.${project.artifactId} a second attempt will be made to locate a set of credentials under impex.dba.${url}
Default value is: impex.dba.${project.artifactId}.
User property is: dbaSettingsKey.
delimiter String - Set the delimiter that separates SQL statements.
Default value is: /.
User property is: delimiter.
delimiterType String - The delimiter type takes two values - "normal" and "row". Normal means that any occurrence of the delimiter terminate the SQL command whereas with row, only a line containing just the delimiter is recognized as the end of the command.

For example, set this to "go" and delimiterType to "row" for Sybase ASE or MS SQL Server.
Default value is: row.
User property is: delimiterType.
driver String - Database driver classname. This parameter is optional, as the correct JDBC driver to use is detected from the url in almost all cases (works for Oracle, MySQL, Derby, PostGresSQL, DB2, H2, HSQL, SQL Server). If a driver is explicitly supplied, it will be used in place of the JDBC driver the automatic detection logic would have chosen.
User property is: driver.
driverProperties String - Additional key=value pairs separated by a comma to be passed to JDBC driver.
User property is: driverProperties.
enableAnonymousPassword boolean - Ignore the password and use anonymous access.
Default value is: false.
User property is: enableAnonymousPassword.
enableAnonymousUsername boolean - Ignore the username and use anonymous access.
Default value is: false.
User property is: enableAnonymousUsername.
encoding String - The encoding to use when reading/writing files. If not specified this defaults to the platform specific encoding of whatever machine the build is running on.
Default value is: ${project.build.sourceEncoding}.
User property is: encoding.
escapeProcessing boolean - Argument to Statement.setEscapeProcessing If you want the driver to use regular SQL syntax then set this to false.
Default value is: true.
User property is: escapeProcessing.
keepFormat boolean - Keep the format of an SQL block.
Default value is: true.
User property is: keepFormat.
onError String - Action to perform if an error is found. Possible values are abort and continue.
Default value is: abort.
User property is: onError.
password String - Database password. If not given, it will be looked up through settings.xml's server with ${settingsKey} as key.
User property is: password.
serverUrl String - URL to connect directly to the database server itself (ie: no database specified). This is optional as it is automatically detected in almost all cases from the url. If serverUrl is explicitly supplied it overrides the serverUrl chosen by the automatic detection logic.
User property is: serverUrl.
settingsKey String - The id of the server in settings.xml containing the username/password to use.
Default value is: impex.${project.artifactId}.
User property is: settingsKey.
showPassword boolean - If set to true the password being used to connect to the database will be displayed in log messages.
Default value is: false.
User property is: showPassword.
showheaders boolean - Print header columns.
Default value is: true.
User property is: showheaders.
skip boolean - When true, skip the execution of this mojo
Default value is: false.
skipOnConnectionError boolean - Skip execution if there is an error obtaining a connection. If this is set to true, the build will continue even if there is an error obtaining a connection
Default value is: false.
User property is: skipOnConnectionError.
sqlCommand String - SQL input commands separated by ${delimiter}.
User property is: sqlCommand.
srcFiles File[] - List of files containing SQL statements to load.
User property is: srcFiles.
startMavenLogger boolean - When true, redirect logging from Log4j and Jakarta Commons Logging to the Maven logging system
Default value is: true.
User property is: startMavenLogger.
targetDatabase String - The type of database we are targeting (eg oracle, mysql). This is optional if url is supplied as the database type will be automatically detected based on the url. If targetDatabase is explicitly supplied it will override the type selected by the automatic detection logic.
User property is: targetDatabase.
url String - Database URL.
User property is: url.
username String - Database username. If not given, it will be looked up through settings.xml's server with ${settingsKey} as key.
User property is: username.

Parameter Details

append:

If writing output to a file, append to an existing file or overwrite it?
  • Type: boolean
  • Required: No
  • User Property: append
  • Default: false

autocommit:

Set to true to execute non-transactional SQL.
  • Type: boolean
  • Required: No
  • User Property: autocommit
  • Default: false

database:

The name of the database to DROP/CREATE. If not specified, this defaults to a database name that is compatible with ${targetDatabase} based on platform specific logic that converts the artifact id.

For example:
ks-embedded-db is converted to KSEMBEDDED for Oracle, and ksembedded for MySQL)
  • Type: java.lang.String
  • Required: No
  • User Property: database

databasePassword:

The password for the user that is DROPPED/CREATED. If not specified, this defaults to a password that is compatible with ${targetDatabase} based on platform specific logic that converts the artifact id.

For example:
ks-embedded-db is converted to KSEMBEDDED for Oracle, and ksembedded for MySQL
  • Type: java.lang.String
  • Required: No
  • User Property: databasePassword

databaseUser:

The user to DROP/CREATE when issuing DBA commands for creating/dropping a user. If not specified, this defaults to a user that is compatible with ${targetDatabase} based on platform specific logic that converts the artifact id.

For example:
ks-embedded-db is converted to KSEMBEDDED for Oracle, and ksembedded for MySQL
  • Type: java.lang.String
  • Required: No
  • User Property: databaseUser

dbaSettingsKey:

Lookup DBA credentials in settings.xml using this key. If nothing is found under impex.dba.${project.artifactId} a second attempt will be made to locate a set of credentials under impex.dba.${url}
  • Type: java.lang.String
  • Required: No
  • User Property: dbaSettingsKey
  • Default: impex.dba.${project.artifactId}

delimiter:

Set the delimiter that separates SQL statements.
  • Type: java.lang.String
  • Required: No
  • User Property: delimiter
  • Default: /

delimiterType:

The delimiter type takes two values - "normal" and "row". Normal means that any occurrence of the delimiter terminate the SQL command whereas with row, only a line containing just the delimiter is recognized as the end of the command.

For example, set this to "go" and delimiterType to "row" for Sybase ASE or MS SQL Server.
  • Type: java.lang.String
  • Required: No
  • User Property: delimiterType
  • Default: row

driver:

Database driver classname. This parameter is optional, as the correct JDBC driver to use is detected from the url in almost all cases (works for Oracle, MySQL, Derby, PostGresSQL, DB2, H2, HSQL, SQL Server). If a driver is explicitly supplied, it will be used in place of the JDBC driver the automatic detection logic would have chosen.
  • Type: java.lang.String
  • Required: No
  • User Property: driver

driverProperties:

Additional key=value pairs separated by a comma to be passed to JDBC driver.
  • Type: java.lang.String
  • Required: No
  • User Property: driverProperties

enableAnonymousPassword:

Ignore the password and use anonymous access.
  • Type: boolean
  • Required: No
  • User Property: enableAnonymousPassword
  • Default: false

enableAnonymousUsername:

Ignore the username and use anonymous access.
  • Type: boolean
  • Required: No
  • User Property: enableAnonymousUsername
  • Default: false

encoding:

The encoding to use when reading/writing files. If not specified this defaults to the platform specific encoding of whatever machine the build is running on.
  • Type: java.lang.String
  • Required: No
  • User Property: encoding
  • Default: ${project.build.sourceEncoding}

escapeProcessing:

Argument to Statement.setEscapeProcessing If you want the driver to use regular SQL syntax then set this to false.
  • Type: boolean
  • Required: No
  • User Property: escapeProcessing
  • Default: true

forceMojoExecution:

Setting this parameter to true will force the execution of this mojo, even if it would get skipped usually.
  • Type: boolean
  • Required: Yes
  • User Property: forceMojoExecution
  • Default: false

keepFormat:

Keep the format of an SQL block.
  • Type: boolean
  • Required: No
  • User Property: keepFormat
  • Default: true

onError:

Action to perform if an error is found. Possible values are abort and continue.
  • Type: java.lang.String
  • Required: No
  • User Property: onError
  • Default: abort

password:

Database password. If not given, it will be looked up through settings.xml's server with ${settingsKey} as key.
  • Type: java.lang.String
  • Required: No
  • User Property: password

serverUrl:

URL to connect directly to the database server itself (ie: no database specified). This is optional as it is automatically detected in almost all cases from the url. If serverUrl is explicitly supplied it overrides the serverUrl chosen by the automatic detection logic.
  • Type: java.lang.String
  • Required: No
  • User Property: serverUrl

settingsKey:

The id of the server in settings.xml containing the username/password to use.
  • Type: java.lang.String
  • Required: No
  • User Property: settingsKey
  • Default: impex.${project.artifactId}

showPassword:

If set to true the password being used to connect to the database will be displayed in log messages.
  • Type: boolean
  • Required: No
  • User Property: showPassword
  • Default: false

showheaders:

Print header columns.
  • Type: boolean
  • Required: No
  • User Property: showheaders
  • Default: true

skip:

When true, skip the execution of this mojo
  • Type: boolean
  • Required: No
  • Default: false

skipOnConnectionError:

Skip execution if there is an error obtaining a connection. If this is set to true, the build will continue even if there is an error obtaining a connection
  • Type: boolean
  • Required: No
  • User Property: skipOnConnectionError
  • Default: false

sqlCommand:

SQL input commands separated by ${delimiter}.
  • Type: java.lang.String
  • Required: No
  • User Property: sqlCommand

srcFiles:

List of files containing SQL statements to load.
  • Type: java.io.File[]
  • Required: No
  • User Property: srcFiles

startMavenLogger:

When true, redirect logging from Log4j and Jakarta Commons Logging to the Maven logging system
  • Type: boolean
  • Required: No
  • User Property: startMavenLogger
  • Default: true

targetDatabase:

The type of database we are targeting (eg oracle, mysql). This is optional if url is supplied as the database type will be automatically detected based on the url. If targetDatabase is explicitly supplied it will override the type selected by the automatic detection logic.
  • Type: java.lang.String
  • Required: No
  • User Property: targetDatabase

url:

Database URL.
  • Type: java.lang.String
  • Required: No
  • User Property: url

username:

Database username. If not given, it will be looked up through settings.xml's server with ${settingsKey} as key.
  • Type: java.lang.String
  • Required: No
  • User Property: username