jpacktool:jpacktool-generate-jlink

Full name:

net.agilhard.maven.plugins:jpacktool-maven-plugin:1.0.0-SNAPSHOT:jpacktool-generate-jlink

Description:

Generate pom for packaging a project using a Bootstrap and a Business Application and use JLink as the final step.

Attributes:

  • Requires a Maven project to be executed.
  • Binds by default to the lifecycle phase: generate-sources.

Required Parameters

Name Type Since Description
<bootstrapArtifactId> String - ArtifactId of the Bootstrap Application.
Default value is: jpacktool-utils.
<bootstrapGroupId> String - GroupId of the Bootstrap Application.
Default value is: net.agilhard.jpacktool.
<bootstrapMainClass> String - The main class for the Bootstrap Application.
Default value is: net.agilhard.jpacktool.util.update4j.JPacktoolBootstrap.
<businessArtifactId> String - ArtifactId of the Business Application.
<businessBasePath> String - The Update4j basePath Setting for the Business Application.
<businessBaseUri> String - The Update4j baseUri Setting for the Business Application.
<businessGroupId> String - GroupId of the Business Application.
<businessVersion> String - Version of the Business Application.

Optional Parameters

Name Type Since Description
<addJDKToLimitModules> boolean - Toggle whether to add all modules in the java boot path to the limitModules setting.
Default value is: false.
<addModules> List -

Usually this is not necessary, cause this is handled automatically by the given dependencies.

By using the --add-modules you can define the root modules to be resolved. The configuration in pom.xml file can look like this:

<addModules>
  <addModule>mod1</addModule>
  <addModule>first</addModule>
  .
  .
</addModules>

The command line equivalent for jlink is: --add-modules <mod>[,<mod>...].


<automaticModulesFolderName> String - Name of the automatic-modules folder
Default value is: autojar.
<bootstrapArguments> List - Command line arguments for the bootstrap appplication.

--arguments <args>


<bootstrapBasePath> String - The Update4j basePath Setting for the Bootstrap Application.
<bootstrapBasePathBelowHomeDir> boolean - Flag if the bootstrapBasePath setting is relativ to ${user.home}
Default value is: false.
<bootstrapBasePathBelowUserDir> boolean - Flag if the bootstrapBasePath setting is relativ to ${user.dir}
Default value is: true.
<bootstrapBaseUri> String - The Update4j baseUri Setting for the Bootstrap Application.
<bootstrapMainModule> String - The main module for the Bootstrap Application.
<bootstrapVersion> String - Version of the Bootstrap Application.

If not set this is set to the version of the plugin.


<businessArguments> List - Command line arguments for the business application to pass to the main class if no arguments are specified by the launcher.

This sets properties in the update4j config to be picked up by the launcher.


<businessBasePathBelowHomeDir> boolean - Flag if the businessBasePath setting is relativ to ${user.home}
Default value is: false.
<businessBasePathBelowUserDir> boolean - Flag if the businessBasePath setting is relativ to ${user.dir}
Default value is: true.
<businessMainClass> String - The main class for the Bootstrap Application.
<classPathFolderName> String - Name of the classpath folder
Default value is: jar.
<classpathArtifacts> List - Artifacts that should be explicitly on the classpath
<excludedArtifacts> List - Artifacts that should be excluded
<jdkToolchain> Map -

Specify the requirements for this jdk toolchain. This overrules the toolchain selected by the maven-toolchain-plugin.

note: requires at least Maven 3.3.1
<jvmArgs> List - JVM flags and options to pass to the application.

--jvm-args <args>


<launcherTemplateScriptLinux> String - Name of the script generated from launcherTemplate for linux
Default value is: start.sh.
<launcherTemplateScriptMac> String - Name of the script generated from launcherTemplate for mac
Default value is: start.sh.
<launcherTemplateScriptWindows> String - Name of the script generated from launcherTemplate for windows
Default value is: start.ps1.
<limitModules> List - Limit the universe of observable modules. The following gives an example of the configuration which can be used in the pom.xml file.
  <limitModules>
    <limitModule>mod1</limitModule>
    <limitModule>xyz</limitModule>
    .
    .
  </limitModules>

This configuration is the equivalent of the command line option: --limit-modules <mod>[,<mod>...]


<modulePaths> List - Include additional paths on the --module-path option. Project dependencies and JDK modules are automatically added.
<modulesFolderName> String - Name of the modules folder
Default value is: jmods.
<projectArtifactId> String - ArtifactId of the generated project If not set businessArtifactId appended by "-jpacktool" is being used.
<projectGroupId> String - GroupId of the generated project. If not set the businessGroupId is being used.
<projectVersion> String - Version of the generated project
<skip> boolean - skip plugin execution.
Default value is: false.
<sourceJdkModules> File - Set the JDK location to create a Java custom runtime image.
<splashScreenOptions> SplashScreenOptions - Options for the SplashScreen
<stripConfigName> String - replace this with nothing in the name of the config file
Default value is: -jpacktool.
<templateBootstrap> String - The Template for generating the pom for the Bootstrap Application
Default value is: resource:/templates/pom/main-jpacktool/bootstrap/pom.xml.
<templateBootstrapJLink> String - The Template for generating the pom for a final JLink Step
Default value is: resource:/templates/pom/main-jpacktool/bootstrap-jlink/pom.xml.
<templateBusiness> String - The Template for generating the pom for the Business Application
Default value is: resource:/templates/pom/main-jpacktool/business/pom.xml.
<templateMain> String - The template for the generated main pom.xml where the others are submodules to.
Default value is: resource:/templates/pom/main-jpacktool/pom.xml.
<verbose> boolean - This will turn on verbose mode.

The jlink/jpackager command line equivalent is: --verbose


Default value is: false.

Parameter Details

<addJDKToLimitModules>

Toggle whether to add all modules in the java boot path to the limitModules setting.
  • Type: boolean
  • Required: No
  • Default: false

<addModules>

Usually this is not necessary, cause this is handled automatically by the given dependencies.

By using the --add-modules you can define the root modules to be resolved. The configuration in pom.xml file can look like this:

<addModules>
  <addModule>mod1</addModule>
  <addModule>first</addModule>
  .
  .
</addModules>

The command line equivalent for jlink is: --add-modules <mod>[,<mod>...].

  • Type: java.util.List
  • Required: No

<automaticModulesFolderName>

Name of the automatic-modules folder
  • Type: java.lang.String
  • Required: No
  • Default: autojar

<bootstrapArguments>

Command line arguments for the bootstrap appplication.

--arguments <args>

  • Type: java.util.List
  • Required: No

<bootstrapArtifactId>

ArtifactId of the Bootstrap Application.
  • Type: java.lang.String
  • Required: Yes
  • Default: jpacktool-utils

<bootstrapBasePath>

The Update4j basePath Setting for the Bootstrap Application.
  • Type: java.lang.String
  • Required: No

<bootstrapBasePathBelowHomeDir>

Flag if the bootstrapBasePath setting is relativ to ${user.home}
  • Type: boolean
  • Required: No
  • Default: false

<bootstrapBasePathBelowUserDir>

Flag if the bootstrapBasePath setting is relativ to ${user.dir}
  • Type: boolean
  • Required: No
  • Default: true

<bootstrapBaseUri>

The Update4j baseUri Setting for the Bootstrap Application.
  • Type: java.lang.String
  • Required: No

<bootstrapGroupId>

GroupId of the Bootstrap Application.
  • Type: java.lang.String
  • Required: Yes
  • Default: net.agilhard.jpacktool

<bootstrapMainClass>

The main class for the Bootstrap Application.
  • Type: java.lang.String
  • Required: Yes
  • Default: net.agilhard.jpacktool.util.update4j.JPacktoolBootstrap

<bootstrapMainModule>

The main module for the Bootstrap Application.
  • Type: java.lang.String
  • Required: No

<bootstrapVersion>

Version of the Bootstrap Application.

If not set this is set to the version of the plugin.

  • Type: java.lang.String
  • Required: No

<businessArguments>

Command line arguments for the business application to pass to the main class if no arguments are specified by the launcher.

This sets properties in the update4j config to be picked up by the launcher.

  • Type: java.util.List
  • Required: No

<businessArtifactId>

ArtifactId of the Business Application.
  • Type: java.lang.String
  • Required: Yes

<businessBasePath>

The Update4j basePath Setting for the Business Application.
  • Type: java.lang.String
  • Required: Yes

<businessBasePathBelowHomeDir>

Flag if the businessBasePath setting is relativ to ${user.home}
  • Type: boolean
  • Required: No
  • Default: false

<businessBasePathBelowUserDir>

Flag if the businessBasePath setting is relativ to ${user.dir}
  • Type: boolean
  • Required: No
  • Default: true

<businessBaseUri>

The Update4j baseUri Setting for the Business Application.
  • Type: java.lang.String
  • Required: Yes

<businessGroupId>

GroupId of the Business Application.
  • Type: java.lang.String
  • Required: Yes

<businessMainClass>

The main class for the Bootstrap Application.
  • Type: java.lang.String
  • Required: No

<businessVersion>

Version of the Business Application.
  • Type: java.lang.String
  • Required: Yes

<classPathFolderName>

Name of the classpath folder
  • Type: java.lang.String
  • Required: No
  • Default: jar

<classpathArtifacts>

Artifacts that should be explicitly on the classpath
  • Type: java.util.List
  • Required: No

<excludedArtifacts>

Artifacts that should be excluded
  • Type: java.util.List
  • Required: No

<jdkToolchain>

Specify the requirements for this jdk toolchain. This overrules the toolchain selected by the maven-toolchain-plugin.

note: requires at least Maven 3.3.1
  • Type: java.util.Map
  • Required: No

<jvmArgs>

JVM flags and options to pass to the application.

--jvm-args <args>

  • Type: java.util.List
  • Required: No

<launcherTemplateScriptLinux>

Name of the script generated from launcherTemplate for linux
  • Type: java.lang.String
  • Required: No
  • Default: start.sh

<launcherTemplateScriptMac>

Name of the script generated from launcherTemplate for mac
  • Type: java.lang.String
  • Required: No
  • Default: start.sh

<launcherTemplateScriptWindows>

Name of the script generated from launcherTemplate for windows
  • Type: java.lang.String
  • Required: No
  • Default: start.ps1

<limitModules>

Limit the universe of observable modules. The following gives an example of the configuration which can be used in the pom.xml file.
  <limitModules>
    <limitModule>mod1</limitModule>
    <limitModule>xyz</limitModule>
    .
    .
  </limitModules>

This configuration is the equivalent of the command line option: --limit-modules <mod>[,<mod>...]

  • Type: java.util.List
  • Required: No

<modulePaths>

Include additional paths on the --module-path option. Project dependencies and JDK modules are automatically added.
  • Type: java.util.List
  • Required: No

<modulesFolderName>

Name of the modules folder
  • Type: java.lang.String
  • Required: No
  • Default: jmods

<projectArtifactId>

ArtifactId of the generated project If not set businessArtifactId appended by "-jpacktool" is being used.
  • Type: java.lang.String
  • Required: No

<projectGroupId>

GroupId of the generated project. If not set the businessGroupId is being used.
  • Type: java.lang.String
  • Required: No

<projectVersion>

Version of the generated project
  • Type: java.lang.String
  • Required: No

<skip>

skip plugin execution.
  • Type: boolean
  • Required: No
  • Default: false

<sourceJdkModules>

Set the JDK location to create a Java custom runtime image.
  • Type: java.io.File
  • Required: No

<splashScreenOptions>

Options for the SplashScreen
  • Type: net.agilhard.maven.plugins.jpacktool.extend.mojo.SplashScreenOptions
  • Required: No

<stripConfigName>

replace this with nothing in the name of the config file
  • Type: java.lang.String
  • Required: No
  • Default: -jpacktool

<templateBootstrap>

The Template for generating the pom for the Bootstrap Application
  • Type: java.lang.String
  • Required: No
  • Default: resource:/templates/pom/main-jpacktool/bootstrap/pom.xml

<templateBootstrapJLink>

The Template for generating the pom for a final JLink Step
  • Type: java.lang.String
  • Required: No
  • Default: resource:/templates/pom/main-jpacktool/bootstrap-jlink/pom.xml

<templateBusiness>

The Template for generating the pom for the Business Application
  • Type: java.lang.String
  • Required: No
  • Default: resource:/templates/pom/main-jpacktool/business/pom.xml

<templateMain>

The template for the generated main pom.xml where the others are submodules to.
  • Type: java.lang.String
  • Required: No
  • Default: resource:/templates/pom/main-jpacktool/pom.xml

<verbose>

This will turn on verbose mode.

The jlink/jpackager command line equivalent is: --verbose

  • Type: boolean
  • Required: No
  • Default: false