16 Monitoring and Managing Oracle BAM

This chapter describes how to monitor and manage Oracle Business Activity Monitoring (Oracle BAM) to keep the system running optimally.

This chapter includes the following sections:

16.1 Understanding Oracle BAM Monitoring and Management

Oracle BAM is monitored using the BAM Composer, the Oracle Enterprise Manager Fusion Middleware Control, and Oracle User Messaging Service.

You monitor continuous queries and viewsets on the Administrator page in BAM Composer.

You monitor and manage several aspects of Oracle BAM using Oracle Enterprise Manager Fusion Middleware Control, including MBean properties, performance metrics, log files, web services, and the Oracle User Messaging Service.

You enable the BAM Diagnostic Framework by setting three MBean properties in Fusion Middleware Control. To view the diagnostic information, you use the diagnostic data objects as you would any BAM data objects.

16.2 Monitoring Continuous Queries

Use the Continuous Query Monitoring page to monitor all continuous queries across different projects in a BAM server instance.

See Creating Business Queries for more information about continuous queries.

To monitor continuous queries:

  1. Go to the Administrator page.
  2. Click Continuous Queries Monitoring.

    The Continuous Queries Monitoring tab opens.

  3. Select a Project or accept the default of All to monitor queries for all projects.
  4. Select a Status or accept the default of All to monitor queries with all statuses. Statuses are:
    • Registering — A newly saved query is being registered.

    • Deactivated — A query remains in BAM but does not fetch data.

    • Activating — A newly saved or activated query is becoming active.

    • Active — A query is fetching data.

    • Deactivating — A query is becoming inactive.

    • Dropping — A query is being dropped (deleted) from BAM.

    • Pre-migrating — A query is being prepared for migration to another BAM server.

    • Migrating — A query is being migrated to another BAM server.

  5. Examine the information in the columns of the Query Details table:
    • Project — The name of the BAM project to which the query belongs.

    • Query — The name of the query.

    • Status — The status of the query, such as Active, Deactivated, and so on.

    • Server — The name of the BAM server on which the query runs.

    • Statement — The SQL statement for the query.

  6. To activate a deactivated query, check the box for the query row and click Activate Query.

    Continuous queries are active by default.

  7. To deactivate an active query, check the box for the query row and click Deactivate Query.
  8. To drop a query and delete it from the BAM project, check the box for the query row and click Drop Query.
  9. To update the Query Details table, click Refresh.
  10. Click the X on the Continuous Queries Monitoring tab to close it.

16.3 Monitoring Viewsets

A master viewset holds the query results in a data snapshot and the changes since the last snapshot for business views in the same project that use the same query and row security filters.

The first view opened in a dashboard for a given query creates the master viewset. Opening other views that use the same query creates slave viewsets.

Viewsets minimize time-consuming query reexecution and ensure that views are incrementally updated using a push-based mechanism.

You should monitor the number of currently open master viewsets and the number of slave viewsets sharing each master. This can help you determine the current load on the Oracle BAM system.

To monitor viewsets:

  1. Go to the Administrator page.
  2. Click Viewset Monitoring.

    The Viewset Monitoring tab opens.

  3. Select a Project or accept the default of All to monitor viewsets for all projects.
  4. Examine the information in the columns of the Viewset Details table:
    • Project — The name of the BAM project to which the viewset belongs.

    • Query — The name of the query on which the viewset is based.

    • Viewset ID — The unique ID for the viewset.

    • CQL Query — The name of the CQL query on which the viewset is based.

    • Viewset Type — The viewset type: Active, Tactical KPI, or RealTime KPI.

    • Expiry Time (secs) — The time left before the viewset expires unless pinged by BAM data control.

    • Last Pinged — The last time BAM data control pinged this viewset.

    • Message Selector — The common message selector filter on the JMS topic to which the BAM report cache publishes and BAM data control subscribes, which identifies viewset IDs.

  5. To close a viewset and delete it from the BAM project, check the box for the viewset row and click Close Viewset.
  6. To update the Viewset Details table, click Refresh.
  7. Click the X on the Viewset Monitoring tab to close it.

16.4 Monitoring the State of the BAM Server and Services

The Oracle BAM Server and its services can be monitored to troubleshoot any operations issues in real time.

You can view the current state of the Oracle BAM server and its services at this URL:

http://host:port/oracle/bam/server

For example:

http://www.example.com:7001/oracle/bam/server

The default Oracle BAM server port is 7001. This may be different from the Oracle WebLogic Server administration server port.

The Description table displays the following information:

  • Server Name — The name of the Oracle WebLogic Server managed server dedicated to Oracle BAM, for example bam_server1.

  • Server State — The current state of the server, such as Running or Stopped.

  • Server Version — The release version of the BAM server.

  • Build Number — The build number of the BAM server.

  • Build Label — The build label, which is the name of the deployment corresponding to the Oracle BAM application on the Oracle WebLogic Server managed server.

  • Build Date — The build date of the BAM server.

  • Schema Version — The schema version of the BAM server. The schema controls the structure of BAM data objects.

The Service Status table displays the states, such as Running or Stopped, of the Persistence, Report Cache, Alerts Engine, and Enterprise Message services.

Clicking the Persistence link displays the number of Inserts, Updates, and Deletes and the number of sent and received notifications for those operations. Click the browser Back button to return to the Description and Service Status tables.

Note:

BAM Composer has limited functionality on session replication. For example, in a clustered server environment, if Server1 is responding to user X's requests, user X has opened several tabs and pop-ups. On failure of Server1, Server2 should respond to further requests from user X and entire session objects like http session, opened tabs, and pop-ups should work seamlessly. But due to limited functionality, only http session is replicated to Server2, opened tabs and popup are closed and application displays the Home page. Subsequent requests from user X are handled by Server2. On clicking any user interface elements during session replication time, the end user may get 500 or 503 errors.

Refresh the page to proceed further.

16.5 Configuring BAM Server MBean Properties

Use Fusion Middleware Control to configure MBean properties for the Oracle BAM server.

To set BAM MBean properties:

  1. Log in to the Fusion Middleware Control console.
  2. In the Target Navigation pane, expand the Business Activity Monitoring node.
  3. Double-click the BamServer node under the Business Activity Monitoring node.

    For example, the BamServer node might be BamServer (bam_server1).

    The BAM Properties page appears, displaying BAM System Settings and Alert Engine properties.

  4. To display other BAM properties, click More BAM Advanced Configuration Properties at the bottom of the page.

    The System MBean Browser opens, displaying BEAMServerConfig properties on the Attributes tab. All properties have descriptions and most have values.

  5. Edit the Value of each property you wish to change, then click Apply.

    To undo all unapplied changes, click Revert.

  6. Restart the Oracle WebLogic Server admin server and managed servers. For more information, see Starting and Stopping Servers in Administering Server Startup and Shutdown for Oracle WebLogic Server.

16.6 Using the BAM Diagnostic Framework

You enable the BAM Diagnostic Framework by setting three MBean properties in Fusion Middleware Control. To view the diagnostic information, you use the diagnostic data objects as you would any BAM data objects.

The following BAM MBean properties control the BAM diagnostic framework:

  • DiagnosticEnabled — Enables the diagnostic framework if set to true. The default is false.

  • DiagnosticLevel — Sets the diagnostic logging level to INFO or DEBUG. The DEBUG level gives granular diagnostic logs. The default is INFO.

  • DiagnosticComponents — Specifies the BAM components for which diagnostic messages are logged. Specify a comma-separated list of any of the following components:

    • ADF — The Application Development Framework, which provides lower-level components upon which Oracle BAM is based.

    • DC — Data Control, which manages how data flows into data objects and queries.

    • RC — The Report Cache, which receives and caches query results, then pushes the results to dashboards and the alert service.

    • CQS — The Continuous Query Service, which delivers continuous query results.

    • ALERTS_ENGINE — The Alert Service, which compares query results to alert events and conditions and executes the corresponding alert actions and notifications.

    • COMPOSER — BAM Composer, the browser-based BAM interface.

    • COMMON_QUERY — The Common Query Service, which delivers non-continuous query results.

    By default, all components are included.

To set these properties, see Configuring BAM Server MBean Properties.

All diagnostic messages are saved to BASE_METRICS, a simple data object. Granular details pertaining to the Report Cache, the Alert Service, and the Continuous Query Service are persisted to the module-specific derived data objects RC_METRICS, ALERTS_METRICS, and CQS_METRICS. These data objects are created when the diagnostic framework is enabled.

You can use these diagnostic data objects in the same way you use other data objects. For example, you can create queries, views, alerts, and dashboards to monitor the diagnostic data.

16.7 Monitoring Oracle BAM Performance

The performance of Oracle BAM is reflected in metrics and statistics. There are Performance Summary pages with appropriate metrics for Oracle BAM Server.

To monitor BAM performance:

  1. Log in to the Fusion Middleware Control console.
  2. In the Target Navigation pane, expand the Business Activity Monitoring node.
  3. Right-click the BamServer node under the Business Activity Monitoring node.

    For example, the BamServer node might be BamServer (bam_server1).

  4. Select the Monitoring > Performance Summary menu item.

    The Performance Summary page appears.

  5. Click Show Metric Palette to display the Metric Palette.
  6. Click the arrow to the left of a metric folder to expand the folder. Keep expanding folders until you see individual metrics with check boxes.
  7. Check each metric you wish to display. Charts for each selected metric appear in the Performance Summary pane.

Descriptions of each metric are available in the Oracle Enterprise Manager Oracle Fusion Middleware Metric Reference Manual.

16.8 Tuning Oracle BAM Performance

If Oracle BAM is running more slowly than expected, you can tune it in these ways:

  • If throughput of data into a data object from an Enterprise Message Source or other source is slow, create an index column for the primary key column. See Adding Index Columns for more information.

  • If Oracle BAM is running slowly and out-of-memory exceptions occur, adjust USER_MEM_ARGS to increase the memory allocated. Use the following command (in csh) with the -Xms2048m and -Xmx2048m arguments:

    setenv USER_MEM_ARGS "-Xms2g -Xmx2g -XX:NewSize=1g -XX:+CMSConcurrentMTEnabled -XX:+UseConcMarkSweepGC"
    

For more tips on how to tune Oracle BAM performance, see "Tuning Oracle Business Activity Monitoring" in Tuning Performance.

16.9 Monitoring Oracle BAM Logs

Use Fusion Middleware Control to monitor Oracle BAM logs.

To monitor BAM logs:

  1. Log in to the Fusion Middleware Control console.
  2. In the Target Navigation pane, expand the Business Activity Monitoring node.
  3. Right-click the BamServer node under the Business Activity Monitoring node.

    For example, the BamServer node might be BamServer (bam_server1).

  4. Select the Logs > View Log Messages menu item.

    The Log Messages page appears.

  5. To display a list of BAM log files, click Target Log Files.

    The Log Files page appears.

  6. To View a log file, select the file and click View Log File.

    The View Log File page appears.

  7. To view specific types of messages, specify search criteria and click Search.

16.10 Monitoring Oracle BAM Web Services

Oracle BAM provides DataObjectDefinition, DataObjectOperationsByName, DataObjectOperationsByID, DataObjectOperations10131, and ManualRuleFire web services.

For more information, see Using Oracle BAM Web Services.

Use Fusion Middleware Control to monitor Oracle BAM web services.

To monitor BAM web services:

  1. Log in to the Fusion Middleware Control console.
  2. In the Target Navigation pane, expand the WebLogic Domain node.
  3. Expand the node for the domain under the WebLogic Domain node.

    For example, the domain node might be soainfra.

  4. Right-click the BamServer node under the domain node.

    For example, the BamServer node might be bam_server1.

  5. Select the Web Services menu item.

    The Web Services page appears.

  6. Select the Java EE tab.

You can see the following statistics in the Java EE Web Services table: Invocation Count, Response Count, Response Error Count, Average Execution Time (ms), and Average Response Time (ms).

16.11 Managing Oracle BAM Availability

Oracle BAM high availability is based on Oracle WebLogic Server high availability.

Note:

Make sure that times on all Oracle BAM Server instances in a cluster are synchronized to UTC. Time differences can result in event losses for continuous queries.

Oracle BAM Server instances can be started and stopped using Fusion Middleware Control.

Restarting is required for any configuration changes made in Fusion Middleware Control properties pages for Oracle BAM or its configuration files.

To start or stop Oracle BAM servers in Fusion Middleware Control:

  1. Log in to the Fusion Middleware Control console.
  2. In the Target Navigation pane, expand the Business Activity Monitoring node.
  3. Right-click the BamServer node under the Business Activity Monitoring node.

    For example, the BamServer node might be BamServer (bam_server1).

  4. Select the Control menu item.

    Start Up starts the server.

    Shut Down shuts down the server.

    Note:

    Do not use Start Up alone to restart the component. To restart the component, you must stop the component using Shut Down before using Start Up to start the component or an error occurs.

16.12 Configuring Oracle User Messaging Service

Oracle User Messaging Service (UMS) must be configured properly in Fusion Middleware Control to send email notifications for alerts.

The UMS email driver monitors the outbound email account configured for Oracle BAM Server for any delivery failures, including rejected emails. Email delivery failure notifications are asynchronous: there is no definite time within which email rejection notification is received.

To make UMS work with SSL, remove javax.net.ssl.trustStore from the JVM argument in the setDomainEnv.sh file for your Oracle WebLogic Server domain.

To configure UMS:

  1. Log in to the Fusion Middleware Control console.

  2. Make sure that the BAM Server is running:

    1. In the Target Navigation pane, expand the Business Activity Monitoring node.

    2. Right-click the BamServer node under the Business Activity Monitoring node.

      For example, the BamServer node might be BamServer (bam_server1).

    3. Select Control > Start Up from the menu.

      If the BAM Server is not running, it is started. If it is already running, an Application already running error message appears.

  3. In the Target Navigation pane, expand the User Messaging Service node.

  4. Right-click the usermessagingdriver-email (bam_server1) node.

  5. Select the Email Driver Properties menu item.

    The Email Driver Properties page appears.

  6. Set or verify the following properties. Email addresses and mail server names are example values.

    • Use Default Sender Address — EMAIL:example@example.com

    • E-mail Receiving Protocol — IMAP

    • Connection Retry Limit — –1

    • Message Cleanup Frequency — 600

    • Auto Delete — unchecked

    • Debug Mode — unchecked

    • Message Retrieval Frequency — 30

    • Message Folder — INBOX

    • Outgoing Mail Server — mailserver.example.com

    • Outgoing Mail Server Port — 465

    • Outgoing Mail Server Security — SSL

    • Default From Address — example@example.com

    • Outgoing Username — example@example.com

    • Outgoing Password — select clear text password from the drop-down]

    • Incoming Mail Server — mailserver.example.com

    • Incoming Mail Server Port — 993

    • Enable SSL — checked

    • Incoming Mail IDs — example@example.com

    • Incoming User IDs — example@example.com

    • Incoming Passwords — select clear text password from the drop-down]

    • Message Processing Chunk S — 100

    • Disable Plain-Text Authentic — unchecked

  7. Click Apply to save the property changes.

  8. In the Target Navigation pane, expand the Business Activity Monitoring node.

  9. Double-click the BamServer node under the Business Activity Monitoring node.

    For example, the BamServer node might be BamServer (bam_server1).

    The BAM Properties page appears, displaying BAM System Settings and Alert Engine properties.

  10. Type the default sender address as the value for the Sender Email ID property. For example, type example@example.com.

  11. Click Apply to save the change.