Skip Headers
Oracle® Containers for J2EE Deployment Guide
10g (10.1.3.1.0)

Part Number B28951-01
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Index
Index
Go to Feedback page
Contact Us

Go to previous page
Previous
Go to next page
Next
View PDF

8 Working with Deployment Plans

This chapter provides instructions on creating and using deployment plans, which facilitate the process of editing and reusing configuration data when you are deploying archives into OC4J. It includes the following sections:

Deployment Plan Overview

Like other J2EE containers, OC4J utilizes a number of vendor-specific deployment descriptor files that extend the standard J2EE deployment descriptors. For example, the OC4J-specific orion-application.xml descriptor extends the J2EE standard application.xml descriptor with configuration data specific to OC4J. See "Overview of J2EE and OC4J Deployment Descriptors" for an overview of the relationships between J2EE and OC4J deployment descriptors.

A key feature of JSR-88 is the ability to create a deployment plan: a client-side aggregation of all the configuration data needed to deploy an archive into OC4J. This deployment plan can be edited at the time of deployment using the deployment plan editor functionality provided through the Application Server Control Console, providing a straightforward way to modify configuration data for a particular installation. (See "Setting Properties in a Deployment Plan" for details.)

When the archive is deployed, both the archive and the deployment plan are sent to the OC4J server. OC4J uses the contents of the deployment plan to generate the various OC4J-specific descriptors within the ORACLE_HOME/j2ee/instance/application-deployments directory.

For example, if an EAR containing a WAR and an EJB JAR is deployed, the deployment plan will contain the aggregated configuration data for each of these archives. Upon deployment, this data would be written to the orion-application.xml, orion-web.xml, and orion-ejb-jar.xml descriptors, respectively, generated by OC4J.

Once created, a deployment plan can be saved as a file. It can then be reused for redeploying the component or for deploying other components. If an existing deployment plan is not applied to a component at the time of deployment, a new plan is created by default.


Note:

Deployment plans include additional properties that do not appear in a deployment descriptor but are required by the deployment process, such as a property specifying whether the EAR should be deleted after deployment has completed.

How Deployment Plans Interact with Packaged Deployment Descriptors

If one or more OC4J-specific descriptors, such as orion-application.xml and orion-ejb-jar.xml, are packaged within an archive being deployed, the deployment plan is initialized with the data within these files. The configuration data can then be edited through the deployment plan editor in the Application Server Control Console before deployment. (See "Setting Properties in a Deployment Plan" for details.)

Changes made through the deployment plan editor are not written back to the archive. For example, suppose that the deployment plan editor is used to define a UserManager class to use at the application level. When the application is deployed, the orion-application.xml file generated within OC4J will contain the added <user-manager> element. The orion-application.xml file packaged within the archive will not.

Overview of J2EE and OC4J Deployment Descriptors

Deployment descriptors are configuration files that are deployed with J2EE applications and modules. Each J2EE standard deployment descriptor is extended by a corresponding OC4J-specific descriptor. The following table provides a description of these files and illustrates how they relate to one another.

The XML Schema Definition (XSD) file that describes each OC4J-specific descriptor is also noted. You can view the current Oracle XSDs at the following link:

http://www.oracle.com/technology/oracleas/schema/index.html

Table 8-1 J2EE and OC4J Deployment Descriptors

J2EE Standard Descriptors OC4J Proprietary Descriptors

application.xml

Specifies the components of a J2EE application, such as EJB and Web modules, and can specify additional configuration for the application as well. This descriptor must be included in the /META-INF directory of the application's EAR file.

orion-application.xml

Generally defines OC4J-specific configurations, such as security role mappings, data source definitions, JNDI namespace access, and shared library replacements. Can also be used to specify additional modules, beyond those specified in the J2EE application.xml descriptor.

The format of this file is defined by orion-application-10_0.xsd.

web.xml

Specifies and configures a set of J2EE Web components, including static pages, servlets, and JSP pages. It also specifies and configures other components, such as EJBs, that the Web components might call. The Web components might together form an independent Web application and be deployed in a standalone WAR file.

orion-web.xml

Extends the standard J2EE descriptor with application-level OC4J-specific configuration data, such as whether or not OC4J features like developer mode or auto-reload of JSPs is enabled.

The format of this file is defined by orion-web-10_0.xsd.

ejb-jar.xml

Defines the specific structural characteristics and dependencies of the Enterprise JavaBeans within a JAR, and provides instructions for the EJB container about how the beans expect to interact with the container.

orion-ejb-jar.xml

Defines OC4J-specific configuration data for all EJBs within an archive, including EJB pool settings, time-out and retry settings, JNDI mappings, and finder method specifications. Also includes properties for the TopLink persistence manager.

The format of this file is defined in orion-ejb-jar-10_0.xsd.

application-client.xml

Describes the EJB modules and other resources used by a J2EE application client packaged in an archive.

orion-application-client.xml

Contains OC4J deployment data, including JNDI mappings to an EJB's home interface or to external resources such as a data source, JMS queue, or mail session.

The file format is defined in orion-application-client-10_0.xsd.

ra.xml

Contains information on implementation code, configuration properties, and security settings for a resource adapter packaged within a RAR file.

oc4j-ra.xml

Contains deployment configuration data for a single resource adapter. This data includes such information as the JNDI name to be used, EIS connection information, connection pooling parameters, and resource principal mappings.

The file format is defined by oc4j-connector-factories-10_0.xsd.

oc4j-connectors.xml

In an OC4J instance with standalone resource adapters deployed, contains an enumeration of those standalone resource adapters. In a J2EE application with embedded resource adapters deployed, contains a list of embedded resource adapters that have been bundled with the application.

This file is formatted according to oc4j-connectors-10_0.xsd.

webservices.xml

Describes a Web Service, including WSDL information and JAX-RPC mapping data, for a Web Service application packaged within a WAR file.

oracle-webservices.xml

Defines properties used by the OC4J Web services container, such as whether to expose the WSDL file. It also defines endpoint addresses and data specific to EJBs implemented as Web services. The file can be packaged in either a WAR or an EJB JAR containing a Web service.

This file is formatted according to oracle-webservices-10_0.xsd.


Creating or Editing a Deployment Plan

Deployment plans can be created or edited through the deployment plan editor functionality available through the Web-based Oracle Enterprise Manager 10g Application Server Control Console interface and the J2EE and Studio Editions of the Oracle JDeveloper 10g integrated development environment.

Creating or Editing Deployment Plans with Application Server Control Console

The deployment plan editor screens provided through the Oracle Enterprise Manager 10g Application Server Control Console are accessed through the third and final screen of the "deployment wizard". Simply click the Edit Deployment Plan button on this screen to view the editor.

Each archive being deployed is displayed as an XPath node in the left-hand navigation pane of the editor. Select an archive node to access the deployment plan properties for that archive type. You will be able to view the following:

  • The J2EE standard descriptor packaged with the archive

  • The current values for XML elements and attributes that will be set in the OC4J-specific descriptor generated at deployment time

  • A set of properties that can be set in the deployment plan, each corresponding to an element or attribute in the OC4J-specific descriptor that will be generated at deployment time

    See "Setting Properties in a Deployment Plan" for a description of each property that can be set. Not all parameters that can be set in an XML descriptor file can be set through the deployment plan editor; parameters set after deployment are not exposed.

After creating a deployment plan, you can save it as an XML file, which you can apply to other application deployments.

You can also select an existing deployment plan to apply during a deployment in the first panel of the "deployment wizard". Once retrieved, a deployment plan can be edited or used as-is.

Creating or Editing Deployment Plans with Oracle JDeveloper

The deployment plan editor functionality provided with Oracle JDeveloper 10g is presented as the Configure Application panel.

To use the deployment plan editor, you must first create a connection of type J2EE 1.4 Server to the target OC4J instance. This is done through the wizard accessible via the Connection Navigator panel.

Once you are connected, the Configure Application panel is displayed after you select an archive and choose Deploy to -> connection_name.

After creating a deployment plan, you can save it as an XML file, which you can apply to other application deployments.

See the "Deploying Applications" topic in the Oracle JDeveloper online help for instructions on deploying archives into OC4J.

Setting Properties in a Deployment Plan

This section describes the properties that you can set in a deployment plan and how to set them. It is organized based on the type of archive being deployed:

Setting J2EE Application Configuration Properties

You can set the following OC4J-specific properties when you are deploying a J2EE application packaged in an EAR file. Each property maps to an element attribute in the orion-application.xml descriptor.

applicationId

Contains a server-defined string that specifies the application's unique identifier.

autoCreateTables

Set to true to automatically create database tables for CMP Enterprise JavaBeans in this application. The default is false.

autoDeleteTables

Specifies whether old database tables for CMP beans should automatically be deleted when this application is redeployed. The default is false.

cluster

Configures OC4J application clustering at the application level. Application clustering is typically configured at the global level; however, application-level settings will override the global configuration. See Oracle Containers for J2EE Configuration and Administration Guide for a detailed overview of the OC4J clustering framework.

  • enabled: Specifies whether clustering is enabled for the application. The default is true. Setting this value at the application level overrides the value inherited from the parent application. Clustering can be enabled or disabled for a specific application.

  • groupName: The name to use when establishing the replication group channels. If not supplied, the application name as defined in server.xml, the OC4J server configuration file, is used by default, and new group channels are created for each enterprise application.

    If a value is specified, the application and all child applications will use the channels associated with this application group name.

  • allowColocation: Specifies whether to allow the application state to be replicated to an application group member residing on the same host machine. The default is true.

    If multiple OC4J instances are instantiated on the same machine, different listener ports must be specified for each instance in the default-web-site.xml, jms.xml, and rmi.xml configuration files.

  • writeQuota: The number of other application group members (JVMs) to which the application state should be replicated. This attribute makes it possible to reduce overhead by limiting the number of nodes state is written to, similar to the "islands" concept used in previous OC4J releases. The default is 1 group member.

  • cacheMissDelay: The length of time, in milliseconds, to wait in-process for another application group member to respond with a session if the session cannot be found locally. If the session cannot be found, the request will pause for the entire length of time specified. The default is 1000 milliseconds (1 second).

  • replicationPolicy: Specifies the replication policy to apply. This policy defines when replication of data occurs.

    The ideal values to set differ for Web modules and EJB components. See the Oracle Containers for J2EE Configuration and Administration Guide for valid values.

  • propertyConfig: Contains the properties that define the clustering communication protocol stack.

    • propertyString: A string containing the properties that define the clustering communication protocol stack.

    • url: A link to the XML configuration file that contains the properties that define the clustering communication protocol stack.

  • protocol: Defines the mechanism to use for data replication. Note that only one can be specified. The default protocol used is multicast.

    • database: The connection information required to persist state data to a database.

      • dataSource: The name of the data source that will provide the database connection. This must be the JNDI name for the data source, which is the value of the jndi-name attribute specified in data-sources.xml.

    • peer: Contains the configuration required to use peer-to-peer (P2P) communication for replication.

      • range: The number of times to increment the port value while looking for a potential peer node. The default is 5 times. Valid only for configuring static peer-to-peer replication in a standalone OC4J installation.

      • startPort: The initial port to attempt to allocate for usage by this application cluster configuration for peer communication. The default is port 7800. Valid only for configuring static peer-to-peer replication in a standalone OC4J installation.

      • timeout: The length of time, in milliseconds, to wait for a response from a peer while looking for a potential peer node. The default is 3000 milliseconds (3 seconds). Valid only for configuring static peer-to-peer replication in a standalone OC4J installation.

      • nodes: Contains the host name and port of a node to poll for the list of available OC4J servers. Multiple nodes may be specified. Valid only for configuring static peer-to-peer replication in a standalone OC4J installation.

      • bindAddr: Optionally specifies the IP address of a Network Interface Card (NIC) to bind to. This is useful if you have OC4J host machines with multiple network cards, each with a specific IP address, and you wish to define which NIC is used to send and receive the multicast messages.

    • multicast: Contains the configuration required to use multicast communication for replication. This is the default mechanism used.

      • ip: The multicast address to use. The OC4J default is 230.230.0.1.

      • port: The multicast port to use. The OC4J default is port 45566.

      • bindAddr: Optionally specifies the IP address of a Network Interface Card (NIC) to bind to. This is useful if you have OC4J host machines with multiple network cards, each with a specific IP address, and you wish to define which NIC is used to send and receive the multicast messages.

  • replicationPolicy: Defines when replication of HttpSession or stateful session bean state occurs, and whether all attributes and variable values or only changed values are replicated. Replication can be an expensive process, and replicating data too frequently can affect server performance. On the other hand, replicating data too infrequently can result in lost data in the event of server failure.

    • scope: Defines what data is replicated: Either all attribute or variable values, or changed values only. By default, only modified HTTP session attributes are replicated; for stateful session beans, all member variables are replicated.

    • trigger: Specifies when replication occurs. By default, the onRequestEnd policy is applied, as it provides frequent replication of data while ensuring that data is not lost if the JVM terminates unexpectedly.

connectorsPath

Defines a plug-in connector deployed with the application.

  • path: The name and path of the oc4j-connectors.xml file. If not specified, then OC4J uses the default path, ORACLE_HOME/j2ee/instance/connectors/rarName./oc4j-connectors.xml.

dataSourcesPath

Specifies the path and file name of the XML file defining data sources to be used by the application.

The default data-sources.xml file, which defines the default data source used by OC4J, is installed in the ORACLE_HOME/j2ee/instance/config/ directory.

  • path: The path to the XML file. The path can be fixed or relative to the location of the orion-application.xml descriptor, which is ORACLE_HOME/j2ee/instance/config/ by default.

defaultDataSource

Defines the default data source to use if other than server default. This must point to a valid CMT data source for this application if specified.

deploymentVersion

Defines the version of OC4J that this JAR was deployed against. If this version does not match the current version, then the JAR will be redeployed. This is an internal server value; do not edit.

enableIIOP

Set to true to enable IIOP. The default is false.

importedLibraries

Defines one or more shared libraries to be imported by the application, as well as one or more shared libraries to delete from the set of libraries inherited by default from the parent application.

  • editImport: Specifies a shared library to be imported by the application.

    • maxVersion: The highest implementation version of the shared library to import. (To import the latest version of a shared library, do not specify a version.)

    • minVersion: The lowest implementation version of the shared library to import.

    • name: The name of the shared library to import.

  • editRemove: Specifies a shared library to be removed from the set of shared libraries inherited by default from the application's parent. This includes shared libraries inherited from the server-level system and default applications, which are inherited by all applications deployed into OC4J by default.

    • name: The name of the shared library to remove.

jazn

Configures the Java Authentication and Authorization Service (JAAS) to use the XML-based configuration provider type. This property maps to the <jazn> element of orion-application.xml. For information about using the <jazn> element for an application, see the description of the <jazn> element of the jazn.xml file in the Oracle Containers for J2EE Security Guide.

  • provider: Set to XML

  • location: Set the path to the jazn-data.xml file (for example: ./jazn-data.xml). This can be an absolute path, or a path relative to the jazn.xml file, where the JAAS Provider first looks for the jazn-data.xml in the directory containing the jazn.xml file. Optional if jazn.xml file configured, otherwise required.

  • persistence Values are NONE (do not persist changes), ALL (persist changes after every modification), VM_EXIT (The default - persist changes when the JVM exits)

  • default-realm: A realm name. For example: sample_subrealm. Optional if only one realm is configured.

For more information about JAAS configuration and the jazn-data.xml and jazn.xml files, see the Oracle Containers for J2EE Security Guide.

jaznLoginConfig

Contains data used to associate the application with a JAAS login module. These properties correspond to the <jazn-loginconfig> element and its subelements in the jazn-data.xml file and should be displayed only if the JAZN XML-based provider will be used by the application.

  • className: The login module implementation class.

  • controlFlag:Indicates whether the login module is required to succeed to proceed with authentication.

  • options: A collection of one or more properties to pass to the login module as name and value pairs. For example: name debug, value true.

See the Oracle Containers for J2EE Security Guide for details about the jazn-data.xml file and these properties.

jmxMBeans

Defines one or more MBeans deployed with the application. Specify each property below for each MBean being deployed.

  • className: The MBean implementation class.

  • description: A string containing a readable name for the MBean. This name will be displayed in the Application Server Control Console user interface.

  • objectName: The name to register the MBean under. The domain part of the name will be ignored even if specified; application MBeans are registered using the application's deployment name as the domain name.

    For example, if you deploy an MBean named MyMBeanA with an application named widget, supply:name=MyMBeanA as the value of this attribute. The name will then be displayed as widget:name=MyMBeanA.

libraries

Specifies either a relative or absolute path or URL to a directory or a JAR or ZIP archive to add as a library path for this OC4J instance. Directories are scanned for archives to include at OC4J startup.

  • path: The path to the directory or archive.

log

Sets the logging configuration for the application.

  • file: The optional path to the directory where text log files will be generated if text logging will be used by the application. The default location for text log files is ORACLE_HOME/j2ee/instance/application-deployments/application_name/application.log. The default log file name and path should not be modified.

  • mail: Optionally set the e-mail address to which to mail log output. A valid mail-session must also be specified through the mailSessions property if this option is selected.

  • odl: Configures Oracle Diagnostic Logging to be used by the application. The ODL framework provides plug-in components that complement the standard Java framework to automatically integrate log data with Oracle log analysis tools. In the ODL framework, log files are formatted in XML, enabling other Oracle Application Server and custom-developed components to parse and reuse the log files more easily.

    • maxDirectorySize: The maximum size, in bytes, allowed for the log file directory. When this limit is exceeded, log files are purged, beginning with the oldest files.

    • maxFileSize: The maximum size, in bytes, that an individual log file is allowed to grow to. When this limit is reached, a new log file is generated.

    • path: The path to the folder to output the log.xml files for this component to. The path can be absolute or relative to the XML configuration file you are modifying.

      For example, to output log.xml files in a /hello-planet-xml directory within ORACLE_HOME/j2ee/instance/log/, set the path attribute to "../../log/hello-planet-xml".

mailSessions

Defines the mail session SMTP host, if SMTP is used by the application.

  • location: The location within the namespace to store the mail session in.

  • smtp-host: The session SMTP server host.

namespaceAccess

Sets the namespace or naming context security policy for RMI clients.

parentApp

Specifies the name of the application that serves as the parent of this application. This value is set during deployment.

persistencePath

Defines the path to a directory where application state data should be stored across application restarts. The path can be absolute or relative to the application root.

  • path: The path to the persistence directory.

resourceProviders

Defines a resource provider.

  • className: The name of the resource provider class.

  • name: The name used to identify the resource provider. This name will be used in finding the resource provider in the application's JNDI as "java:comp/resource/name/".

  • description: An optional description of the specific resource provider.

  • properties: Set name and value property pairs to pass to the resource provider as parameters.

seeParentDataSources

Specifies whether the application should inherit the existing data sources defined for its parent application. The default is false.

taskManagerInterval

Defines the interval at which the task manager performs its duties, in milliseconds. The task manager is a background process that performs cleanup activities. By default, it is started every second (1000 milliseconds).

treatZeroAsNull

Specifies whether to read the value zero as null when it represents a primary key. The default is false.

userManagerByClass

Specifies an optional UserManager class to use, which can be any class that implements the com.evermind.security.UserManager interface. For example, com.evermind.sql.DataSourceUserManager or com.evermind.ejb.EJBUserManager. These classes are typically used to integrate existing systems and provide custom user-managers for Web applications.

  • className: The fully qualified classname of the UserManager.

  • description: An optional text description.

  • displayName: A descriptive name for this UserManager instance.

  • properties: One or more properties as name and value pairs to be passed to the UserManager. For example:

    name="groupMembershipGroupFieldName" value="group" name="groupMembershipUsernameFieldName" value="Userid"


Note:

The com.evermind.security package and its classes are deprecated. They will no longer be supported in the 11g release. Instead of com.evermind.security.UserManager implementations, you can use JAAS custom login modules, described in the Oracle Containers for J2EE Security Guide.

webSiteBinding

Specifies the name of the Web site the application's Web module is bound to. By default, all applications deployed into OC4J are bound to the default Web site. See the Oracle Containers for J2EE Configuration and Administration Guide for details on creating and using Web sites in OC4J.

Setting Web Module Configuration Properties

The following subsections describe the OC4J-specific properties that you can set when deploying a Web module packaged in a WAR file. Each property maps to an element attribute in the orion-web.xml descriptor.

accessMask

Specifies optional access masks for this application. You can specify host names or domains to filter clients through the hostAccess property; specify IP addresses and subnets to filter clients in ipAccess; or define both.

  • default: Specifies whether to allow requests from clients not identified through a hostAccess or ipAccess property. Supported values are allow (default) and deny.

  • hostAccess: Specifies a host name or domain from which to allow or deny access.

    • domain: The host or domain.

    • mode: Whether to allow or deny access from the specified host or domain. Supported values are allow (default) or deny.

  • ipAccess: Specifies an IP address and subnet mask from which to allow or deny access.

    • ip: The IP address, as a 32-bit value; for example: 123.124.125.126.

    • netmask: The relevant subnet mask; for example: 255.255.255.0.

    • mode: Whether to allow or deny access from the specified IP address and subnet mask. Supported values are allow (default) or deny.

autoJoinSession

Specifies whether users should be assigned a session as soon as they log in to the application. The default is false.

classpath

Specifies additional code locations for Web application classloading. These can be either library files or locations for individual class files.

  • path: The path(s) to one or more code locations, separated by commas or semicolons. A location can be one of the following:

    • The complete path to a JAR or ZIP file, including the file name

    • A directory path

    If you specify a directory path, the class loader recognizes only individual class files in the specified directory, not JAR or ZIP files (unless those are specified separately).

    The class loader recognizes the following:

    • The lib1.jar and zip1.jar libraries (but no other libraries in /abc/def)

    • Any class files in /abc/def

    • Any class files in mydir, relative to the location of the generated orion-web.xml file

defaultBufferSize

Specifies the default size of the output buffer for servlet responses, in bytes. The default is 2048.

defaultCharset

Specifies the ISO character set to use by default. The default is "iso-8859-1".

defaultMimeType

Specifies the default MIME type to use for files with unknown or unrecognized extensions.

deploymentVersion

Specifies the version of OC4J under which this Web application was deployed. If this value does not match the current version, then the application is redeployed. This is an internal server value and should not be changed.

development

This property is a convenience for use during development. If set to true, then the OC4J server checks a particular directory for updates to servlet source files. If a source file has changed since the last request, then OC4J will, upon the next request, recompile the servlet, redeploy the Web application, and reload the servlet and any dependency classes.

The directory is determined by the setting of the sourceDirectory attribute (described in the following text).

directoryBrowsing

Specifies whether to allow directory browsing for a URL that ends in "/". Values are allow and deny (default).

Assume the following circumstances:

  • There is no index.htmlfile in the directory the URL is mapped to.

  • There is no "welcome" page defined in the web.xml file.

If set to allow under these circumstances, then a URL ending in "/" results in the contents of the corresponding directory being displayed in the user's browser.

If set to deny under these circumstances, then a URL ending in "/" results in an error indicating that the directory contents cannot be displayed.

If there is a defined welcome file or there is an index.html file in the directory the URL is mapped to, then the contents of that file are displayed, regardless of this setting.

enableJspDispatcherShortcut

A true setting, which is the default, results in significant performance improvements by the OC4J JSP container, especially in conjunction with a true setting for the simpleJspMapping property. This is particularly true for JSP pages with numerous jsp:include tags.

Use of the true setting assumes, however, that if you define JSP files with <jsp-file> elements in web.xml, you have corresponding url-pattern definitions for those files.

expirationSettings

Defines the length of time before a specified set of resources - such as image files - will expire in the user's browser. This is useful for caching policies, such as for not reloading images as frequently as documents.

  • expires: The number of seconds before the resources expiration, or "never" for no expiration. The default setting is "0" (zero), for immediate expiration.

  • urlPattern: The URL pattern that the expiration applies to, such as in the following example:

    urlPattern="*.gif"
    

fileModificationCheckInterval

Defines the interval, in milliseconds, at which OC4J checks for modified files. This property applies only to static files, such as HTML files.

Within the time period since the last check, further checks are not necessary. Zero or a negative number specifies that a check always occurs. The default is 1000. For performance reasons, a very large value (1000000, for example) is recommended in a production environment.

id

Defines a unique internal identifier generated at the time of deployment.

jaznWebApp

Configures the OracleAS JAAS Provider and Single Sign-On (SSO) properties for servlet execution. You must set these features appropriately to invoke a servlet under the privileges of a particular security subject.

  • authMethod: Supported values are BASIC (for basic J2EE authentication, the default) and SSO. Use SSO to employ Oracle Single Sign-On for HTTP client authentication. Use BASIC mode if the application uses a custom LoginModule instance.

  • runAsMode: Set to true to invoke the servlet using the privileges of a particular subject. A subject is defined by an instance of the javax.security.auth.Subject class and includes a set of facts regarding a single entity, such as a person. Such facts include identities and security-related attributes, such as passwords and cryptographic keys.

    With the default runas-mode="false" setting, doasprivileged-mode is ignored.

  • doAsPrivilegedMode: Assuming runAsMode is set to true, use the default true setting to use privileges of a particular subject without being limited by the access-control restrictions of the server.

    For additional information about JAAS and the features described for this element, see the Oracle Containers for J2EE Security Guide.

jspCacheDirectory

Specifies the JSP cache directory, which is used as a base directory for output files from the JSP translator. It is also used as a base directory for application-level TLD caching. The default value is ./persistence, relative to the application deployment directory.

jspCacheTlds

Indicates whether persistent TLD caching is enabled for JSP pages. TLD caching is implemented both at a global level, for TLD files in "well-known" tag library locations, and at an application level, for TLD files under the /WEB-INF directory. Values are standard (default), on or off. Well-known locations are defined in the jspTaglibLocations property (documented in the following text). For more information on these values, see the Oracle Containers for J2EE Support for JavaServer Pages Developer's Guide.

jspPrintNull

Set to false to print an empty string instead of the default "null" string for null output from a JSP page. The default is true.

jspTaglibLocations

Defines the locations of shared tag libraries. This value can be set at the global application level only.

jspTimeout

Specifies an integer value, in seconds, after which any JSP page will be removed from memory if it has not been requested. This frees up resources in situations in which some pages are called infrequently. The default value is 0 (zero), for no timeout.

mimeMappings

Defines the path to a file containing MIME mappings to use.

  • path: The path or URL for the file, either absolute or relative to the location of the orion-web.xml file.

persistencePath

Indicates where to store servlet HttpSession objects for persistence across server restarts or application redeployments. Specify a relative path, which will be relative to an OC4J temporary storage area under the application-deployments directory. There is no default value. If no value is defined, then there is no persistence of session objects across restarts or redeployments.

Session objects must be serializable (directly or indirectly implementing the java.io.Serializable interface) or remoteable (directly or indirectly implementing the java.rmi.Remote interface) for this feature to work.

requestTrackers

Specifies one or more servlets to use as dedicated request trackers. Request trackers are useful for logging information, for example.

A request tracker is invoked for each separate request sent from a browser to the server, at the time that the corresponding response is committed (immediately before the response is actually sent).

There can be multiple request trackers, each one defined in a separate property.

  • servletName: The servlet to invoke. You can specify either the servlet name or the class name, according to the corresponding <servlet-name> or <servlet-class> element (both of which are subelements of a <servlet> element) in the web.xml file.

servletChaining

Specifies a servlet to call when the response of the current servlet is set to a specified MIME type. The specified servlet is called after the current servlet. This is known as servlet chaining, for filtering or transforming certain kinds of output.

  • mimeType: The MIME type used to trigger the chaining, such as "text/html".

  • servletName: The servlet to call when the specified MIME type is encountered. The servlet name is tied to a servlet class through its definition in the <web-app> element of global-web-application.xml, web.xml, or orion-web.xml.

servletWebdir

Specifies the path for invoking a servlet by class name. Anything appearing after this path in a URL is assumed to be a class name, including the package.

The following example illustrates servlet invocation by class name, assuming this property is set to "/servlet/":

http://www.example.com:8888/servlet/foo.bar.SessionServlet

This feature is typically for use in an OC4J standalone environment during development and testing. For deployment, use the standard web.xml mechanisms for defining the context path and servlet path.

sessionTracking

Specifies the session-tracking settings for this application. Session tracking is accomplished using cookies, assuming a cookie-enabled browser.

  • cookies: Set to enabled (default) to send session cookies; set to disabled to disable this setting.

  • cookieDomain: Set to the desired domain to use for cookies. You can use this attribute to track a single client or user over multiple Web sites. The setting must start with a period (".") and must consist of at least two elements, such as .us.oracle.com or .oracle.com.

    In this case, the same cookie is used when the user visits any site that matches the .us.oracle.com domain pattern, such as webserv1.us.oracle.com or webserv2.us.oracle.com.

  • cookieMaxAge: Set the maximum length of time, in seconds, that the browser will keep a cookie. By default, the cookie is kept in memory during the browser session and discarded afterward.

  • sessionTracker: The name of the servlet to use as a session tracker.

    The session tracker is invoked as soon as a session is created; specifically, at the same time as the invocation of the sessionCreated() method of the HTTP session listener (an instance of a class implementing the javax.servlet.http.HttpSessionListener interface).

  • servletName: The servlet to invoke as a session tracker. Specify either the servlet name or the class name, according to the corresponding <servlet-name> or <servlet-class> element, both of which are subelements of a <servlet> element) in the Web module's web.xml file.

simpleJspMapping

Set to true if "*.jsp" is mapped only to the OC4J front-end JSP servlet, oracle.jsp.runtimev2.JspServlet, in the <servlet> elements of any Web descriptors affecting your application (global-web-application.xml, web.xml, and orion-web.xml). This allows performance improvements for JSP pages. The default setting is false.

sourceDirectory

Specifies the location of servlet source files to auto-compile if the development property is set to true. The default location is /WEB-INF/src if it exists; otherwise it is /WEB-INF/classes.

temporaryDirectory

Contains the path to a temporary directory that can be used by servlets and JSP pages for scratch files. The path can be either absolute or relative to the deployment directory. The default setting is "./temp".

A servlet may use a temporary directory, for example, to write information to disk as a user is entering data in a form, for interim or short-term storage before the information is written to a database.

virtualDirectories

Adds a virtual directory mapping for static content. This is conceptually similar to symbolic links on a UNIX system, for example.

The virtual directory enables you to make files in the "real" document root directory available to the application, even though the files do not physically reside in the Web application WAR file. This would be useful, for example, to link an enterprise-wide error page into multiple WAR files.

  • realPath: The real path to the files that the virtual path will map to. For example, /usr/local/realpath in UNIX or C:\testdir in Windows.

  • virtualPath: The virtual path to map to the specified real path.

webAppClassLoader

Contains class loading instructions passed to the OC4J server at Web module startup.

  • searchLocalClassesFirst: Set to true to search and load WAR file classes before system classes. The default setting is false.

  • includeWarManifestClassPath: Set to false to not include the classpath specified in the WAR file manifest Class-Path attribute when searching and loading classes from the WAR file, regardless of the searchLocalClassesFirst setting. The default setting is true.

If both attributes are set to true, the overall classpath is constructed so that classes physically residing in the WAR file are loaded prior to any classes defined in the WAR file manifest classpath. In the event of conflict, classes physically residing in the WAR file will take precedence.

Setting Enterprise JavaBeans Module Configuration Properties

The following details the OC4J-specific properties that can be set when you are deploying a J2EE application packaged in an EAR file. Each property maps to an element attribute in the orion-ejb.xml descriptor.

The properties that can be set differ for entity beans, session beans and message-driven beans. As such, the properties are broken out as follows:

Setting General EJB Properties

The following properties apply to all EJBs within the archive being deployed.

defaultMethodAccess

Sets the default method access policy for insecure methods not associated with a role mapping. Methods are automatically mapped to the default security role.

  • impliesAll: Set to true to disable security-role checking for insecure methods.

    If false, you must map the default role defined in the name attribute to an OracleAS JAAS Provider or XML user group or user through the groups and users properties (described in the following items).

    The default is false if <security-role-mapping> is specified in the orion-ejb-jar.xml file and impliesAll is not set.

    If <security-role-mapping> is not specified in the orion-ejb-jar.xml file, the OC4J EJB layer defaults this attribute to true: no security-role checking occurs for these methods.

  • name: The default security role that insecure methods will be mapped to. The default is the <default-ejb-caller-role> role; however, this value can be changed to any valid role.

  • groups: One or more user group names that will be used by clients to access insecure methods.

  • users: One or more user names that will be used by clients to access insecure methods.

deploymentVersion

The version of OC4J the EJB JAR is being deployed into. This is an internal server value.

persistenceManager

Defines the persistence manager component to use to manage the persistence layer of entity EJBs.

The TopLink utility is the default persistence manager used with OC4J, and by default, all EJBs deployed into OC4J are managed by the TopLink PM. No configuration is required for TopLink. See the Oracle TopLink Getting Started Guide for details.

  • descriptor: The file name of the persistence manager's deployment descriptor file.

  • name: The name of the persistence manager implementation to use. Valid values are toplink if using TopLink, or orion if using the Orion CMP implementation. The default is toplink.

  • pmProperties: Contains configuration properties for the TopLink persistence manager.

    • customizationClass: An optional Java class implementing the oracle.toplink.ejb.cmp.DeploymentCustomization interface used to allow deployment customization of TopLink mapping and runtime configuration. The class must be fully qualified and included in the EJB JAR being deployed.

    • dbPlatformClass: A TopLink database platform class containing TopLink support specific to a particular database. The specified class must be fully qualified.

    • projectClass: An optional TopLink project class containing mapping metadata. This class will replace the TopLink descriptor specified in the descriptor property. The class must be fully qualified and must exist in the EJB JAR file being deployed.

    • remoteRelationships: Set to true to maintain relationships between remote objects through the entities' remote interfaces. Note that this flag is not compliant with EJB 2.0. The default is false.

    • sessionName: A unique name for the EJB JAR being deployed. The name must be unique among all TopLink-persisted JARs deployed in OC4J. If no value is specified, a unique name will be generated by the TopLink persistence manager.

    • mode: Set whether updates should be propagated to another data store server synchronously or asynchronously. The default value is asynchronously.

    • serverUrl: The URL to the data store host.

    • serverUser: The user name to use to access the host.

    • dbTableGen: Specifies how TopLink will create or use the database tables being mapped to. This setting is ignored if the mappings are already defined for the entities. Values are as follows:

      • Create: Attempt to create the tables. This is the default.

      • DropAndCreate: Attempt to drop existing tables before re-creating them.

      • UseExisting: Use existing tables.

    • extendedTableNames: Set to true only if the generated table names are not long enough to be unique. This setting is ignored if the mappings are already defined for the entities. The default is false.

Setting Entity Bean Properties

The following properties apply to an entity bean included in the EJB archive.

callTimeout

Specifies the maximum time, in milliseconds, to wait for any resource to make a business/life-cycle method invocation. This is not a timeout for how long a business method invocation can take. The default is 90000 milliseconds (90 seconds). If the timeout is reached, a TimedOutException is thrown. This excludes database connections. Set to 0 if you want the timeout to be forever. See the EJB section in the Oracle Application Server Performance Guide for more information.

copyByValue

Specifies whether or not to copy (clone) all of the incoming and outgoing parameters in EJB calls. Set to false if you are certain that your application does not assume copy-by-value semantics for a speed-up. The default is true.

dataSource

Specifies the name of the data source used if using container-managed persistence.

disableWrapperCache

Set to true to disable the wrapper class cache for the EJB.

doSelectBeforeInsert

Specifies whether to execute a SELECT statement before an insert into the database. The extra select normally checks to see if the entity already exists before doing the insert to avoid duplicates.

The default value is true. For performance, Oracle recommends setting this property to false to avoid executing the extra statement.

However, if a unique key constraint is not defined for the entity, setting this value to false will allow a duplicate insert to avoid detection. To prevent duplicate inserts in this case, leave the value set to true.

findByPrimaryKeyLazyLoading

Set to true to turn on lazy loading and enforce only a single execution of the select() finder method. For entity bean finder methods, lazy loading can cause this method to be invoked more than once. The default is false.

instanceCacheTimeout

Specifies the amount of time, in seconds, that entity wrapper instances are assigned to an identity. Set to never to retain the wrapper instances until they are garbage collected. The default is 60 seconds.

iorSecurityConfigs

Configures CSIv2 security policies for interoperability. See Oracle Containers for J2EE Security Guide for details.

isolation

Specifies the isolation level for database actions.

  • Valid values for Oracle databases are serializable and committed (default).

  • Valid values for non-Oracle databases include the following: none, committed, serializable, uncommitted, and repeatable_read.

location

Defines the JNDI name this EJB will be bound to.

lockingMode

Configures the concurrency modes, which specify when to block for resource contention management, or when to execute in parallel. Values are:

  • optimistic: Allows multiple users to execute the entity bean in parallel. It does not monitor resource contention; thus, the burden of the data consistency is placed on the database isolation modes. This is the default.

  • pessimistic: Manages resource contention and does not allow parallel execution. Only one user at a time is allowed to execute the entity bean at a single time.

  • read-only: Allows multiple users to execute the entity bean in parallel. However, the container does not allow any updates to the bean's state.

maxInstances

Sets the number of maximum bean implementation instances to be kept instantiated or pooled. The default is 100. Set to 0 to indicates no maximum.

maxTxRetries

Specifies the number of times to retry a transaction that was rolled back due to system-level failures. The default is 3. Generally, you should add retries only where errors are seen that could be resolved through retries. For example, if you are using serializable isolation and you want to retry the transaction automatically if there is a conflict, you might want to use retries.

minInstances

Sets the number of minimum bean implementation instances to be kept instantiated or pooled. The default is 0.

name

Specifies the name of the bean, which matches the name specified in the assembly section of the standard EJB deployment descriptor (ejb-jar.xml).

poolCacheTimeout

Defines the amount of time, in seconds, that the bean implementation instances are to be kept in the "pooled" or unassigned state. Set to 0 to retain bean instances until they are garbage collected. The default is 60.

txRetryWait

Specifies the time to wait in seconds between retrying the transaction. The default is 60 seconds.

The tx-retry-wait attribute of the <entity-deployment> or <session-deployment> element in the orion-ejb-jar.xml file is not in orion-ejb-jar-10_0.xsd or orion-ejb-jar.dtd.

You can still specify txRetryWait to use the tx-retry-wait attribute in your orion-ejb-jar.xml file. If you use this attribute, however, do not configure OC4J to perform XML file validation (by using the -validateXML option on the OC4J startup command line).

validityTimeout

Sets the maximum amount of time, in milliseconds, that an entity is valid in the cache before being reloaded. This is useful for loosely coupled environments where rare updates from legacy systems occur. This attribute is only valid for entity beans with a locking mode of read_only.

If the EJB is generally not modified externally, meaning that the table is occasionally updated and cache updates are required, set this to a value corresponding to the interval at which you think the data may be changing externally.

If the data is never modified externally the value can be set to 0 or -1 to disable this option. The data in the cache will always be valid for read-only EJBs that are never modified externally.

Setting Session Bean Properties

The following properties apply to a session bean included in the EJB archive.

callTimeout

Specifies the maximum time, in milliseconds, to wait for any resource to make a business/life-cycle method invocation. This is not a timeout for how long a business method invocation can take. The default is 90000 milliseconds (90 seconds).

Set to 0 for no timeout. See the EJB section in the Oracle Application Server 10g Performance Guide for more information.

copyByValue

Specifies whether or not to copy (clone) all of the incoming and outgoing parameters in EJB calls. Set to false if you are certain that your application does not assume copy-by-value semantics for a speed-up. The default is true.

idleTime

Specifies the timeout, in seconds, applied to stateful session EJBs. If the value is 0 or negative, then all timeouts are disabled. The default is 1800 seconds (30 minutes).The timeout parameter is an inactivity timeout for stateful session beans. Every 30 seconds the pool cleanup logic is invoked. Within the pool cleanup logic, only the sessions that timed out, by passing the timeout value, are deleted. Adjust the timeout based on your application's use of stateful session beans. For example, if stateful session beans are not removed explicitly by your application, and the application creates many stateful session beans, then you may want to lower the timeout value.

iorSecurityConfigs

Configures CSIv2 security policies for interoperability. See the Oracle Containers for J2EE Security Guide for details.

location

Defines the JNDI name this EJB will be bound to.

maxInstances

Defines the maximum number of bean instances, either instantiated or pooled, allowed in memory. The default is 100.

When this limit is reached, the container attempts to passivate the oldest bean instance from memory. If unsuccessful, the container waits the number of milliseconds set in callTimeout to see if a bean instance is removed from memory, through passivation, its remove() method, or bean expiration, before a TimeoutExpiredException is thrown back to the client.

Set to 0 to allow an infinite number of bean instances. This property applies to both stateless and stateful session beans.

maxInstancesThreshold

Specifies how many active beans can exist in relation to the value set for maxInstances before passivation is initiated.

Specify an integer that is translated as a percentage. For example, if maxInstances is 100 and maxInstancesThreshold is 90 percent, passivation of beans occurs when active bean instances reaches past a total of 90.

The default is 90. Set to 0 to disable this feature.

maxTxRetries

Specifies the number of times to retry a transaction that was rolled back due to system-level failures. The default is 3. Generally, you should add retries only where errors are seen that could be resolved through retries. For example, if you are using serializable isolation and you want to retry the transaction automatically if there is a conflict, you might want to use retries.

memoryThreshold

Defines a threshold for how much used JVM memory is allowed before passivation should occur. Specify an integer that is translated as a percentage. When the percentage is reached, beans are passivated, even if their idle timeout has not expired. The default is 80 percent. To disable, specify never.

minInstances

Sets the number of minimum bean implementation instances to be kept instantiated or pooled. The default is 0.

name

Defines the name of the EJB, which matches the name of a bean in the assembly section of the standard EJB deployment descriptor (ejb-jar.xml).

passivateCount

Defines the number of beans to be passivated if any of the resource thresholds - such as maxInstancesThreshold or memoryThreshold - has been reached. Passivation of beans is performed using the least recently used algorithm. By default, the number of beans is one-third of the value set for maxInstances. Set the count to 0 or a negative number to disable.

persistenceFilename

Defines the path to the file where sessions are stored across OC4J restarts.

poolCacheTimeout

Sets the amount of time, in seconds, that stateless sessions are to remain cached in the pool. At the specified interval, all unassigned beans in the pool are removed. The default is 60 seconds.

If the value specified is 0 or negative, beans are not removed from the pool.

replication

Defines when state replication should occur for stateful session beans in a clustered environment. Values are VMTermination, EndOfCall or None (default). See the Oracle Containers for J2EE Configuration and Administration Guide for details.

resourceCheckInterval

Defines the interval, in seconds, at which OC4J checks all resources to see which have passed the specified thresholds, such as maxInstancesThreshold. Passivation of beans occurs if any thresholds have been reached. The default is 180 seconds (3 minutes). To disable, set to 0.

timeout

Defines the inactivity timeout, in seconds, after which stateful session beans are considered ready for deletion from the pool. If the value is 0 or negative, then all timeouts are disabled. The default is 1800 seconds (30 minutes).Adjust the timeout based on your application's use of stateful session beans. For example, if stateful session beans are not removed explicitly by your application, and the application creates many stateful session beans, then you might want to lower the timeout value. The pool cleanup logic is invoked every 30 seconds.

txRetryWait

Specifies the length of time to wait, in seconds, between retrying a transaction. The default is 60 seconds.

The tx-retry-wait attribute of the <entity-deployment> or <session-deployment> element in the orion-ejb-jar.xml file is not in orion-ejb-jar-10_0.xsd or orion-ejb-jar.dtd.

You can still specify txRetryWait to use the tx-retry-wait attribute in your orion-ejb-jar.xml file. If you use this attribute, however, do not configure OC4J to perform XML file validation (by using the -validateXML option on the OC4J startup command line).

Setting Message-Driven Bean Properties

The following properties apply to a message-driven bean within the archive being deployed. Each property pertains to attributes or sub-elements of a <message-driven-deployment> element in the orion-ejb-jar.xml descriptor.

connectionFactoryLocation

Contains the JNDI location of the connection factory to use.

The syntax is java:comp/resource + resource provider name + TopicConnectionFactories or QueueConnectionFactories + user defined name. The ConnectionFactories property details the type of factory that is being defined.

dequeueRetryCnt

Specifies how often the listener thread tries to reacquire the JMS session once database failover has occurred. The default is 0. This value is only for container-managed transactions.

dequeueRetryInterval

Specifies the interval between attempts to reacquire the JMS session. The default is 60 seconds.

destinationLocation

Specifies the JNDI location of the destination (topic or queue) to use.

The syntax is java:comp/resource + resource provider name + Topics or Queues + Destination name. The Topic or Queue details what type of Destination is being defined. Destination name is the actual queue or topic name defined in the database.

listenerThreads

Sets the number of listener threads spawned to listen for incoming JMS messages on the topic or queue. The threads concurrently consume JMS messages. Topics can only have one thread; queues can have more than one thread. The default is 1 thread.

maxInstances

Do not set his property; use listenerThreads instead.

minInstances

Do not set this property.

name

Contains the name of the EJB, which matches the name of an EJB in the assembly section of the J2EE standard EJB deployment descriptor (ejb-jar.xml) packaged in the EJB archive.

resourceAdapter

Contains the name of the resource adapter to be created by the connection factory for use by this bean. This value is defined in orion-ra.xml, the OC4J-specific resource adapter descriptor.

subscriptionName

Contains the topic subscription name, if the bean represents a topic.

transactionTimeout

Sets the transaction timeout interval, in seconds, for any container-managed transactional MDB. The default is 86400 seconds (one day). If the transaction has not completed within this timeframe, the transaction is rolled back.

Setting Web Services Configuration Properties

Each property maps to an element attribute in the oracle-webservices.xml descriptor.

Setting General Web Services Properties

The following properties apply to all Web Services deployed with the archive.

contextRoot

Specifies the root context of the exposed Web Service, which is required only for EJB 2.1 Web Services. If the root context is not specified, the server defaults to the EJB JAR file name minus the .jar extension. For example, foo-ejb.jar will be translated into /foo-ejb.

For Java class Web Services, the context root is derived from the context root specified in the parent application's application.xml descriptor.

Setting Web Service Description Properties

The following properties apply to a Web Service contained within the archive being deployed.

downloadExternalImports

Specifies whether relative imports should be downloaded and resolved to absolute URLs. If set to true, resolveRelativeImports is automatically set to true. The default is false.

exposeTestpage

Set to true to expose the test page. The default is true.

exposeWsdl

Set to true to expose the WSDL file describing the Web service. The default is true.

name

Defines the name of the Web service for an EJB implemented as a Web service. This value matches the name defined in the J2EE standard EJB deployment descriptor (ejb-jar.xml).

resolveRelativeImports

Set to true to force relative imports to be resolved to absolute URLs. This property is automatically set to true if downloadExternalImports is true.

wsdlFileFinalLocation

Specifies the URI for the final updated WSDL that describes the Web service.

wsdlPublishLocation

Specifies the URI to the WSDL if exposeWsdl is set to true.

Setting Application Client Configuration Properties

The following details the OC4J-specific properties that can be set when deploying an application client packaged in a JAR or CAR file. Each property maps to an element attribute in the orion-application-client.xml descriptor.

clientInvocationMappings

Configures the client module to start when the OC4J container is started.

  • autoStart: Set to true to start the client when OC4J is started. The default is false.

  • user: The unique identifier of the user the client will run as.

  • path: The path to the client JAR file. Can be absolute or relative to the parent application's root.

  • arguments: One ore more string arguments to be passed to the client's main() method at startup.

mailSessions

Contains the configuration for a mail session resource.

  • description: An optional description for the resource.

  • location: The JNDI name to bind the mail session to.

  • smtpHost: The name or IP address of the SMTP host to use, if using SMTP.

  • username: A user name used to log in to the resource, if required.

  • password: The password used to access the resource.

  • properties: Can contain additional properties that should be given to the mail session as name and value pairs. For example:

    name="mail.from" value="mail.sender@server.com name="mail.transport.protocol" value="smtp" name="mail.smtp.from" value="mail.sender@server.com

ejb-ref

Declares a reference to the home interface of an EJB that will be used by the client.

  • location: The JNDI location the EJB is bound to.

  • name: The EJB reference name used by the application client.

Setting Resource Adapter Properties

The following text details the OC4J-specific properties that you can set when deploying a resource adapter packaged in a RAR file. Each property maps to an element attribute in the oc4j-ra.xml descriptor.

See the Oracle Containers for J2EE Resource Adapter Administrator's Guide for detailed information on resource adapter configuration.

connectionPools

Contains a name and one or more name and value pairs defining a shared connection pool. Valid property names are as follows:

  • maxConnections: The maximum number of connections permitted within the pool. If no value is specified, there is no limit on the number of connections.

  • minConnections: The minimum number of connections. If greater than 0, the specified number of connections are opened when OC4J is initialized. OC4J may not be able to open the connections if necessary information is unavailable at initialization time.

    For instance, if the connection requires a JNDI lookup, it cannot be created, because JNDI information is not available until initialization is complete. The default value is 0.

  • scheme: Defines how OC4J handles connection requests after the maximum permitted number of connections is reached. One of the following values must be specified:

    • dynamic: OC4J creates a new connection and returns it to the application, even if this violates the maximum limit. When these limit-violating connections are closed, they are destroyed instead of being returned to the connection pool.

    • fixed: OC4J raises an exception when the application requests a connection and the maximum limit has been reached.

    • fixed_wait: OC4J blocks the application's connection request until an in-use connection is returned to the pool. If waitTimeout is specified, OC4J throws an exception if no connection becomes available within the specified time limit.

  • waitTimeout: The maximum number of seconds that OC4J waits for an available connection if maxConnections has been exceeded and the fixed_wait scheme is in effect. In all other cases, this property is ignored.

connectorFactories

Contains properties defining an installed J2EE Connector Architecture-compliant resource adapter.

  • connectionFactoryInterface: The name of the factory that will create managed connection instances, such as javax.jms.QueueConnectionFactory.

  • connectorName: The name of the connector.

  • description: An optional short description of the connector.

  • location: The JNDI location which OC4J will bind the connection factory to. For example, if the value is set to eis/myEIS1, an application component can look up the connection factory using JNDI lookup on location java:comp/env/eis/myEIS1.

  • configProperties: Configuration properties for the connector factory defined in connectionFactoryInterface.

    Configuration properties are connector-specific and are defined in the <config-property> element in the J2EE deployment descriptor (ra.xml) packaged with the resource adapter. For a JCA 1.0 resource adapter, the <config-property> element is a sub-element of the <resourceadapter> element. For JCA 1.5, they are found inside the <connection-definition> element(s).

  • connectionPooling: Contains properties defining a connection pool to use. Properties are:

    • use: Specifies whether a connection pool should be used for the connection factory; and if so, whether a shared pool or a private pool should be used. Possible string values for this attribute are:

      • shared: The shared connection pool to be used for this connection factory configuration.

      • private: The private, non-shared connection pool defined in the properties fields below will be used for this connection factory configuration.

      • none: Connection pooling is disabled for this connection factory configuration.

  • log: The path to the log file generated by OC4J for this connector. If the path name is not specified or if the directory does not exist, logging is not enabled. For example: ./logConnFctry1.log

  • securityConfig: Specifies the security mechanism to use and corresponding credential information needed by the connector to access the EIS.

    • use: The security mechanism to use. Only one may be specified. Valid values are: jaasModule, principalMappingEntries or principalMappingInterface.

    • jaasModule: If using JAAS, the name of the JAAS application to use.

    • principalMappingEntries: If using the principal mapping entries mechanism, specify the following:

      • defaultMapping: Specify the resource user name and password for the default resource principal. This principal is used to log in to the EIS if there is no principal mapping entry whose initiating user corresponds to the current initiating principal.

      • principalMappingEntries: Specify the initiating principal user name and the resource user name and password. This maps the initiating principal to the resource principal and password it will use to log in to the EIS.

    • principalMappingInterface: If using the OC4J-specific programmatic container-managed sign-on mechanism, which utilizes a class implementing the oracle.j2ee.connector.PrincipalMapping interface, specify the following:

      • implClass: The class implementing the oracle.j2ee.connector.PrincipalMapping interface. A JAR file containing the class must be placed into the directory containing the decompressed RAR file.

      • properties: The user name and password that will be used to log in.

  • xaRecoveryConfig: The user name and password of the privileged user that will log in to the EIS during a two-phase commit transaction recovery.