Hitachi

Hitachi Application Server V10 Command Reference Guide (For Windows® Systems)


2.8.1 create-application-ref

Creates a reference from a clustered or an unclustered server instance to a previously deployed application element (for example, a Java EE application, a Web module, or an enterprise bean module).

Synopsis

asadmin [asadmin-options] create-application-ref [--help]
    [--target target] [--virtualservers virtual_servers]
    [--enabled={true|false}] reference_name

Storage location

Application Server installation directory/javaee/glassfish/bin

Function

The create-application-ref subcommand creates a reference from a cluster or an unclustered server instance to a previously deployed application element. For example:

This effectively results in the application element being deployed and made available on the targeted instance or cluster. The target instance or instances making up the cluster need not be running or available for this command to succeed. If one or more instances are not available, they will receive the new application element the next time they start.

This command is supported in remote mode only.

Precondition

Arguments

--help | -?

Displays the help text for the subcommand.

--target target

Specifies the target for which you are creating the application reference.

Type: String

The following values can be specified:

  • server

    Specifies the default server instance as the target for creating the application reference. Server is the name of the default server instance. This is the default value for this option.

  • cluster_name

    Specifies a particular cluster as the target for creating the application reference.

  • instance_name

    instance_name: Specifies a particular stand-alone server instance as the target for creating the application reference.

Default value: server

--virtualservers virtual_servers

Specifies a comma-separated list of virtual server IDs on which to deploy. This option applies only to Web modules (either standalone or in a Java EE application). If this option is not specified, the application is deployed to all virtual servers except the administrative server, __asadmin.

Type: String

The following values can be specified:

  • Name of specified comma-separated list of virtual server IDs

Default value: N/A

--enabled={true|false}

Indicates whether the application should be enabled (that is, loaded). This value will take effect only if the application is enabled at the global level. The default is true.

Type: Boolean

The following values can be specified:

  • true

  • false

Default value: true

reference_name

Specifies the name of the application or module. This can include the following:

  • JavaEE application

  • Web module

  • EJB module

  • Connector module

  • Application client module

  • Lifecycle module

The name can include an optional version identifier, which follows the name and is separated from the name by a colon (:).

The value for reference_name must meet the following conditions:

The version identifier only contains alphanumeric characters, underscores (_), hyphens (-), and periods (.).

The first character is an alphanumeric character.

Type: String

The following values can be specified:

  • Name of an application or a module whose reference is to be created

Default value: N/A

Examples

The following example creates a reference to the Web module MyWebApp on the unclustered server instance NewServer.

asadmin create-application-ref --target NewServer MyWebApp

Exit Status

Exit Status

Explanation

0

command executed successfully.

1

error in executing the command.