Different TIBCO BusinessEvents processing units and agents within the processing units have specialized roles in a Cache OM architecture. The following sections provide more detail.
Agent group IA1 has three active agents, and agent group IA2 has two load balanced agents and one standby agent for fault tolerance. Each agent group is listening on a different destination. See
Load Balancing and Fault Tolerance of Inference Agents for details.
A cache cluster (or metaspace, to use the TIBCO BusinessEvents DataGrid term) is a logical entity that provides the following services:
You define the cluster member machines, processing units, and agents in the Cluster Deployment Descriptor (CDD) which is an XML file, configured in the CDD editor in TIBCO BusinessEvents Studio. See
CDD Configuration Procedures in
TIBCO BusinessEvents Administration.
An inference agent executes rules according to the rule agenda created using the Rete network. In Cache OM systems, inference agents are connected to the cache cluster, enabling fault tolerance of engine processes and cache data, as well as load balancing (with queues).
At design time, you configure an inference agent class with a selection of rules from the project, and a selection of destinations, and, as needed, a selection of shutdown and startup functions. You can deploy multiple instances of an agent class as an
agent group. Each agent in a group runs in a different processing unit, concurrently, to enable load balancing when events come from a queue, and fault tolerance.
The purpose of cache agents is to store and serve cache data for the cluster. The built-in cache provider, TIBCO BusinessEvents DataGrid, calls such agents
seeders. The Oracle Coherence cache provider calls them
storage nodes.
Dedicated cache agent PUs are non-reasoning agents (one per PU). Cache agents are responsible for object management. They participate in distribution, partitioning and storage of the objects in the cluster.
The JVM may use a lot more memory than expected because it often defers garbage collection. If JVM uses a large proportion of the physical memory available, then TIBCO BusinessEvents DataGrid may not perform well due to swapping. Because JVM and TIBCO BusinessEvents DataGrid are of the same process, they contend for the same addressable space. If the JVM uses a large proportion of the addressable space (which may occur on 32-bit systems where the addressable space is 4GB or less), then out of memory errors will occur in TIBCO BusinessEvents DataGrid. To avoid this situation, set the heap limit of JVM (such as Xmx-512m) to limit the amount of memory used by the JVM so it does not compete with TIBCO BusinessEvents DataGrid.
With Oracle Coherence as the cache provider, the amount of memory you need for cache agents depends on factors such as how many objects you have, their object management configuration, and whether you are using limited or unlimited cache.
You must find an appropriate balance for your projects between too little memory, which leads to too much time spent in garbage collection, and too much memory, which leads to longer garbage collection cycles. The optimal heap size depends on factors such as how much data is kept in each cache agent, how many cache agents are used, and whether the cache is limited or unlimited.
For example, if you use a JVM heap size of 1024 MB (1GB), in order to minimize the impact of garbage collection, about 75% of the heap can be used to store cache items, which means about 768 MB per heap. The other 25% is then available for garbage collection activities.
Query agents are available only with TIBCO BusinessEvents Event Stream Processing add-on software. Query agents use an SQL-like query language. You can query data that is in the cache. You can also query data arriving in events, known as event stream processing or ESP.
A query agent is a non-reasoning agent. It has read-only access to the underlying objects in the cache cluster. A query agent can execute rule functions, but not rules. You can mix query agents and inference agents within one node as desired.
Dashboard agents are available only with TIBCO BusinessEvents Views add-on software. They are similar to a query agent in that their role is to generate information based on queries. The information is made available to the TIBCO BusinessEvents Views dashboard. See
TIBCO BusinessEvents Views Developer’s Guide for details.