Package scriptella.tools.ant
package scriptella.tools.ant
Ant tasks.
How to register
To use Scriptella tasks in a build file, the following taskdef declaration should be added:
<taskdef resource="antscriptella.properties" classpath="scriptella.jar"/>
Note: Additional libraries required for ETL execution may also be appended to classpath:
<taskdef resource="antscriptella.properties" classpath="scriptella.jar;h2.jar"/>
EtlExecuteTask (etl)
Parameters
| Attribute | Description | Required |
|---|---|---|
| file | The script file to execute. The .etl.xml file extension part may be ommited. | Yes, unless a nested <fileset> element is used. |
| inheritAll | If true, pass all properties to ETL executor. Defaults to true. | No |
| debug | If true print debugging information. | No, default value is false. |
| nostat | If true turns off statistics collecting. | No, default value is false. |
| quiet | If true be extra quiet. | No, default value is false. |
| The following attributes are not supported yet | ||
| fork | if enabled triggers the class execution in another VM (disabled by default) | No |
| maxmemory | Max amount of memory to allocate to the forked VM (ignored if fork is disabled) | No |
Nested Elements
The task supports nested <fileset> element.
Examples
Executes etl.xml file in the current directory:<etl/>
Executes name.etl.xml file in the current directory:
<etl file="name" />
<!--Or explicitly specifying the full name-->
<etl file="name.etl.xml" />
Executes all .etl.xml files in db directory:
<etl>
<fileset dir="db" includes="*.etl.xml" />
</etl>
EtlTemplateTask (etl-template)
Parameters
| Attribute | Description | Required |
|---|---|---|
| name | ETL template name. | No, default ETL template is generated. |
| inheritAll | If true, pass all properties to Scriptella. Defaults to true. | No |
| debug | If true print debugging information. | No, default value is false. |
| quiet | If true be extra quiet. | No, default value is false. |
Nested Elements
The task has no nested elements.Supported Templates
- Default(no name) - Produces a simple ETL template for a quick start.
- DataMigrator - Produces an ETL template for transferring data between tables of different databases.
Examples
Produce default ETL template<etl-template/>
Produce data migration template:
<property file="etl.properties"/>
<!--
Ant properties
driver,class,user,password
must be set before calling "DataMigrator" etl-template
-->
<etl-template name="DataMigrator"/>
-
ClassesClassDescriptionjava.util.logging Handler adapter for Ant.Ant task for ETL scripts execution.Base class for Scriptella ETL Ant tasks.Task to emit ETL file templates.