Hitachi

uCosminexus Application Server Application Setup Guide


4.2.2 Defining the DB Connector properties

You define the DB Connector properties. You can also define the DB Connector properties after deploying the DB Connector. Note that if you want to change the properties of a DB Connector that is already deployed, change the properties when the applicable DB Connector is not running.

For details on property settings, see 3.5 Property settings using the property file. The following subsections define the DB Connector properties:

Organization of this subsection

(1) Attribute file to be edited

Connector attribute file

(2) Acquiring the attribute file to be edited and setting the attributes

(3) Attribute settings to be edited

The settings for DB Connector properties are described below:

(a) General information of the DB Connector

The following table describes the settings for the general information attributes (<outbound-resourceadapter> tag) of the DB Connector that can be set:

Items

Mandatory

Corresponding tags

Transaction support level

Y

<transaction-support>

Scope of re-authentication support

Y

<reauthentication-support>

Legend:

Y: Mandatory

For details on the property settings, see 4.1.1 Specifications of the HITACHI Connector Property file in the uCosminexus Application Server Application and Resource Definition Reference Guide.

(b) Configuration properties

The following table describes the settings for the configuration properties (<outbound-resourceadapter> - <connection-definition> - <config-property> tag) of the DB Connector:

Items

Corresponding tags

Configuration property name

<config-property-name>

Configuration property data type

<config-property-type>

Configuration property value

<config-property-value>#

#

To clear the configuration property value, specify an empty tag (<config-property-value></config-property-value>).

If the <config-property-value> tag itself is not specified, the configuration property value is not changed.

Repeat the settings under the <config-property> tag for all the configuration properties that you want to define.

Some of the items that you need to set up differ based on the type of imported DB Connector. For details on the properties that can be set in the <config-property> tag, see 4.1.10 Properties that you can specify in the <config-property> tag set up for DB Connector in the uCosminexus Application Server Application and Resource Definition Reference Guide.

Note that when XAOpenString is specified in the <config-property-name> tag and if you execute the cjgetresprop command, the configuration property value (<config-property-value>) will be displayed as follows:

  • When the property value is set up

    The configuration property value (<config-property-value>) is not obtained and <!-- The config-property-value is already set up. --> is displayed.

    To change the value of XAOpenString, add the <config-property-value> tag, and then specify the changed value.

  • When the property value is not set up

    An empty tag (<config-property-value></config-property-value>) is displayed.

    To set up the value of XAOpenString, add the value in the <config-property-value> tag.

For statement pooling operations and notes on using the statement pooling functionality, see 3.14.4 Statement pooling in the uCosminexus Application Server Common Container Functionality Guide.

For details on the examples of configuration property settings for the DB Connector to be used, see (4) Example of configuration property settings.

(c) Runtime properties

The following table describes the settings for the runtime properties (<outbound-resourceadapter> - <connection-definition> - <connector-runtime> tag) of the DB Connector:

Items

Corresponding tags

Property name

<property-name>

Property data type

<property-type>

Property value

<property-value>#

#

To clear a property value, specify an empty tag (<property-value></property-value>).

If the <property-value> tag itself is not specified, the property value is not changed.

Repeat the above settings for all the properties that you want to define.

When you set the property value (<property-value>), the value set as the default property value (<property-default-value>) will not be applied.

Set the following items in the property names (<property-name>):

Property items

Item names of property name (<property-name>)

User name#

User

Password#

Password

Minimum number of connections to be pooled in the connection pool

MinPoolSize

Maximum number of connections to be pooled in the connection pool

MaxPoolSize

Choose a method to check whether a failure has occurred in the connections inside the pool

ValidationType

Interval for periodically checking whether a failure has occurred in the connections inside the pool

ValidationInterval

Retry count when you fail to acquire the connection

RetryCount

Retry interval when you fail to acquire the connection

RetryInterval

Choose whether to output the log

LogEnabled

Period from the last usage of connection until you determine whether to cancel the connection automatically (connection sweeper)

ConnectionTimeout

Interval for canceling the connection automatically (connection sweeper)

SweeperInterval

Choose whether to manage the requests for connection acquisition in a queue when the connections are used up

RequestQueueEnable

Maximum waiting time when the requests for connection acquisition (when the connections are used up) are managed in a queue

RequestQueueTimeout

Choose whether to enable alert output for monitoring the connection pool

WatchEnabled

Interval for monitoring the connection pool

WatchInterval

Threshold value for monitoring the usage state of the connection pool

WatchThreshold

Choose whether to output the connection pool monitoring results to a file

WatchWriteFileEnabled

Interval for operating the connection count adjustment function

ConnectionPoolAdjustmentInterval

Choose whether to enable the warming up function of the connection pool

Warmup

Choose whether to enable the timeout of the network failure detection function

NetworkFailureTimeout

#

When the User, Password is set in the <property-name> tag, and if you execute the cjgetresprop command, the property-value (<property-value>) will be displayed as described below:

  • When the property value is set

    The property value (<property-value>) is not obtained and <!-- The property-value is already set up. --> is displayed.

    To change the value of User and Password, add the <property-value> tag, and then specify the changed value.

  • When the property-value is not set

    An empty tag (<property-value></property-value>) is displayed.

    To set up the value of User and Password, add the value in the <property-value> tag.

For details on the property settings, see 4.1.1 Specifications of the HITACHI Connector Property file in the uCosminexus Application Server Application and Resource Definition Reference Guide.

For connection pooling operations and notes on using the connection pooling functionality, see 3.14.1 Connection pooling in the uCosminexus Application Server Common Container Functionality Guide.

(d) Optional name information

The following table describes the settings for the optional name information (<outbound-resourceadapter> - <connection-definition> - <connector-runtime> - <resource-external-property> tag) of the DB connector:

Items

Mandatory

Corresponding tags

Resource optional name

Y

<optional-name>

Resource authentication method

O

<res-auth>

Resource sharing scope

O

<res-sharing-scope>

Legend:

Y: Mandatory

O: Optional

For details on the property settings, see 4.1.1 Specifications of the HITACHI Connector Property file in the uCosminexus Application Server Application and Resource Definition Reference Guide.

For details on how to use an optional name of the DB Connector, see 4.7 Referencing and changing the resource adapter names registered in the JNDI name space.

(4) Example of configuration property settings

This subsection shows examples of configuration property settings for the following DB Connectors:

(a) When using HiRDB or XDM/RD E2 with DBConnector_HiRDB_Type4_CP.rar

The following table describes an example of configuration property settings when using HiRDB or XDM/RD E2 with DBConnector_HiRDB_Type4_CP.rar:

Table 4‒4: Example of configuration property settings when using HiRDB or XDM/RD E2 as a database (With DBConnector_HiRDB_Type4_CP.rar)

Item names

Example of settings for HiRDB

Example of settings for XDM/RD E2

Description

HiRDB- port-number#

Server-schedule-number-of-the-database-connection-server#

DBHostName

HiRDB-host-name

XDM/RD-E2-host-name

environmentVariables

HiRDB-client-environment-variable-names

HiRDB-client-environment-variable-names

loginTimeout

8

8

encodeLang

--

--

JDBC_IF_TRC

false

false

TRC_NO

500

500

uapName

--

--

LONGVARBINARY_Access

REAL

REAL

SQLInNum

300

300

SQLOutNum

300

300

SQLWarningLevel

SQLWARN

SQLWARN

SQLWarningIgnore

false

false

HiRDBCursorMode

false

false

maxBinarySize

0

0

LONGVARBINARY_AccessSize

0

0

LONGVARBINARY_TruncError

true

true

PreparedStatementPoolSize

10

10

CallableStatementPoolSize

10

10

CancelStatement

true

true

logLevel

ERROR

ERROR

Legend:

-- : Settings are not required

#

You can also specify the environment variable group name (in Windows) or the path of environment variable group setup file (in UNIX) of HiRDB client.

(b) When using HiRDB with DBConnector_HiRDB_Type4_XA.rar

The following table describes an example of configuration property settings when using HiRDB with DBConnector_HiRDB_Type4_XA.rar:

Table 4‒5: Example of configuration property settings when using HiRDB as database (With DBConnector_HiRDB_Type4_XA.rar)

Item names

Example of settings for HiRDB

Description

Environment-variable-group-identifier

DBHostName

HiRDB-host-name

environmentVariables

HiRDB-client-environment-variable-names

XAOpenString

<Environment-variable-group-identifier#1> +

<Path-of-environment-variable-group-setup-file#2>

loginTimeout

8

encodeLang

--

JDBC_IF_TRC

false

TRC_NO

500

uapName

--

LONGVARBINARY_Access

REAL

SQLInNum

300

SQLOutNum

300

SQLWarningLevel

SQLWARN

SQLWarningIgnore

false

HiRDBCursorMode

false

maxBinarySize

0

LONGVARBINARY_AccessSize

0

LONGVARBINARY_TruncError

true

XACloseString

--

XALocalCommitMode

true

PreparedStatementPoolSize

10

CallableStatementPoolSize

10

CancelStatement

true

logLevel

ERROR

Legend:

--: Settings are not required

#1

Specify the value entered in the Description field.

#2

Specify the path of the environment variable group setup file of HiRDB. For details, see 4.1.6 Setting the database connection environment (setting HiRDB) in the uCosminexus Application Server System Setup and Operation Guide.

(c) When using Oracle with DBConnector_Oracle_CP.rar

The following table describes the example of configuration property settings when using Oracle with DBConnector_Oracle_CP.rar:

Table 4‒6: Example of configuration property settings when using Oracle as the database (with DBConnector_Oracle_CP.rar)

Item names

If a URL is not used

If a URL is used

databaseName

Oracle-SID

--

serverName

Oracle-host-name or IP-address

--

portNumber

1521

--

url

--

jdbc:oracle:thin:@//Oracle-Database-host-name-or-IP-address:1521/Oracle-SID

loginTimeout

8000

PreparedStatementPoolSize

10

CallableStatementPoolSize

10

CancelStatement

true

ConnectionIDUpdate

false

logLevel

ERROR

Legend:

--: Settings are not required

(d) When using Oracle with DBConnector_Oracle_XA.rar

The following table describes the example of configuration property settings when using Oracle with DBConnector_Oracle_XA.rar:

Table 4‒7: Example of configuration property settings when using Oracle as the database (with DBConnector_Oracle_XA.rar)

Item names

If a URL is not used

If a URL is used

databaseName

Oracle-SID

--

serverName

Oracle-host-name or IP-address

--

portNumber

1521

--

url

--

jdbc:oracle:thin:@//Oracle-Database-host-name-or-IP-address:1521/Oracle-SID

loginTimeout

8000

sessionTimeout

300

PreparedStatementPoolSize

10

CallableStatementPoolSize

10

CancelStatement

true

ConnectionIDUpdate

false

logLevel

ERROR

Legend:

--: Settings are not required

(e) When using SQL Server with DBConnector_SQLServer_CP.rar

The following table describes the example of configuration property settings when using SQL Server with DBConnector_SQLServer_CP.rar.

Table 4‒8: When using SQL Server as the database

Item names

Example of settings for SQL Server

databaseName

SQL-Server-database-name

serverName

SQL-Server-host-name-or-IP address

applicationName

Name-of-application-to-be-connected-to- SQL-Server

instanceName

Name-of-instance-to-be-connected-to- SQL-Server

lastUpdateCount

true

lockTimeout

-1

loginTimeout

8

portNumber

1433

selectMethod

cursor

sendStringParametersAsUnicode

true

workstationID

Host-name-of-Application Server

xopenStates

false

failoverPartner

Name-of-failover-server-used-in-database-mirroring-configuration

integratedSecurity

false

packetSize

4096

PreparedStatementPoolSize

10

CallableStatementPoolSize

10

CancelStatement

true

logLevel

ERROR

applicationIntent

ReadWrite

multiSubnetFailover

false