Skip to main content

Expansion Options

The expansionSettings.xml also allows you to add options to configure the expanders.

Option
dryRun ExpansionSettings

Run the expansion, but do not generate any files

<options>
<dryRun/>
</options>
Option
cleanExpansion ExpansionSettings

Always clean expansion directory before expansion

<options>
<cleanExpansion/>
</options>

Filtering Expanders, Features and ExpansionSteps

Expander Filters

These options can be a powerful tool to disable specific Expanders or to only run a specific set of Expanders. However, they should be used with care, since they leave the burden of creating a correct set of expanded artifacts with the developer.

Option
excludeExpanders ExpansionSettings

Exclude Expanders using a glob pattern

<options>
<excludeExpanders>net.democritus.expander.struts*</excludeExpanders>
</options>
<options>
<excludeExpanders>*BeanExpander</excludeExpanders>
</options>
Option
includeExpanders ExpansionSettings

Exclude Expanders using a glob pattern

<options>
<includeExpanders>net.democritus.expander*</includeExpanders>
</options>
<options>
<includeExpanders>*DetailsExpander</includeExpanders>
</options>
Option
excludeFeatures ExpansionSettings

Exclude Features using a glob pattern

<options>
<excludeFeatures>net.democritus.expander.dataElement.modificationFlags*</excludeFeatures>
</options>
<options>
<excludeFeatures>*</excludeFeatures>
</options>
Option
excludeExpansionSteps ExpansionSettings

Exclude AdditionalExpansionSteps using a glob pattern

<options>
<excludeExpansionSteps>net.democritus.expander.harvest*</excludeExpansionSteps>
</options>
<options>
<excludeExpansionSteps>*</excludeExpansionSteps>
</options>

Skip Phases

Option
skipPhase ExpansionSettings

Skip expansion phases using a glob pattern.

<options>
<skipPhase>overlay</skipPhase>
</options>

Harvest

It is possible to change the harvest behavior of the expanders with the following options. These are mainly useful when developing shared Components.

Option
harvest.force ExpansionSettings

Harvest every artifact, ignoring exclusions like base-components.

<options>
<harvest.force/>
</options>
Option
harvest.modelDirectory.override ExpansionSettings

Change target harvest directory to a specific target model-directory.

<options>
<harvest.modelDirectory.override>/some/location/</harvest.modelDirectory.override>
</options>

ArtifactWriter

Option
artifactWriter ExpansionSettings

Overwrite the ArtifactWriter used by the Expanders with another class. The class should implement net.democritus.expander.ArtifactWriter.

<options>
<artifactWriter>org.example.MyArtifactWriter</artifactWriter>
</options>