Copyright © TIBCO Software Inc. All Rights Reserved
Copyright © TIBCO Software Inc. All Rights Reserved


Chapter 4 Working with Rulebases : Creating a Rule

Creating a Rule
The following example uses the Process microagent as a representative data source.
To create a new rule:
1.
Figure 11 Rule Editing Screen
2.
3.
Select the Process microagent. The Methods panel displays the methods for the microagent.
4.
Select the getProcess method. The Description panel displays a detailed description of the method, including arguments and return values. The Arguments panel displays the fields for method arguments and a data interval.
5.
In the Process Name field, type rvd.*.
When invoked, the getProcess() method returns information about all running processes. It takes the name of a specific process as an optional argument and with no argument specified, the entire process table is returned. In this case, the method returns all process instances that begin with the string rvd.
The getProcess() method is a synchronous method. When the rule is active, the agent subscribes to this method and receives data every 5 seconds, by default. The data interval can be changed, if required. For asynchronous methods, such as Logfile:onNewLine(), no collection interval is required.
6.
Select the name of an existing schedule from the Schedule dropdown list to apply to this rule. This is an optional field. By default, the rule is always active. To know more, see Working with Schedules and Period Groups.
7.
Specify the Over-Ruling value by using the up and down arrow keys. This is an optional field. For know more about Over-Ruling feature, see TIBCO Hawk Concepts Guide.
8.
Click the Apply & Add Test button to save the changes and proceed to the defining the test process. Refer Creating a Test for further instruction.
9.
Click the Apply Changes button to save the current changes. These changes are available in the browser till the user logs out.
The rule is now configured to use the getProcess() method of the Process microagent as a data source. The Rule screen displays COM.TIBCO.hawk.Process:getProcess(Name=rvd.*):5 in the title bar.

Copyright © TIBCO Software Inc. All Rights Reserved
Copyright © TIBCO Software Inc. All Rights Reserved