Configure connection factories for resource adapters within applications
To access an enterprise information system (EIS), configure connection factories, which instantiate resource adapter classes for establishing and maintaining resource connections.
An application component uses a connection factory to access a connection instance, which the component then uses to connect to the underlying enterprise information system (EIS). Examples of connections include database connections, Java Message Service connections, and SAP R/3 connections.
Tasks
- Optional: Install the application if it is not already installed on the application server.
- Click Applications > Install New Application.
- Browse to find the appropriate EAR file, which contains an RAR file.
- Click Next.
- Select Resource ref mapping to a J2C Connection Factory, then click Next.
- In Step 2: Map module to servers, select the resource adapters with which to associate the application and click Next.
- Complete the installation process for the application. For more information on installing applications, refer to the topic, Installing enterprise application files with the console.
- Select the application to configure.
- Click Modules > Manage Modules.
- Select the name of the RAR file in the Manage Modules panel.
- Click Resource Adapter under the Additional Properties heading.
- Under the Additional Properties heading, click J2C connection factories.
- Click New.
- Specify any properties for the connection factory in the General Properties panel.
- Select the authentication preference.
- Select an alias for Component-managed authentication if any application components with Application or Per connection factory authentication specified in the resource reference are going to be getting connections from this connection factory using the empty-argument getConnection() method. For resources that support XA, we can specify an Authentication alias for XA recovery. If there are no aliases available, or we want to define a different alias:
- Click Apply to save the current settings.
- Click JAAS - J2C authentication data under the Related Items heading.
- Click New.
- Define the properties for the alias in General Properties.
- Click OK.
- Click OK.
- Click the name of the J2C connection factory that we created.
- Under the Additional Properties heading, click Connection pool properties.
- Change any values by clicking on the property name. For more information on the settings for connection pools, refer to the topic, Tuning connection pools, or the topic, Connection pool settings.
- Click OK.
- Click Custom properties under the Additional Properties heading.
- Click any property name to change its value. If the UserName and Password properties are defined, they will be overridden by a component-managed authentication alias that we might have configured.
- Click Save.
Related:
Relational resource adapters and JCA Connection pooling Configure new J2C connection factories Tune connection pools Install enterprise application files with the console Connection pool settings CMP connection factories collection Java EE resource provider or connection factory custom properties collection J2C Connection Factories collection