6 Modifying Applications to Work with AMM

Learn how to modify your custom client applications and custom reports to work with the Oracle Communications Billing and Revenue Management (BRM) Account Migration Manager (AMM) software.

Topics in this document:

Enabling ECE to Rate Events during Account Migration

When you enable ECE to rate events during account migration, the AMM business events listed in Table 6-1 automatically notify ECE that an account migration job is occurring. They enable ECE to:

  • Track the status of the migration

  • Notify BRM if ECE fails to clear its rated event data store before the migration begins (a migration prerequisite)

  • Continue rating events while the accounts are migrated

  • Update its information about the target database schema for successfully migrated accounts

Table 6-1 ECE Response to AMM Business Events

AMM Business Event ECE Response

HoldCDRProcessing

  1. Gets the migration job ID, the source database schema, and the target database schema from this event.

  2. Queries the BRM database for the list of accounts that belong to the migration job.

  3. Waits for all existing rated events associated with those accounts to be extracted from the Oracle NoSQL database data store.

  4. Does one of the following:

    If the extraction succeeds:

    – Assigns the IN_ACCOUNT_MIGRATION status to the accounts.

    – Updates their target database schema information.

    – Sends an ACKHoldCDRProcessing acknowledgment to the BRM acknowledgment queue.

    – Continues rating incoming usage events for the migrated accounts but does not extract them from the Oracle NoSQL database data store.

    If the extraction fails, ECE sends a NACKHoldCDRProcessing acknowledgment to BRM, and BRM does not migrate the accounts.

MigrateAcct

Sends an ACKMigrateAcct acknowledgment to the AMM acknowledgment queue.

MigrateSource

Sends an ACKMigrateSource acknowledgment to the AMM acknowledgment queue.

MigrateDestination

Sends an ACKMigrateDestination acknowledgment to the AMM acknowledgment queue.

ResumeCDRProcessing

  1. Gets the migration job ID, the source database schema, and the target database schema from this event.

  2. Queries the BRM database for the list of accounts that belong to the migration job.

  3. Removes the IN_ACCOUNT_MIGRATION status from those accounts.

  4. Loads all the rated events that were generated while the accounts' status was IN_ACCOUNT_MIGRATION into the new target database schema.

To enable ECE to rate events during account migration:

  1. Configure the definition of your system's AMM controllers for ECE:

    1. Go to the BRM_home/sys/amt directory and open the Infranet.properties file in a text editor.

    2. Verify that the following entry is set to true:

      controller_1_event_generation=true
    3. If more than one controller is defined in the file, ensure that each controller's controller_controller_number_event_generation= entry is set to true.

    4. Save and close the file.

      The change takes effect the next time the pin_amt utility is run. For more information, see the discussion about that utility in BRM System Administrator's Guide.

  2. Configure ECE to use the AMM acknowledgment queue.

  3. Verify that Customer Updater is correctly configured for your system and running.

    ECE receives AMM business events from the BRM Account Synchronization DM database queue through Customer Updater. Because account migration involves multiple database schemas, Customer Updater must be configured to support all the database schemas in your system. It must also be configured to send AMM-related acknowledgments from ECE to your system's AMM acknowledgment queue.

  4. Verify that BRM Gateway is correctly configured for your system and running.

  5. Verify that Rated Event Formatter is correctly configured for your system and running.

Configuring ECE to Use the AMM Acknowledgment Queue

The AMM acknowledgment queue is used to send AMM-related acknowledgments from ECE to BRM; it is an Oracle AQ database queue on the BRM system.

To configure ECE to use the AMM acknowledgment queue:

  1. Access the ECE configuration MBeans:

    1. Log on to the driver machine.

    2. Start the ECE charging servers (if they are not started).

    3. Connect to the ECE charging server node enabled for JMX management.

      This is the charging server node set to start CohMgt = true in the ECE_home/oceceserver/config/eceTopology.conf file.

    4. Start a JMX editor that enables you to edit MBean attributes, such as JConsole.

    5. In the editor's MBean hierarchy, find the ECE configuration MBeans.

  2. Expand the ECE Configuration node.

  3. Expand charging.connectionConfigurations.oracleQueueConnection.

  4. Expand Attributes.

  5. Set the amtAckQueueName attribute to the fully qualified name of the acknowledgment queue to which the pin_amt utility listens to AMM-related acknowledgment events:

    schema.ammAcknowledgmentQueue

    where:

    • schema is the name of the BRM database schema in which the AMM acknowledgment queue resides.

    • ammAcknowledgmentQueue is the name of the AMM acknowledgment queue.

    For example:

    PIN01.ECE_AMT_ACK_QUEUE
  6. Save your changes.

Modifying Custom Client Applications for AMM

Custom client applications that connect to a specific database schema and try to access an object based on a POID may receive a PIN_ERR_INVALID_OBJ error if the object was migrated to another database schema. You must modify any custom client applications to handle that error and then perform a global search to find the object's correct location.

To obtain the correct POID of an object, modify your application to call the PCM_OP_GLOBAL_SEARCH opcode from its exception handling routine.

This example shows a call to the PCM_OP_GLOBAL_SEARCH opcode when the PIN_ERR_INVALID_OBJ error is returned from the Oracle DM:

/* Error? */

if (PIN_ERR_IS_ERR(ebufp)) {
PIN_ERR_LOG_EBUF(PIN_ERR_LEVEL_ERROR,
"sample_read_obj_search error", ebufp);
}
/* Call the DM to do a global search.*/

PCM_OP(ctxp, PCM_OP_GLOBAL_SEARCH, 0, flistp, &r_flistp, ebufp);

return;

The following opcodes return the PIN_ERR_INVALID_OBJ error when a POID specified in an input flist is invalid:

  • PCM_OP_READ_OBJ

  • PCM_OP_READ_FLDS

  • PCM_OP_WRITE_FLDS

  • PCM_OP_INC_FLDS

  • PCM_OP_DELETE_OBJ

  • PCM_OP_DELETE_FLDS

  • PCM_OP_TRANS_OPEN

Modifying Custom BRM Reports for AMM

After account migration, any custom BRM reports created prior to Infranet Release 6.2 ServicePak1 might retrieve and process duplicate data from your source and destination database schemas. For example, if an account object is migrated from database schema 0.0.0.1 to database schema 0.0.0.2, your report might retrieve the account object from both database schemas.

To prevent this, use the Oracle Business Intelligence Publisher to add the following line to the WHERE clause of each custom report's query:

TABLE_T.POID_DB  >  0

where TABLE_T satisfies these conditions:

  • It is a database table used by the report.

  • It is one of the tables moved from the source database schema to the destination database schema when account data is migrated.

  • It is associated with every record the report must retrieve.

    Note:

    If a single table does not satisfy the last condition, add the same line for several tables that together satisfy the last condition.

AMM Return Codes and Messages

AMM uses the return codes and messages shown in Table 6-2. To automate account migration, you can modify your external application to check for the following return codes and respond appropriately.

Table 6-2 AMM Return Codes and Messages

Return Code Number Return Code Return Message

100

CONTROLLER_STARTED_SUCC

controller is started

101

CONTROLLER_STOPPED_SUCC

controller is stopped

102

CONTROLLER_PAUSED_SUCC

paused controller

103

CONTROLLER_CONTINUED_SUCC

continued controller

104

CONTROLLER_UP_SUCC

controller status is up

105

CONTROLLER_DOWN_SUCC

controller status is down

106

SUBMIT_JOB_SUCC

submitted job

107

DELETE_JOB_SUCC

deleted job

108

PURGE_DATABASE_SUCC

purged database

109

ENABLE_JOB_SUCC

enabled job

110

REPORT_SUCC

generated report

111

ENABLE_BATCH_SUCC

enabled batch

200

CONTROLLER_RUNNING_ERROR

ERROR: controller is already running

201

CONTROLLER_PAUSED_ERROR

ERROR: controller is already paused

202

CONTROLLER_SPEC_ACCESS_ERROR

ERROR: controller specification does not exist

203

CONTROLLER_COMM_ERROR

ERROR: controller cannot be reached

204

SEARCH_SPEC_IO_ERROR

ERROR: account search specification could not be accessed

205

OPERATION_ROLLBACK_ERROR

ERROR: operation rollback

206

SEARCH_SPEC_PARSE_ERROR

ERROR: account search specification cannot be parsed

207

OPERATION_PERM_ERROR

ERROR: operation not permitted for current user OR job_id/batch_id does not exist

208

CONTROLLER_UNKNOWN_HOST_ERROR

ERROR: controller host not found

209

CONTROLLER_PROCESS_ERROR

ERROR: controller process could not be created

210

REPORT_PROCESS_ERROR

ERROR: external process interruption

211

REPORT_SCRIPT_ACCESS_ERROR

ERROR: reporting tool not found or report type does not exist

212

OPT_PARAM_REQ_ERROR

ERROR: one optional parameter is required

213

CONFIG_FILE_ACCESS_ERROR

ERROR: configuration file cannot be accessed

214

INIT_ERROR

ERROR: could not create new object

215

EMPTY_RESULTSET_ERROR

ERROR: account search resulted in 0 accounts, job submission failed

216

CONVERSION_CLASS_LOAD_ERROR

ERROR: dynamic loading of custom Conversion class failed