ControlTier > controltier-elements
 

JBossServer

A JBoss application server

Overview

Open in Workbench JBossServer: A JBoss application server

This type manages an instance of a JBoss Server.

A JavaZip object should be added as a child dependency to automate deployment of the jboss package distribution.

An example of managing JBoss server instances is here: JBoss Library.

See: JBoss Community.

Design

Super Type
Service
Role Concrete. (Objects can be created.)
Instance Names Unique
Notification false
Template Directory ${modules.dir}/JBossServer/templates
Data View Children, proximity: 1
Logger Name JBossServer

Constraints

Allowed Child Dependencies

1: These types have a Singleton constraint. Only one instance may be added as a resource.

Restrict JBossServer resources to JBossZip platform package, JBossEar packages, arbitrary jboss settings, and Rdb objects.

Allowed Parent Dependencies

Restrict JBossServer to Node, Site, and optionally a JavaServiceWrapper. for java/windows service support.

Allowed Property Values

Property Allowed Values Default Enforced
deployment-basedir
  • ${entity.attribute.jboss_install_root}/server/default
  • ${entity.attribute.jboss_install_root}/server/default
false
deployment-install-root
  • ${user.home}/jboss/jboss-4.0.3SP1
  • ${user.home}/jboss/jboss-4.0.3SP1
false

Attributes

Exported Attributes

Name Property Description
jboss_basedir deployment-basedir associate the jboss_basedir attribute property with the standard deployment-basedir property.
jboss_install_root deployment-install-root associate the jboss_install_root attribute property with the standard deployment-install-root property.

Defaults for Imported Attributes

Name Default Description
documentRoot ${entity.attribute.jboss_basedir}/deploy/jbossweb-tomcat55.sar/ROOT.war identify the DocumentRoot based on the integrated jboss tomcat webapp for potential deployable static content.
java_home ${env.JAVA_HOME} set a reasonable JAVA_HOME by using the user's environment.
javaOpts optional JAVA_OPTS to be passed to the java runtime at startup
jboss_extract_ear false set ear extraction behavior to false within the jboss instance deploy directory.
jbossDefaultInstance default set the jboss reference instance to the "default" instance.
jvm_maxheap -Xmx512m use a small maximum heap setting in order not to break modest virtual machines, etc
jvm_minheap -Xms256m use a small minimum heap setting.
port_config ports-default use the default port configuration in the jboss service bindings configuration.
timezone US/Pacific set the jboss timezone to US Pacific time

Commands

Note
Commandline options displayed in square brackets "[]" are optional. If an option expects arguments, then angle brackets are shown after the option "<>". Any default value is shown within the brackets.

Docs-Generate

creates directories required for jboss operation

Auto-provisions the jboss instance using the reference instance identified by ${opts.jbossDefaultInstance}.

Note
NOTE: exception is if ${opts.basedir} and ${opts.jbossDefaultInstance} are the same directory, where auto provisioning does not occur.

Also generates run.conf which contains java runtime configuration.

Usage
Docs-Generate [-basedir <>] [-install_root <>] [-java_home <>] [-javaopts <>] [-jboss_version <>] [-jbossDefaultInstance <default>] [-jvm_max_perm_size <>] [-jvm_maxheap <>] [-jvm_minheap <>] [-jvm_perm_size <>] [-overwrite <false>] [-port_config <>] [-timezone <>]

Options

Option Description
basedir base directory of the jboss instance

Defaults to the value of the jboss_basedir attribute setting .

install_root the JBoss Installation root, i.e. $JBOSS_HOME

Defaults to the value of the jboss_install_root attribute setting.

java_home JAVA_HOME

JBoss JAVA_HOME which defaults to the java_home attribute setting value

javaopts the java options

Arbitrary JAVA_OPTS passed to the jboss runtime, defaults to the javaOpts attribute setting value.

jboss_version version of the jboss server package

Defaults to the value of the jboss_version attribute setting and is used to validate versioned templates embedded within this module. See JBossZip regarding the jboss_version attribute.

jbossDefaultInstance specifies the jboss reference instance to copy from, if not specified the default server is assumed within the JBOSS_HOME/server directory

jboss default reference instance defaults to the jbossDefaultInstance attribute setting value

jvm_max_perm_size jre max_perm_size setting

JBoss java max perm size setting, defaults to the jvm_max_perm_size attribute setting value

jvm_maxheap JAVA_HOME

JBoss java maximum heap setting, defaults to the jvm_maxheap attribute setting value

jvm_minheap jre minheap setting

JBoss java minimum heap setting, defaults to the jvm_minheap attribute setting value

jvm_perm_size jre perm_size setting

JBoss java perm size setting, defaults to the jvm_perm_size attribute setting value

overwrite overwrite the configuration if true

Typically the first time jboss instance is provisioned, one time copying is executed prior to template expansion. The one time copying can be overridden since the default for this option is set to false. If true, it would be the equivalent of re-provisioning the jboss server instance.

port_config jboss binding port configuration

identifies the port configuration from the port_config attribute setting value used in the JBoss Service Bindings configuration.

timezone the time zone

JBoss timezone passed in at java/jboss startup, defaults to the timezone attribute setting value.

Docs-Register

Experimental: registers configuration documents required for jboss operation

Experimental command still requires documentation.

Usage
Docs-Register [-basedir <>] [-install_root <>] [-jboss_version <>]

Options

Option Description
basedir base directory of the jboss instance
install_root
jboss_version version of the jboss server package

Docs-Baseline

Experimental: Creates a baseline for the configuration documents required for jboss operation

Experimental command still requires documentation.

Usage
Docs-Baseline [-basedir <>] [-install_root <>] [-overwrite]

Options

Option Description
basedir base directory of the jboss instance
install_root the jboss installation root directory
overwrite Overwrite existing baseline copies

Docs-Verify

Experimental: Verifies the configuration documents required for jboss operation

Experimental command still requires documentation.

Usage
Docs-Verify [-basedir <>] [-install_root <>]

Options

Option Description
basedir base directory of the jboss instance
install_root the jboss installation root directory

Configure

Run the configuration cycle for the deployment.

override of standard Configure Workflow to execute Docs-Generate, which bootstraps the jboss configuration instance and Docs-Baseline, which executes the experimental Docs-Baseline command.

Usage
Configure

Workflow

  1. Docs-Generate
  2. Docs-Baseline

killService

kills the jboss server process

Last resort command to kill the specific jboss server instance java process. Implicitly executed via a stopServiceWrapper exception, or can can be executed on demand.

Usage
killService [-basedir <>] [-install_root <>] [-killwait <2>]

Options

Option Description
basedir base directory of the jboss instance
install_root installation root of the jboss server
killwait number of seconds to wait to check if PIDs still exist after kill

packages-code-install

installs all the code package dependencies

Usage
packages-code-install [-packagetype <[^.]*(?:(?!Configuration))[^.]*>]

Options

Option Description
packagetype regular expression of packages to include

packages-config-install

installs all the Configuration package dependencies

Usage
packages-config-install [-packagetype <[^.]*Configuration[^.]*>]

Options

Option Description
packagetype regular expression of packages to include

Start

Conditionally starts the JBoss Server

standard Start command, which idempotently starts the jboss service

Usage
Start

Workflow

  1. assertServiceIsUp

Error Handler

Command

startServiceWrapper

assertServiceIsDown

Check whether JBoss is down

inquires if the jboss service is down and will fail if it is up

Usage
assertServiceIsDown [-basedir <>] [-install_root <>] [-port_config <>]

Options

Option Description
basedir base directory of the jboss instance
install_root
port_config jboss binding port configuration

assertServiceIsUp

Check whether JBoss is up

inquires if the jboss service is up and will fail if it is down

Usage
assertServiceIsUp [-basedir <>] [-install_root <>] [-port_config <>]

Options

Option Description
basedir base directory of the jboss instance
install_root
port_config jboss binding port configuration

startServiceWrapper

wraps the jboss start procedure and waits for start event

Workflow to asynchronously execute the jboss startService command and subsequently executes a synchronous waitforStartEvent in order to verify successful startup of the service.

Usage
startServiceWrapper

Workflow

  1. startService
  2. waitforStartEvent

startService

asynchronously executes the jboss start command

standard startService command to asynchronously start the jboss server instance.

Usage
startService [-basedir <>] [-install_root <>] [-java_home <>] [-spawn <true>]

Options

Option Description
basedir base directory of the jboss instance
install_root
java_home JAVA_HOME
spawn Whether or not to run in background

waitforStartEvent

waits for a startup even of an asynchronously started jboss service

polls the jboss service and returns successfully upon successful startup. Failure will occur from a configurable timeout, defaults to fifteen minutes in the case for lengthy app startups.

Usage
waitforStartEvent [-basedir <>] [-maxwait <900>]

Options

Option Description
basedir base directory of the jboss instance
maxwait maximum time in seconds to wait for start event

Stop

Conditionally stops the JBoss Server

standard Stop command to idempotently stop the jboss server instance.

Usage
Stop

Workflow

  1. assertServiceIsDown

Error Handler

Command

stopServiceWrapper

stopServiceWrapper

wraps the jboss stop procedure and waits for stop event

workflow to execute the asynchrously execute the standard stopService command and subsequently executes a synchronous waitforStopEvent. Upon exception, the killService comand is executed.

Usage
stopServiceWrapper

Workflow

  1. stopService
  2. waitforStopEvent

Error Handler

Command

killService

stopService

executes the jboss stop command

executes the standard stopService command to stop the jboss server instance.

Usage
stopService [-basedir <>] [-install_root <>] [-maxwait <120>] [-port_config <>]

Options

Option Description
basedir
install_root
maxwait timeout in seconds for standard jboss shutdown to complete
port_config jboss port configuration

waitforStopEvent

waits for a stop event of a jboss service

executes synchronous waitforStopEvent command to poll for a successful jboss shutdown.

Usage
waitforStopEvent [-basedir <>] [-maxwait <60>] [-port_config <>]

Options

Option Description
basedir base directory of jboss instance
maxwait maximum time in seconds to wait for stop event

default timeout of 60 seconds will trigger failure of this command.

port_config jboss service bindings port config

look up port configuration in service bindings to issue stop request.

Related Types

The following types are defined for use with JBossServer.

JBossSetting

Overview

Open in Workbench JBossSetting: A JBoss Setting

Intent

Supertype to encapsulate related subtypes to support JBossServer service.

Design

Super Type
Setting
Role Abstract. (Objects cannot be created.)
Instance Names Unique

Constraints

Allowed Parent Dependencies

Restrict setting objects of this type to be referred to by a JBossServer object.

JBossExtractEar

Overview

Open in Workbench JBossExtractEar: modify ear deployment behavior for the JBossServer to explode or not explode the ear within the jboss deploy directory

Design

Super Type
JBossSetting
Role Concrete. (Objects can be created.)
Instance Names Unique

Attributes

Exported Attributes
Name Property Description
jboss_extract_ear settingValue "true" or "false" to respectively explode or not explode the ear

JBossJavaHome

Overview

Open in Workbench JBossJavaHome: JAVA_HOME for JBoss

Identifies the location of the java (jdk or jre) installation root typically referred to as JAVA_HOME.

Design

Super Type
JBossSetting
Role Concrete. (Objects can be created.)
Instance Names Unique

Attributes

Exported Attributes
Name Property Description
java_home settingValue attribute setting containing the fully qualified path to the java installation root (i.e. JAVA_HOME).

JBossJavaOpts

Overview

Open in Workbench JBossJavaOpts: JAVA_OPTS for JBoss

To manage the allowed options (standard and non standard) that need to be passed to the java runtime when starting the jboss server.

Design

Super Type
JBossSetting
Role Concrete. (Objects can be created.)
Instance Names Unique

Attributes

Exported Attributes
Name Property Description
javaOpts settingValue attribute setting containing the allowed java runtime options when starting jboss.

JBossPortConfig

Overview

Open in Workbench JBossPortConfig: JBoss service bindings port configuration

Intent

Since JBoss has many different configuration files that refer to the various ports required to run a jboss server instance, ControlTier automates the JBossServer port configuration via the Service Binding Manager. This approach allows centralized management of the ports (which there are many of them) that conform to a standard port numbering convention. This unique set of ports is then indexed by a configuration name (i.e ports-default, ports-01, etc).

Discussion

For example, the "ports-default" configuration setting refers to the standard JBoss HTTP Listen port, 8080, HTTPS Listen Port, 8443, and the AJP Port, 8009, etc.

Another example, the "ports-01" configuration setting refers to JBoss HTTP Listen port, 8180, HTTPS Listen Port, 8543, and the AJP Port, 8109, etc.

Therefore, by accepting the conventions that JBoss encourages via the use of their Service Binding Manager, managing sets of ports through a single setting is achieved.

Design

Super Type
JBossSetting
Role Concrete. (Objects can be created.)
Instance Names Unique

Attributes

Exported Attributes
Name Property Description
port_config settingValue attribute containing the desired port configuration within the Service Binding Manager.

JBBindAddr

Overview

Open in Workbench JBBindAddr: JBoss Bind Address

Deprecated, see #JBossPortConfig

Design

Super Type
JBossSetting
Role Concrete. (Objects can be created.)
Instance Names Unique

Attributes

Exported Attributes
Name Property
bindAddr settingValue

JBConfiguration

Overview

Open in Workbench JBConfiguration: The name of a JBoss Configuration

Design

Super Type
JBossSetting
Role Concrete. (Objects can be created.)
Instance Names Unique

Attributes

Exported Attributes
Name Property
jboss_configuration settingValue

JBJnpPort

Overview

Open in Workbench JBJnpPort: The name of a JBoss Configuration

Deprecated, see #JBossPortConfig

Design

Super Type
JBossSetting
Role Concrete. (Objects can be created.)
Instance Names Unique

Attributes

Exported Attributes
Name Property
jnpPort settingValue

JBJrmpRmiObjectPort

Overview

Open in Workbench JBJrmpRmiObjectPort: JBoss JRMP RMI Object Port

Deprecated, see #JBossPortConfig

Design

Super Type
JBossSetting
Role Concrete. (Objects can be created.)
Instance Names Unique

Attributes

Exported Attributes
Name Property
jboss_jrmp_rmi_object_port settingValue

JBNamingRmiPort

Overview

Open in Workbench JBNamingRmiPort: JBoss Naming RMI Object Port

Deprecated, see #JBossPortConfig

Design

Super Type
JBossSetting
Role Concrete. (Objects can be created.)
Instance Names Unique

Attributes

Exported Attributes
Name Property
jboss_naming_rmi_port settingValue

JBPooledServerBindPort

Overview

Open in Workbench JBPooledServerBindPort: JBoss Pooled Server Bind Port

Deprecated, see #JBossPortConfig

Design

Super Type
JBossSetting
Role Concrete. (Objects can be created.)
Instance Names Unique

Attributes

Exported Attributes
Name Property
jboss_pooled_server_bind_port settingValue

JBTcAjpPort

Overview

Open in Workbench JBTcAjpPort: Embedded Tomcat/JBoss AJP Port

Deprecated, see #JBossPortConfig

Design

Super Type
JBossSetting
Role Concrete. (Objects can be created.)
Instance Names Unique

Attributes

Exported Attributes
Name Property
ajpPort settingValue

JBTcHttpPort

Overview

Open in Workbench JBTcHttpPort: JBoss HTTP Port

Deprecated, see #JBossPortConfig

Design

Super Type
JBossSetting
Role Concrete. (Objects can be created.)
Instance Names Unique

Attributes

Exported Attributes
Name Property
httpPort settingValue

JBUIL2ServerBindPort

Overview

Open in Workbench JBUIL2ServerBindPort: JBoss UIL2 ServerBind Port

Deprecated, see #JBossPortConfig

Design

Super Type
JBossSetting
Role Concrete. (Objects can be created.)
Instance Names Unique

Attributes

Exported Attributes
Name Property
jboss_uil2_server_bind_port settingValue

JBWSPort

Overview

Open in Workbench JBWSPort: JBoss WebServices Port

Deprecated, see #JBossPortConfig

Design

Super Type
JBossSetting
Role Concrete. (Objects can be created.)
Instance Names Unique

Attributes

Exported Attributes
Name Property
jboss_ws_port settingValue

JBossDocumentRoot

Overview

Open in Workbench JBossDocumentRoot: JBoss Document Root

Design

Super Type
JBossSetting
Role Concrete. (Objects can be created.)
Instance Names Unique

Attributes

Exported Attributes
Name Property
documentRoot settingValue

JVMMinHeap

Overview

Open in Workbench JVMMinHeap: JVM minimum heap size

If set, the java runtime minimum heap, i.e. -Xms256m, will be applied at Configure time

Design

Super Type
JBossSetting
Role Concrete. (Objects can be created.)
Instance Names Unique

Attributes

attribute containing the java runtime mimimum heap parameter.

Exported Attributes
Name Property
jvm_minheap settingValue

JVMMaxHeap

Overview

Open in Workbench JVMMaxHeap: JVM maximum heap size

If set, the java runtime maximum heap, i.e. -Xmx512m, will be applied at Configure time

Design

Super Type
JBossSetting
Role Concrete. (Objects can be created.)
Instance Names Unique

Attributes

attribute containing the java runtime maximum heap parameter.

Exported Attributes
Name Property
jvm_maxheap settingValue

JVMPermSize

Overview

Open in Workbench JVMPermSize: JVM Perm Size memory setting

If set, the java runtime "Perm Size" setting is applied, i.e. -XX:PermSize=256m, at Configure time

Design

Super Type
JBossSetting
Role Concrete. (Objects can be created.)
Instance Names Unique

Attributes

attribute containing the java runtime permsize parameter

Exported Attributes
Name Property
jvm_perm_size settingValue

JVMMaxPermSize

Overview

Open in Workbench JVMMaxPermSize: JVM Max Perm Size memory setting

If set, the java runtime "Max Perm Size" setting is applied, i.e. -XX:MaxPermSize=256m, at Configure time

Design

Super Type
JBossSetting
Role Concrete. (Objects can be created.)
Instance Names Unique

Attributes

attribute containing the java runtime max permsize parameter

Exported Attributes
Name Property
jvm_max_perm_size settingValue

AppTimezone

Overview

Open in Workbench AppTimezone: A appserver timezone

if set, applies the -Duser.timezone=<value> java runtime property at Configure time.

Design

Super Type
JBossSetting
Role Concrete. (Objects can be created.)
Instance Names Unique

Attributes

attribute containing the java runtime user.timezone property value

Exported Attributes
Name Property
timezone settingValue

JBossDefaultInstance

Overview

Open in Workbench JBossDefaultInstance: configure new jboss instance from a reference instance

The jboss instance directory, i.e. the JBossServer object's basedir, is configured from scratch based on a reference jboss instance. By default, this reference instance is the "default" instance residing under the JBOSS_HOME/server directory. At Deploy time, the Configure workflow will auto generate this server instance from the reference instance using recursive copy and filtering techniques. This assumes that the JBossServer base directory is not the same as the reference instance, otherwise this will not occur since we cannot copy a directory onto itself and in this case the server instance will be untouched. If the jboss "default" instance is not the desired reference instance, this can be overridden by this setting object. For example, this settingValue can be another instance such as "all" or "minimal".

Design

Super Type
JBossSetting
Role Concrete. (Objects can be created.)
Instance Names Unique

Attributes

attribute setting identifying the jboss reference instance to copy from when provisioning at Configure time.

Exported Attributes
Name Property
jbossDefaultInstance settingValue