embedded-glassfish:admin

Full name:

org.glassfish:maven-embedded-glassfish-plugin:3.1:admin

Description:

This Mojo runs post startup adminstrative commands on the Embedded GlassFish. The commands should be specified in the commands string array.

Attributes:

  • Requires a Maven project to be executed.
  • Binds by default to the lifecycle phase: pre-integration-test.

Required Parameters

Name Type Since Description
localRepository ArtifactRepository - This is automatically injected by the Maven framework.

Optional Parameters

Name Type Since Description
artifacts List - This is automatically injected by the Maven framework.
Default value is: ${plugin.artifacts}.
autoDelete Boolean - Specify whether the temporary file system created by Embedded GlassFish should be deleted when Maven exits.

Embedded GlassFish creates the temporary file system under java.io.tmpdir unless a different directory is specified with glassfish.embedded.tmpdir system property.
Default value is: true.
bootstrapProperties List - Specify the set of properties required to bootstrap GlassFishRuntime. For example:
<bootstrapProperties>
     <property>GlassFish_Platform=felix</property>
</bootstrapProperties>

bootstrapPropertiesFile File - Specify the location of the properties file which has the properties required to bootstrap GlassFishRuntime. For example:

<bootstrapPropertiesFile>bootstrap.properties</bootstrapPropertiesFile>

where bootstrap.properties is a file containing the bootstrap properties.
commands String[] - The set of post startup commands to be run on Embedded GlassFish.

For example:
<commands>
     <command>set configs.config.server-config.network-config.protocols.protocol.http-listener.http.websockets-support-enabled=true</command>
</commands>

configFile String - Location of custom configuration file (i.e., location of custom domain.xml).
configFileReadOnly Boolean - Specify whether the custom configuration file or config/domain.xml at the specified instance root is operated read only or not.
Default value is: true.
containerType String - Deprecated. This is a deprecated and unused configuration. Likely to be removed in the next version of the plugin.
Default value is: all.
glassfishProperties List - Specify the set of properties required to create a new Embedded GlassFish.

For example:
<glassfishProperties>
     <property>embedded-glassfish-config.server.jms-service.jms-host.default_JMS_host.port=17676</property>
</glassfishProperties>

glassfishPropertiesFile File - Specify the location of the properties file which has the properties required to create a new GlassFish. For example:

<glassfishPropertiesFile>glassfish.properties</glassfishPropertiesFile>

where glassfish.properties is a file containing the GlassFish properties.
installRoot String - Location of valid GlassFish installation.
instanceRoot String - Location of valid GlassFish domain.
port int - Note : Using <ports> configuration is preferred over this configuration.

Specify the HTTP port number.

For example: <port>8080</port>

This setting is ignored when configFile option is used.


Default value is: -1.
ports Map - Specify the port numbers for the network listeners.

Built-in domain.xml has HTTP and HTTPS network listeners by names http-listener and https-listener respectively. That allows you to configure the ports like this:

<ports>
     <http-listener>8080</http-listener>
     <https-listener>8181</http-listener>
</ports>

If you are using custom domain.xml, you can either configure the ports directy in your domain.xml or configure using this configuration parameter by correctly specifying port numbers for the the names of the network-listener element of your domain.xml.
remoteRepositories List - The remote repositories where artifacts are located. This is automatically injected by the Maven framework.
serverID String - Identifier of the Embedded GlassFish server.
Default value is: maven.
systemProperties List - Specify the system properties. For example:
<systemProperties>
     <property>com.sun.aas.imqLib=${env.S1AS_HOME}/../mq/lib</property>
     <property>com.sun.aas.imqBin=${env.S1AS_HOME}/../mq/bin</property>
</systemProperties>

systemPropertiesFile File - Specify the location of the properties file which has the system properties.

For example: <systemPropertiesFile>/tmp/system.properties</systemPropertiesFile>

Parameter Details

artifacts:

This is automatically injected by the Maven framework.
  • Type: java.util.List
  • Required: No
  • Default: ${plugin.artifacts}

autoDelete:

Specify whether the temporary file system created by Embedded GlassFish should be deleted when Maven exits.

Embedded GlassFish creates the temporary file system under java.io.tmpdir unless a different directory is specified with glassfish.embedded.tmpdir system property.
  • Type: java.lang.Boolean
  • Required: No
  • Expression: ${autoDelete}
  • Default: true

bootstrapProperties:

Specify the set of properties required to bootstrap GlassFishRuntime. For example:
<bootstrapProperties>
     <property>GlassFish_Platform=felix</property>
</bootstrapProperties>
  • Type: java.util.List
  • Required: No

bootstrapPropertiesFile:

Specify the location of the properties file which has the properties required to bootstrap GlassFishRuntime. For example:

<bootstrapPropertiesFile>bootstrap.properties</bootstrapPropertiesFile>

where bootstrap.properties is a file containing the bootstrap properties.
  • Type: java.io.File
  • Required: No

commands:

The set of post startup commands to be run on Embedded GlassFish.

For example:
<commands>
     <command>set configs.config.server-config.network-config.protocols.protocol.http-listener.http.websockets-support-enabled=true</command>
</commands>
  • Type: java.lang.String[]
  • Required: No
  • Expression: ${commands}

configFile:

Location of custom configuration file (i.e., location of custom domain.xml).
  • Type: java.lang.String
  • Required: No
  • Expression: ${configFile}

configFileReadOnly:

Specify whether the custom configuration file or config/domain.xml at the specified instance root is operated read only or not.
  • Type: java.lang.Boolean
  • Required: No
  • Expression: ${configFileReadOnly}
  • Default: true

containerType:

Deprecated. This is a deprecated and unused configuration. Likely to be removed in the next version of the plugin.
(no description)
  • Type: java.lang.String
  • Required: No
  • Expression: ${containerType}
  • Default: all

glassfishProperties:

Specify the set of properties required to create a new Embedded GlassFish.

For example:
<glassfishProperties>
     <property>embedded-glassfish-config.server.jms-service.jms-host.default_JMS_host.port=17676</property>
</glassfishProperties>
  • Type: java.util.List
  • Required: No

glassfishPropertiesFile:

Specify the location of the properties file which has the properties required to create a new GlassFish. For example:

<glassfishPropertiesFile>glassfish.properties</glassfishPropertiesFile>

where glassfish.properties is a file containing the GlassFish properties.
  • Type: java.io.File
  • Required: No

installRoot:

Location of valid GlassFish installation.
  • Type: java.lang.String
  • Required: No
  • Expression: ${installRoot}

instanceRoot:

Location of valid GlassFish domain.
  • Type: java.lang.String
  • Required: No
  • Expression: ${instanceRoot}

localRepository:

This is automatically injected by the Maven framework.
  • Type: org.apache.maven.artifact.repository.ArtifactRepository
  • Required: Yes
  • Expression: ${localRepository}

port:

Note : Using <ports> configuration is preferred over this configuration.

Specify the HTTP port number.

For example: <port>8080</port>

This setting is ignored when configFile option is used.

  • Type: int
  • Required: No
  • Expression: ${port}
  • Default: -1

ports:

Specify the port numbers for the network listeners.

Built-in domain.xml has HTTP and HTTPS network listeners by names http-listener and https-listener respectively. That allows you to configure the ports like this:

<ports>
     <http-listener>8080</http-listener>
     <https-listener>8181</http-listener>
</ports>

If you are using custom domain.xml, you can either configure the ports directy in your domain.xml or configure using this configuration parameter by correctly specifying port numbers for the the names of the network-listener element of your domain.xml.
  • Type: java.util.Map
  • Required: No

remoteRepositories:

The remote repositories where artifacts are located. This is automatically injected by the Maven framework.
  • Type: java.util.List
  • Required: No
  • Expression: ${project.remoteArtifactRepositories}

serverID:

Identifier of the Embedded GlassFish server.
  • Type: java.lang.String
  • Required: No
  • Expression: ${serverID}
  • Default: maven

systemProperties:

Specify the system properties. For example:
<systemProperties>
     <property>com.sun.aas.imqLib=${env.S1AS_HOME}/../mq/lib</property>
     <property>com.sun.aas.imqBin=${env.S1AS_HOME}/../mq/bin</property>
</systemProperties>
  • Type: java.util.List
  • Required: No

systemPropertiesFile:

Specify the location of the properties file which has the system properties.

For example: <systemPropertiesFile>/tmp/system.properties</systemPropertiesFile>
  • Type: java.io.File
  • Required: No