7 Monitoring Connection Manager Activity

Learn how to monitor Oracle Communications Billing and Revenue Management (BRM) Connection Managers (CMs).

Topics in this document:

Manually Checking the Status of the CM

You can monitor the operation of the CM by checking the status at regular intervals and comparing the results with what you expect.

To check the status of the CM:

  1. Find the process ID (PID) of the main CM process by looking in the pid file for the CM in BRM_home/sys/cm.

  2. Enter the following command:

    kill -USR1 PID_of_CM

BRM displays a report on the CM, which shows information about the master CM such as the version and the number of children. If there are CM children, the rest of the reports consist of a single line for each child showing the state, the IP address and port for the application, and the IP address and port of the current DM connection.

Table 7-1 describes the state values:

Table 7-1 CM State Values

Value Description

1

Reading from (or waiting to read from) the application

2

Starting to process the operation

3

Facilities Module processing in progress (if going to FM)

4

Facilities Module processing done, sending response

5

Finding DM address (if going to DM)

6

Sending operation to DM

7

Waiting on DM

8

Forwarding DM response to application

9

Cleaning up after the operation

10

Shutting down the child CM

11

Starting the child CM

Enabling Java PCM Clients to Use Operating System TCP/IP Keepalive Parameters

If a connection for a Java PCM client is not in use for some time, a BAD_READ error may result. If this becomes a recurring problem, you can enable the client to use the underlying operating system TCP/IP keepalive parameters such as keepalive time, keepalive interval, and keepalive retry.

To enable Java PCM clients to use operating system TCP/IP keepalive parameters:

  1. Open the Infranet.properties file of the Java PCM client.

    A Java PCM client is any Java client application that communicates with BRM by using the Java Portal Communication Module (Java PCM) API (for example, Developer Center, or a custom application).

  2. Add the following entry:

    infranet.pcp.socket.keepalive.enabled=true
    • true enables Java PCM clients to use operating system TCP/IP keepalive parameters.

    • false prevents Java PCM clients from using operating system TCP/IP keepalive parameters.

    By default, BRM prevents Java PCM clients from using operating system TCP/IP keepalive parameters.

  3. Save and close the file.

Setting the CM Log Time Resolution

By default, the time resolution in CM log files is in seconds. If you need a higher resolution to help diagnose performance issues, change the resolution to milliseconds.

To set the CM log time resolution:

  1. Open the CM pin.conf file in BRM_home/sys/cm.

  2. Change the value of the cm_logformat entry from 0 to 1, where 0 sets the log time resolution to seconds and 1 sets the log time resolution to milliseconds.

  3. Save and close the file.

  4. Stop and restart the CM.

Setting a Timeout Value for Requests Sent to the CM

BRM client applications contain a parameter for setting the maximum timeout of BRM transactions. If a timeout occurs, the client side of the operation is canceled, and the transaction is not committed to the database. This guarantees that transactions are not committed when timeouts occur and writes to the database do not occur at any point during the transaction.

To specify a timeout value, configure your client applications as follows:

  • For BRM client applications that use a pin.conf file:

    1. Open the pin.conf file in a text editor.

      By default, the pin.conf file is in BRM_home/apps/application_name, where application_name is the name of the application, such as pin_billd.

    2. Add the following entry to the file:
      - nap pcm_opcode_timeout_in_usecs milliseconds

      where milliseconds is the number of milliseconds to wait before ending the transaction.

    3. Save and close the file.
  • For BRM client applications that use an Infranet.properties file:

    1. Open the Infranet.properties file in a text editor.

      By default, the Infranet.properties file is in BRM_home/apps/application_name.

    2. Add the following entry to the file:
      - infranet.PcmOpcodeTimeoutinUsecs milliseconds

      where milliseconds is the number of milliseconds to wait before ending the transaction.

    3. Save and close the file.
  • For Java Connector Architecture (JCA) Resource Adapter:

    1. Open the Adapter deployment descriptor (ra.xml) file in a text editor.

      Note:

      By default, the ra.xml and weblogic-ra.xml files are packaged along with the adapter archive (RAR) file.

    2. Set the following parameter in the file:

      PcmTimeout milliseconds

      where milliseconds is the number of milliseconds to wait before ending the transaction. The default value is 0, which means JCA waits infinitely for the response from CM.

    3. Save and close the file.

    4. Open the Oracle WebLogic Server deployment descriptor (weblogic-ra.xml) file in a text editor.

    5. Repeat steps 2 and 3.

Note:

The timeout value specified in the files is used for all open connections. If a timeout value is set for a connection in the application itself, that value overrides the value in the files.

For information on setting timeout values for each connection in your custom client applications, see "Implementing Timeout for Requests in Your Application" and "Specifying a Timeout Value for Requests" in BRM Developer's Guide.

Configuring Multilevel CM Timeout for Client Requests

You can configure the CM to use two timeouts for handling client requests:

  • A short (suspect) timeout

  • A long (failover) timeout

A Short (Suspect) Timeout

When this timeout period expires, the request for the DM connection is placed in a suspect state, the current transaction is stopped, and the request is returned to the client with the PIN_ERR_TIMEOUT and PIN_ERRCLASS_SYSTEM_SUSPECT errors.

To configure the suspect timeout:

  1. Open the CM configuration file (BRM_home/sys/cm/pin.conf) in a text editor.

  2. Add the following entry to the file:

    pcm_suspect_timeout_in_msecs milliseconds

    where milliseconds is the number of milliseconds in the suspect timeout period.

    Note:

    The value of this entry must be smaller than the value of the pcm_timeout_in_msecs entry.

  3. Save and close the file.

A Long (Failover) Timeout

When this timeout period expires, the CM returns a PIN_ERR_TIMEOUT error to the client. Current timeouts in BRM terminate the client side of the operation, and the database operation is rolled back only after its execution is completed. In a high-availability system with multiple DMs, the CM connects to the secondary DM to process the requests.

To configure the failover timeout:

  1. Open the CM configuration file (BRM_home/sys/cm/pin.conf) in a text editor.

  2. Add the following entry to the file:

    - nap pcm_opcode_timeout_in_usecs milliseconds

    where milliseconds is the number of milliseconds in the failover timeout period.

    Note:

    The value of this entry should be larger than the value of the pcm_opcode_timeout_in_usecs entry.

  3. Save and close the file.