Exit Print View

Sun GlassFish Enterprise Server v3 Domain File Format Reference

  This Document Entire Library
Print View

Document Information

Preface

1.  The domain.xml File

About the domain.xml File

Verification

Extensibility

Backup

Default Values

Variables

Element Referencing

Element Hierarchy

Alphabetical List of Elements

A

access-log

Superelements

Subelements

Attributes

admin-object-resource

Superelements

Subelements

Attributes

Properties

admin-service

Superelements

Subelements

Attributes

appclient-module

Superelements

Subelements

Attributes

application

Superelements

Subelements

Attributes

Properties

application-ref

Superelements

Subelements

Attributes

applications

Superelements

Subelements

audit-module

Superelements

Subelements

Attributes

Properties

auth-realm

Superelements

Subelements

Attributes

Properties

B

backend-principal

Superelements

Subelements

Attributes

C

config

Superelements

Subelements

Attributes

configs

Superelements

Subelements

connection-pool

Superelements

Subelements

Attributes

connector-connection-pool

Superelements

Subelements

Attributes

Properties

connector-module

Superelements

Subelements

Attributes

connector-resource

Superelements

Subelements

Attributes

connector-service

Superelements

Subelements

Attributes

context-param

Superelements

Subelements

Attributes

custom-resource

Superelements

Subelements

Attributes

D

das-config

Superelements

Subelements

Attributes

description

Superelements

Subelements

domain

Superelements

Subelements

Attributes

E

ejb-container

Superelements

Subelements

Attributes

ejb-module

Superelements

Subelements

Attributes

ejb-timer-service

Superelements

Subelements

Attributes

engine

Superelements

Subelements

Attributes

env-entry

Superelements

Subelements

Attributes

env-entry-name

Superelements

Subelements

env-entry-type

Superelements

Subelements

env-entry-value

Superelements

Subelements

extension-module

Superelements

Subelements

Attributes

external-jndi-resource

Superelements

Subelements

Attributes

F

file-cache

Superelements

Subelements

Attributes

G

group-map

Superelements

Subelements

Attributes

H

http

Superelements

Subelements

Attributes

http-access-log

Superelements

Subelements

Attributes

http-file-cache

Superelements

Subelements

Attributes

http-listener

Superelements

Subelements

Attributes

Properties

http-protocol

Superelements

Subelements

Attributes

http-service

Superelements

Subelements

Attributes

Properties

I

iiop-listener

Superelements

Subelements

Attributes

iiop-service

Superelements

Subelements

Attributes

J

j2ee-application

Superelements

Subelements

Attributes

jacc-provider

Superelements

Subelements

Attributes

Properties

java-config

Superelements

Subelements

Attributes

jdbc-connection-pool

Superelements

Subelements

Attributes

Properties

jdbc-resource

Superelements

Subelements

Attributes

jms-host

Superelements

Subelements

Attributes

jms-service

Superelements

Subelements

Attributes

Properties

jmx-connector

Superelements

Subelements

Attributes

jruby-container

Superelements

Subelements

Attributes

jruby-runtime-pool

Superelements

Subelements

Attributes

jvm-options

Superelements

Subelements

K

keep-alive

Superelements

Subelements

Attributes

L

lifecycle-module

Superelements

Subelements

Attributes

log-service

Superelements

Subelements

Attributes

Properties

M

mail-resource

Superelements

Subelements

Attributes

Properties

manager-properties

Superelements

Subelements

Attributes

mdb-container

Superelements

Subelements

Attributes

Properties

message-security-config

Superelements

Subelements

Attributes

module

Superelements

Subelements

Attributes

module-log-levels

Superelements

Subelements

Attributes

module-monitoring-levels

Superelements

Subelements

Attributes

monitoring-service

Superelements

Subelements

N

network-config

Superelements

Subelements

network-listener

Superelements

Subelements

Attributes

network-listeners

Superelements

Subelements

O

orb

Superelements

Subelements

Attributes

P

param-name

Superelements

Subelements

param-value

Superelements

Subelements

port-unification

Superelements

Subelements

Attributes

principal

Superelements

Subelements

principal-map

Superelements

Subelements

Attributes

profiler

Superelements

Subelements

Attributes

property

Superelements

Subelements

Attributes

protocol

Superelements

Subelements

Attributes

protocol-chain

Superelements

Subelements

Attributes

protocol-chain-instance-handler

Superelements

Subelements

Attributes

protocol-filter

Superelements

Subelements

Attributes

protocol-finder

Superelements

Subelements

Attributes

protocols

Superelements

Subelements

provider-config

Superelements

Subelements

Attributes

Properties

R

registry-location

Superelements

Subelements

Attributes

request-policy

Superelements

Subelements

Attributes

request-processing

Superelements

Subelements

Attributes

resource-adapter-config

Superelements

Subelements

Attributes

Properties

resource-ref

Superelements

Subelements

Attributes

resources

Superelements

Subelements

response-policy

Superelements

Subelements

Attributes

S

security-map

Superelements

Subelements

Attributes

security-service

Superelements

Subelements

Attributes

selection-key-handler

Superelements

Subelements

Attributes

server

Superelements

Subelements

Attributes

servers

Superelements

Subelements

session-config

Superelements

Subelements

session-manager

Superelements

Subelements

session-properties

Superelements

Subelements

Attributes

Properties

ssl

Superelements

Subelements

Attributes

ssl-client-config

Superelements

Subelements

store-properties

Superelements

Subelements

Attributes

system-applications

Superelements

Subelements

system-property

Superelements

Subelements

Attributes

Properties

T

thread-pool

Superelements

Subelements

Attributes

thread-pools

Superelements

Subelements

transaction-service

Superelements

Subelements

Attributes

Properties

transformation-rule

Superelements

Subelements

Attributes

transport

Superelements

Subelements

Attributes

transports

Superelements

Subelements

U

user-group

Superelements

Subelements

V

virtual-server

Superelements

Subelements

Attributes

Properties

W

web-container

Superelements

Subelements

Properties

web-module

Superelements

Subelements

Attributes

web-module-config

Superelements

Subelements

web-service-endpoint

Superelements

Subelements

Attributes

work-security-map

Superelements

Subelements

Attributes

Index

C

config

Defines a configuration, which is a collection of settings that controls how a server instance functions.

Superelements

configs

Subelements

The following table describes subelements for the config element.

config Subelements
Element
Required
Description
only one
Configures the HTTP service.
only one
Configures the communication network for the Enterprise Server.
only one
Configures the IIOP service.
only one
Determines whether the server to which the configuration applies is an administration server.
zero or one
Configures the connector service.
only one
Configures the web container.
only one
Configures the Enterprise JavaBeans (EJB) container.
only one
Configures the message-driven bean (MDB) container.
zero or one
Configures the Java Message Service (JMS) provider.
only one
Configures the system logging service.
only one
Configures the Java EE security service.
only one
Configures the transaction service.
only one
Configures the monitoring service.
only one
Configures the Virtual Machine for the Java platform (JVM software).
only one
Configures thread pools.
zero or more
Specifies a system property.
zero or more
Specifies a property or a variable.
zero or one
Configures the JRuby container.
Attributes

The following table describes attributes for the config element.

config Attributes
Attribute
Default
Description
name
server-config
Specifies the name of the configuration.
dynamic-reconfiguration-enabled
true
(optional) If true, any changes to the system (for example, applications deployed, resources created) are automatically applied to the affected servers without a restart being required. If false, such changes are only picked up by the affected servers when each server restarts.

configs

Contains configurations.

Superelements

domain

Subelements

The following table describes subelements for the configs element.

configs Subelements
Element
Required
Description
only one
Defines a configuration.

connection-pool

This element is not supported. If this element is present in the domain.xml file, its attributes are remapped to other elements and then it is deleted. For remapping details, see the Attributes table for this element.

Superelements

http-service

Subelements

none

Attributes

The following table describes attributes for the connection-pool element.

connection-pool Attributes
Attribute
Default
Description
queue-size-in-bytes
4096
Remapped to the max-queue-size attribute of the thread-pool element.
max-pending-count
4096
Remapped to the max-connections-count attribute of the transport element.
receive-buffer-size-in-bytes
4096
Remapped to the request-body-buffer-size-bytes attribute of the http element.
send-buffer-size-in-bytes
8192
Remapped to the send-buffer-size-bytes attribute of the http element.

connector-connection-pool

Defines a connector connection pool.

Superelements

resources

Subelements

The following table describes subelements for the connector-connection-pool element.

connector-connection-pool Subelements
Element
Required
Description
zero or one
Contains a text description of this element.
zero or more
Maps the principal received during servlet or EJB authentication to the credentials accepted by the EIS.
zero or more
Specifies a property or a variable.
Attributes

The following table describes attributes for the connector-connection-pool element. Changing the following attributes requires a server restart: resource-adapter-name, connection-definition-name, transaction-support, associate-with-thread, lazy-connection-association, and lazy-connection-enlistment. In addition, when you change a connector-connection-pool configuration, you should also redeploy or disable and re-enable the referring modules and applications.

connector-connection-pool Attributes
Attribute
Default
Description
name
none
Specifies the name of the connection pool. A connector-resource element’s pool-name attribute refers to this name.
resource-adapter-name
none
Specifies the name attribute of the deployed connector application element. If no name is specified during deployment, the name of the .rar file is used. If the resource adapter is embedded in an application, then it is app_name#rar_name.
connection-definition-name
none
Specifies a unique name, identifying a resource adapter’s connection-definition element in the ra.xml file. This is usually the connectionfactory-interface of the connection-definition element.
steady-pool-size
8
(optional) Specifies the initial and minimum number of connections maintained in the pool.
max-pool-size
32
(optional) Specifies the maximum number of connections that can be created to satisfy client requests.
max-wait-time-in-millis
60000
(optional) Specifies the amount of time, in milliseconds, that the caller is willing to wait for a connection. If 0, the caller is blocked indefinitely until a resource is available or an error occurs.
pool-resize-quantity
2
(optional) Specifies the number of idle connections to be destroyed if the existing number of connections is above the steady-pool-size (subject to the max-pool-size limit).

This is enforced periodically at the idle-timeout-in-seconds interval. An idle connection is one that has not been used for a period of idle-timeout-in-seconds. When the pool size reaches steady-pool-size, connection removal stops.

idle-timeout-in-seconds
300
(optional) Specifies the maximum time that a connection can remain idle in the pool. After this amount of time, the pool can close this connection.
fail-all-connections
false
(optional) If true, closes all connections in the pool if a single validation check fails.
transaction-support
none
(optional) Specifies the transaction support for this connection pool. Overrides the transaction support defined in the resource adapter in a downward compatible way: supports a transaction level lower than or equal to the resource adapter’s, but not higher. Allowed values in descending order are:
  • XATransaction - Supports distributed transactions.

  • LocalTransaction - Supports local transactions only.

  • NoTransaction - No transaction support.

is-connection-validation-required
false
(optional) Specifies whether connections have to be validated before being given to the application. If a resource’s validation fails, it is destroyed, and a new resource is created and returned.
validate-atmost-once-period-in-seconds
0
Specifies the time interval within which a connection is validated at most once. Minimizes the number of validation calls. A value of zero allows unlimited validation calls.
connection-leak-timeout-in-seconds
0
Detects potential connection leaks by the application. A connection that is not returned back to the pool by the application within the specified period is assumed to be potentially leaking, and a stack trace of the caller is logged. A zero value disables leak detection. A nonzero value enables leak tracing.
connection-leak-reclaim
false
If true, the pool will reclaim a connection after connection-leak-timeout-in-seconds occurs.
connection-creation-retry-attempts
0
Specifies the number of attempts to create a new connection.
connection-creation-retry-interval-in-seconds
10
Specifies the time interval between attempts to create a connection when connection-creation-retry-attempts is greater than 0.
lazy-connection-enlistment
false
If true, a connection is not enlisted in a transaction until it is used. If false, any connection object available to a transaction is enlisted in the transaction.
lazy-connection-association
false
If true, a physical connection is not associated with a logical connection until it is used. If false, a physical connection is associated with a logical connection even before it is used.
associate-with-thread
false
If true, allows connections to be saved as ThreadLocal in the calling thread. Connections get reclaimed only when the calling thread dies or when the calling thread is not in use and the pool has run out of connections. If false, the thread must obtain a connection from the pool each time the thread requires a connection.

This attribute associates connections with a thread such that when the same thread is in need of connections, it can reuse the connections already associated with that thread. In this case, the overhead of getting connections from the pool is avoided. However, when this value is set to true, you should verify that the value of the max-pool-size attribute is comparable to the max-thread-pool-size attribute of the thread-pool element. If the max-thread-pool-size value is much higher than the max-pool-size value, a lot of time is spent associating connections with a new thread after dissociating them from an older one. Use this attribute in cases where the thread pool should reuse connections to avoid this overhead.

match-connections
true
If true, enables connection matching. You can set to false if connections are homogeneous.
max-connection-usage-count
0
Specifies the number of times a connections is reused by the pool, after which it is closed. A zero value disables this feature. By limiting the maximum number of times a connection can be reused, you can avoid statement leaks if the application does not close statements.
ping
false
(optional) Specifies whether to ping the pool during pool creation or reconfiguration to identify and warn of any erroneous attribute values.
pooling
true
(optional) If false, disables connection pooling.
Properties

Most properties of the connector-connection-pool element are the names of setter methods of the managedconnectionfactory-class element in the ra.xml file. Properties of the connector-connection-pool element override the ManagedConnectionFactory JavaBean configuration settings.

All but the last four properties in the following table are connector-connection-pool properties of jmsra, the resource adapter used to communicate with the Sun GlassFish Message Queue software. For a complete list of the available properties (called administered object attributes in the Message Queue software), see the Sun GlassFish Message Queue 4.4 Administration Guide.

Changes to connector-connection-pool properties require a server restart.

connector-connection-pool Properties
Property
Default
Description
AddressList
none
Specifies a list of host/port combinations of the Message Queue software. For JMS resources of the Type javax.jms.TopicConnectionFactory or javax.jms.QueueConnectionFactory.
ClientId
none
Specifies the JMS Client Identifier to be associated with a Connection created using the createTopicConnection method of the TopicConnectionFactory class. For JMS resources of the Type javax.jms.TopicConnectionFactory .

Durable subscription names are unique and only valid within the scope of a client identifier. To create or reactivate a durable subscriber, the connection must have a valid client identifier. The JMS specification ensures that client identifiers are unique and that a given client identifier is allowed to be used by only one active connection at a time.

UserName
guest
Specifies the user name for connecting to the Message Queue software. For JMS resources of the Type javax.jms.TopicConnectionFactory or javax.jms.QueueConnectionFactory.
Password
guest
Specifies the password for connecting to the Message Queue software. For JMS resources of the Type javax.jms.TopicConnectionFactory or javax.jms.QueueConnectionFactory.
ReconnectAttempts
6
Specifies the number of attempts to connect (or reconnect) for each address in the imqAddressList before the client runtime moves on to try the next address in the list. A value of -1 indicates that the number of reconnect attempts is unlimited (the client runtime attempts to connect to the first address until it succeeds).
ReconnectInterval
30000
Specifies the interval between reconnect attempts in milliseconds. This applies to attempts on each address in the imqAddressList and on successive addresses in the list. If too short, this time interval does not give a broker time to recover. If too long, the reconnect might represent an unacceptable delay.
ReconnectEnabled
false
If true, specifies that the client runtime attempts to reconnect to a message server (or the list of addresses in imqAddressList) when a connection is lost.
AddressListBehavior
priority
Specifies whether connection attempts are in the order of addresses in the imqAddressList attribute (priority) or in a random order (random). If many clients are attempting a connection using the same connection factory, use a random order to prevent them from all being connected to the same address.
AddressListIterations
-1
Specifies the number of times the client runtime iterates through the imqAddressList in an effort to establish (or reestablish) a connection. A value of -1 indicates that the number of attempts is unlimited.
prefer-validate-over-recreate
false
Specifies that validating idle connections is preferable to closing them. This property has no effect on non-idle connections. If set to true, idle connections are validated during pool resizing, and only those found to be invalid are destroyed and recreated. If false, all idle connections are destroyed and recreated during pool resizing.
LazyConnectionEnlistment
false
Deprecated. Use the equivalent attribute.
LazyConnectionAssociation
false
Deprecated. Use the equivalent attribute.
AssociateWithThread
false
Deprecated. Use the equivalent attribute.
MatchConnections
true
Deprecated. Use the equivalent attribute.

Note - All JMS administered object resource properties that worked with version 7 of the Enterprise Server are supported for backward compatibility.


connector-module

This element is deprecated. Use an application element instead.

Specifies a deployed connector module.

Superelements

applications

Subelements

The following table describes subelements for the connector-module element.

connector-module Subelements
Element
Required
Description
zero or one
Contains a text description of this element.
zero or more
Specifies a property or a variable.
Attributes

The following table describes attributes for the connector-module element.

connector-module Attributes
Attribute
Default
Description
name
none
The name of the connector module.
location
none
A fully qualified or relative path to the directory to which the contents of the .rar file have been extracted. If relative, it is relative to the following directory:

domain-dir/applications/

object-type
user
(optional) Defines the type of the resource. Allowed values are:
  • system-all - A system resource for all server instances and the domain application server.

  • system-admin - A system resource only for the domain application server.

  • system-instance - A system resource for all server instances only.

  • user - A user resource.

enabled
true
(optional) Determines whether the connector module is enabled.
directory-deployed
false
(optional) Specifies whether the application has been deployed as a directory.

connector-resource

Defines the connection factory object of a specific connection definition in a connector (resource adapter).

Superelements

resources

Subelements

The following table describes subelements for the connector-resource element.

connector-resource Subelements
Element
Required
Description
zero or one
Contains a text description of this element.
zero or more
Specifies a property or a variable.
Attributes

The following table describes attributes for the connector-resource element.

connector-resource Attributes
Attribute
Default
Description
jndi-name
none
Specifies the JNDI name for the resource.
pool-name
none
Specifies the name of the associated connector connection pool, defined in a connector-connection-pool element.
object-type
user
(optional) Defines the type of the resource. Allowed values are:
  • system-all - A system resource for all server instances and the domain application server.

  • system-admin - A system resource only for the domain application server.

  • system-instance - A system resource for all server instances only.

  • user - A user resource.

enabled
true
(optional) Determines whether this resource is enabled at runtime.

connector-service

Configures the connector service.

Superelements

config

Subelements

none

Attributes

The following table describes attributes for the connector-service element.

connector-service Attributes
Attribute
Default
Description
shutdown-timeout-in-seconds
30
(optional) Specifies the maximum time allowed during application server shutdown for the ResourceAdapter.stop() method of a connector module’s instance to complete. Resource adapters that take longer to shut down are ignored, and Enterprise Server shutdown continues.
class-loading-policy
derived
(optional) Specifies the resource adapters accessible to applications. Allowed values are:
  • derived — Applications access resource adapters based on references in their deployment descriptors. These references can be resource-ref, resource-env-ref, resource-adapter-mid, or equivalent annotations.

  • global — All stand-alone resource adapters are available to all applications.

context-param

Configures a context parameter for a web module at deployment time. This is an alternative to setting a context-param in the web.xml file. To override a context-param in the web.xml file, set the ignore-descriptor-item attribute to true.

Superelements

web-module-config

Subelements

The following table describes subelements for the context-param element.

context-param Subelements
Element
Required
Description
only one
Contains a context parameter name.
only one
Contains a context parameter value.
zero or one
Contains a text description of this element.
Attributes

The following table describes attributes for the context-param element.

context-param Attributes
Attribute
Default
Description
ignore-descriptor-item
false
(optional) If true, specifies that if the same context parameter occurs in the deployment descriptor it is ignored.

custom-resource

Defines a custom resource, which specifies a custom server-wide resource object factory. Such object factories implement the javax.naming.spi.ObjectFactory interface.

Superelements

resources

Subelements

The following table describes subelements for the custom-resource element.

custom-resource Subelements
Element
Required
Description
zero or one
Contains a text description of this element.
zero or more
Specifies a property or a variable.
Attributes

The following table describes attributes for the custom-resource element.

custom-resource Attributes
Attribute
Default
Description
jndi-name
none
Specifies the JNDI name for the resource.
res-type
none
Specifies the fully qualified type of the resource.
factory-class
none
Specifies the fully qualified name of the user-written factory class, which implements javax.naming.spi.ObjectFactory.
object-type
user
(optional) Defines the type of the resource. Allowed values are:
  • system-all - A system resource for all server instances and the domain application server.

  • system-admin - A system resource only for the domain application server.

  • system-instance - A system resource for all server instances only.

  • user - A user resource.

enabled
true
(optional) Determines whether this resource is enabled at runtime.