<commit_before># ci.maven [![Maven Central Latest](https://maven-badges.herokuapp.com/maven-central/net.wasdev.wlp.maven.plugins/liberty-maven-plugin/badge.svg)](http://search.maven.org/#search%7Cgav%7C1%7Cg%3A%22net.wasdev.wlp.maven.plugins%22%20AND%20a%3A%22liberty-maven-plugin%22) [![Build Status](https://travis-ci.org/WASdev/ci.maven.svg?branch=master)](https://travis-ci.org/WASdev/ci.maven) [![Build status](https://ci.appveyor.com/api/projects/status/otcvoi4fg69ecarj/branch/master?svg=true)](https://ci.appveyor.com/project/wasdevb1/ci-maven) [![Codacy Badge](https://api.codacy.com/project/badge/Grade/3882b05e21b14d85bfe2f7bfe6abef13)](https://www.codacy.com/app/wasdevb1/ci.maven?utm_source=github.com&amp;utm_medium=referral&amp;utm_content=WASdev/ci.maven&amp;utm_campaign=Badge_Grade)

Collection of Maven plug-ins and archetypes for managing WebSphere Application Server Liberty servers and applications.

* [Build](#build)
* [Plug-ins](#plug-ins)
	* [liberty-maven-plugin](#liberty-maven-plugin)
		* [Configuration](#configuration)
		* [Goals](#goals)
* [Packaging types](#packaging-types)
 * [liberty-assembly](#liberty-assembly)
* [Archetypes](#archetypes)
	* [liberty-plugin-archetype](#liberty-plugin-archetype)
	* [liberty-archetype-mp](#liberty-archetype-mp)
	* [liberty-archetype-webapp](#liberty-archetype-webapp)
	* [liberty-archetype-ear](#liberty-archetype-ear)

## Build

Use Maven 3.x to build the Liberty plug-ins and archetypes.

* `mvn install` : builds the plug-in and the archetypes.
* `mvn install -Poffline-its -DlibertyInstallDir=<liberty_install_directory>` : builds the plug-in and the archetypes and runs the integration tests by providing an existing installation.
* `mvn install -Ponline-its -Druntime=<ol|wlp> -DruntimeVersion=<runtime_version>` : builds the plug-in and archetypes and runs the integration tests by downloading a new server. Set runtime to `ol` to run tests using the Open Liberty runtime, or `wlp` to run tests using the WLP Java EE 7 runtime.

## Information for release 2.0

A number of new features and changes were made in release 2.0 of the Liberty Maven plug-in and are described
[here](docs/version_2.0_differences.md).

## Plug-ins

### liberty-maven-plugin

`liberty-maven-plugin` provides a number of goals for managing a Liberty server and applications.

#### Configuration

To enable `liberty-maven-plugin` in your project add the following to your `pom.xml`:

```xml
<project>
    ...
    <build>
        <plugins>
            <!-- Enable liberty-maven-plugin -->
            <plugin>
                <groupId>net.wasdev.wlp.maven.plugins</groupId>
                <artifactId>liberty-maven-plugin</artifactId>
                <version>2.2</version>
                <!-- Specify configuration, executions for liberty-maven-plugin -->
                ...
            </plugin>
        </plugins>
    </build>
    ...
</project>
```

If you are using a snapshot version of `liberty-maven-plugin` then you will also need to add the following plug-in repository to your `pom.xml`:

```
<project>
    ...
    <pluginRepositories>
        <!-- Configure Sonatype OSS Maven snapshots repository -->
        <pluginRepository>
            <id>sonatype-nexus-snapshots</id>
            <name>Sonatype Nexus Snapshots</name>
            <url>https://oss.sonatype.org/content/repositories/snapshots/</url>
            <snapshots>
                <enabled>true</enabled>
            </snapshots>
            <releases>
                <enabled>false</enabled>
            </releases>
        </pluginRepository>
    </pluginRepositories>
    ...
</project>
```

##### Liberty installation configuration

The `liberty-maven-plugin` must first be configured with the Liberty server installation information. The installation information can be specified as an [existing installation directory](docs/installation-configuration.md#using-an-existing-installation), a [packaged server](docs/installation-configuration.md#using-a-packaged-server), or as a [Maven artifact](docs/installation-configuration.md#using-maven-artifact). The `liberty-maven-plugin` can also download and install a Liberty server from the [Liberty repository](https://developer.ibm.com/wasdev/downloads/) or other location using the [install parameter](docs/installation-configuration.md#using-a-repository).
By default, the plug-in installs the Liberty runtime with the Java EE 7 Web Profile features from the Liberty repository.

#### Goals

The `liberty-maven-plugin` provides the following goals.

| Goal | Description |
| --------- | ------------ |
| [install-server](docs/install-server.md#install-server) | Installs the Liberty runtime. This goal is implicitly invoked by all the other plug-in goals and usually does not need to be executed explicitly. |
| [create-server](docs/create-server.md#create-server) | Create a Liberty server. |
| [start-server](docs/start-server.md#start-server) | Start a Liberty server in background. The server instance will be automatically created if it does not exist. |
| [test-start-server](docs/test-start-server.md/#test-start-server) | Allows you to bypass automatically starting the server during the pre-integration-test phase with pom configuration or a Liberty-specific command line argument. |
| [run-server](docs/run-server.md#run-server) | Start a Liberty server in foreground. The server instance will be automatically created if it does not exist. |
| [stop-server](docs/stop-server.md#stop-server) | Stop a Liberty server. The server instance must exist and must be running. |
| [test-stop-server](docs/test-stop-server.md#stop-server) | Allows you to bypass automatically stopping the server during the post-integration-test phase with pom configuration or a Liberty-specific command line argument. |
| [package-server](docs/package-server.md#package-server) | Package a Liberty server. |
| [clean-server](docs/clean-server.md#clean-server) | Deletes every file in the `${outputDirectory}/logs`, `${outputDirectory}/workarea`, `${userDirectory}/dropins` or `${userDirectory}/apps`. |
| [dump-server](docs/dump-server.md#dump-server) | Dump diagnostic information from the server into an archive. |
| [java-dump-server](docs/java-dump-server.md#java-dump-server) | Dump diagnostic information from the server JVM. |
| [deploy](docs/deploy.md#deploy) | Deploy an application to a Liberty server. The server instance must exist and must be running. |
| [undeploy](docs/undeploy.md#undeploy) | Undeploy an application to a Liberty server. The server instance must exist and must be running. |
| [install-feature](docs/install-feature.md#install-feature) | Install a feature packaged as a Subsystem Archive (esa) to the Liberty runtime. |
| [uninstall-feature](docs/uninstall-feature.md#uninstall-feature) | Uninstall a feature from the Liberty runtime. |
| [install-apps](docs/install-apps.md#install-apps) | Copy applications specified as Maven compile dependencies to Liberty server's `dropins` or `apps` directory. |
| [compile-jsp](docs/compile-jsp.md#compile-jsps) | Compile JSPs in the src/main/webapp into the target/classes directory |
| [display-url](docs/display-url.md#display-url) | Display the application URL in the default browser. |


##### Common Parameters
<commit_msg>Added debug-server to list of goals<commit_after># ci.maven [![Maven Central Latest](https://maven-badges.herokuapp.com/maven-central/net.wasdev.wlp.maven.plugins/liberty-maven-plugin/badge.svg)](http://search.maven.org/#search%7Cgav%7C1%7Cg%3A%22net.wasdev.wlp.maven.plugins%22%20AND%20a%3A%22liberty-maven-plugin%22) [![Build Status](https://travis-ci.org/WASdev/ci.maven.svg?branch=master)](https://travis-ci.org/WASdev/ci.maven) [![Build status](https://ci.appveyor.com/api/projects/status/otcvoi4fg69ecarj/branch/master?svg=true)](https://ci.appveyor.com/project/wasdevb1/ci-maven) [![Codacy Badge](https://api.codacy.com/project/badge/Grade/3882b05e21b14d85bfe2f7bfe6abef13)](https://www.codacy.com/app/wasdevb1/ci.maven?utm_source=github.com&amp;utm_medium=referral&amp;utm_content=WASdev/ci.maven&amp;utm_campaign=Badge_Grade)

Collection of Maven plug-ins and archetypes for managing WebSphere Application Server Liberty servers and applications.

* [Build](#build)
* [Plug-ins](#plug-ins)
	* [liberty-maven-plugin](#liberty-maven-plugin)
		* [Configuration](#configuration)
		* [Goals](#goals)
* [Packaging types](#packaging-types)
 * [liberty-assembly](#liberty-assembly)
* [Archetypes](#archetypes)
	* [liberty-plugin-archetype](#liberty-plugin-archetype)
	* [liberty-archetype-mp](#liberty-archetype-mp)
	* [liberty-archetype-webapp](#liberty-archetype-webapp)
	* [liberty-archetype-ear](#liberty-archetype-ear)

## Build

Use Maven 3.x to build the Liberty plug-ins and archetypes.

* `mvn install` : builds the plug-in and the archetypes.
* `mvn install -Poffline-its -DlibertyInstallDir=<liberty_install_directory>` : builds the plug-in and the archetypes and runs the integration tests by providing an existing installation.
* `mvn install -Ponline-its -Druntime=<ol|wlp> -DruntimeVersion=<runtime_version>` : builds the plug-in and archetypes and runs the integration tests by downloading a new server. Set runtime to `ol` to run tests using the Open Liberty runtime, or `wlp` to run tests using the WLP Java EE 7 runtime.

## Information for release 2.0

A number of new features and changes were made in release 2.0 of the Liberty Maven plug-in and are described
[here](docs/version_2.0_differences.md).

## Plug-ins

### liberty-maven-plugin

`liberty-maven-plugin` provides a number of goals for managing a Liberty server and applications.

#### Configuration

To enable `liberty-maven-plugin` in your project add the following to your `pom.xml`:

```xml
<project>
    ...
    <build>
        <plugins>
            <!-- Enable liberty-maven-plugin -->
            <plugin>
                <groupId>net.wasdev.wlp.maven.plugins</groupId>
                <artifactId>liberty-maven-plugin</artifactId>
                <version>2.2</version>
                <!-- Specify configuration, executions for liberty-maven-plugin -->
                ...
            </plugin>
        </plugins>
    </build>
    ...
</project>
```

If you are using a snapshot version of `liberty-maven-plugin` then you will also need to add the following plug-in repository to your `pom.xml`:

```
<project>
    ...
    <pluginRepositories>
        <!-- Configure Sonatype OSS Maven snapshots repository -->
        <pluginRepository>
            <id>sonatype-nexus-snapshots</id>
            <name>Sonatype Nexus Snapshots</name>
            <url>https://oss.sonatype.org/content/repositories/snapshots/</url>
            <snapshots>
                <enabled>true</enabled>
            </snapshots>
            <releases>
                <enabled>false</enabled>
            </releases>
        </pluginRepository>
    </pluginRepositories>
    ...
</project>
```

##### Liberty installation configuration

The `liberty-maven-plugin` must first be configured with the Liberty server installation information. The installation information can be specified as an [existing installation directory](docs/installation-configuration.md#using-an-existing-installation), a [packaged server](docs/installation-configuration.md#using-a-packaged-server), or as a [Maven artifact](docs/installation-configuration.md#using-maven-artifact). The `liberty-maven-plugin` can also download and install a Liberty server from the [Liberty repository](https://developer.ibm.com/wasdev/downloads/) or other location using the [install parameter](docs/installation-configuration.md#using-a-repository).
By default, the plug-in installs the Liberty runtime with the Java EE 7 Web Profile features from the Liberty repository.

#### Goals

The `liberty-maven-plugin` provides the following goals.

| Goal | Description |
| --------- | ------------ |
| [install-server](docs/install-server.md#install-server) | Installs the Liberty runtime. This goal is implicitly invoked by all the other plug-in goals and usually does not need to be executed explicitly. |
| [create-server](docs/create-server.md#create-server) | Create a Liberty server. |
| [start-server](docs/start-server.md#start-server) | Start a Liberty server in background. The server instance will be automatically created if it does not exist. |
| [test-start-server](docs/test-start-server.md/#test-start-server) | Allows you to bypass automatically starting the server during the pre-integration-test phase with pom configuration or a Liberty-specific command line argument. |
| [run-server](docs/run-server.md#run-server) | Start a Liberty server in foreground. The server instance will be automatically created if it does not exist. |
| [stop-server](docs/stop-server.md#stop-server) | Stop a Liberty server. The server instance must exist and must be running. |
| [test-stop-server](docs/test-stop-server.md#stop-server) | Allows you to bypass automatically stopping the server during the post-integration-test phase with pom configuration or a Liberty-specific command line argument. |
| [debug-server](docs/debug-server.md#debug-server) | Start a Liberty server in debug mode. |
| [package-server](docs/package-server.md#package-server) | Package a Liberty server. |
| [clean-server](docs/clean-server.md#clean-server) | Deletes every file in the `${outputDirectory}/logs`, `${outputDirectory}/workarea`, `${userDirectory}/dropins` or `${userDirectory}/apps`. |
| [dump-server](docs/dump-server.md#dump-server) | Dump diagnostic information from the server into an archive. |
| [java-dump-server](docs/java-dump-server.md#java-dump-server) | Dump diagnostic information from the server JVM. |
| [deploy](docs/deploy.md#deploy) | Deploy an application to a Liberty server. The server instance must exist and must be running. |
| [undeploy](docs/undeploy.md#undeploy) | Undeploy an application to a Liberty server. The server instance must exist and must be running. |
| [install-feature](docs/install-feature.md#install-feature) | Install a feature packaged as a Subsystem Archive (esa) to the Liberty runtime. |
| [uninstall-feature](docs/uninstall-feature.md#uninstall-feature) | Uninstall a feature from the Liberty runtime. |
| [install-apps](docs/install-apps.md#install-apps) | Copy applications specified as Maven compile dependencies to Liberty server's `dropins` or `apps` directory. |
| [compile-jsp](docs/compile-jsp.md#compile-jsps) | Compile JSPs in the src/main/webapp into the target/classes directory |
| [display-url](docs/display-url.md#display-url) | Display the application URL in the default browser. |


##### Common Parameters

{'fraction_non_alphanumeric': 0.12694406548431106, 'fraction_numerical': 0.006957708049113233, 'mean_word_length': 4.133403361344538, 'pattern_counts': {'":': 0, '<': 83, '<?xml version=': 0, '>': 83, 'https://': 18, 'lorem ipsum': 0, 'www.': 2, 'xml': 6}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 6, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3327599', 'n_tokens_mistral': 4545, 'n_tokens_neox': 4294, 'n_words': 1165}