How to: |
A key part of any business process is the ability to modify or enable data capture at any point in time. A process flow can contain independent taps that are not configured initially with a specific expression. This allows you to modify or activate any tap using the iWay Service Manager Administration Console without having to go back to iWay Designer to modify the original process flow. As a result, you can have multiple deactivated taps in a process flow that serve as placeholders for future use. If the data capture requirement changes or there is a need to monitor more data, these taps can be activated accordingly.
To update taps:
The iWay Service Manager Tools pane opens.
The Views pane opens, as shown in the following image.
Note: The sales.process.tap2 tap was created earlier, but not configured.
The Edit IFL Expression dialog box opens.
_if(_contains(XPATH(TRANSACTION/ProductID),1),_expose (sales.quantity.product1,XPATH(/TRANSACTION/Quantity),db,int),_if (_contains(XPATH(TRANSACTION/ProductID),2),_expose(sales.quantity.product2, XPATH(/TRANSACTION/Quantity),db,int),_if(_contains(XPATH(TRANSACTION/ ProductID),3),_expose(sales.quantity.product3,XPATH(/TRANSACTION/ Quantity),db,int))))
This expression allows you to capture the quantity sold for each product. Using iFL (iWay Functional Language) notation, the expression checks if the ProductID is 1. If this condition is met, the expression exposes the Quantity sold to the sales.quantity.product1 event. If the ProductID is 2, then the expression exposes its Quantity to the sales.quantity.product2 event. Finally, if the ProductID is 3, then the expression exposes the sales.quantity.product3 event.
You are returned to the Views pane, where the new expression is now added to the Expression column for the sales.process.tap2 tap.
Note: You may need to refresh your Web browser after the expression is saved.
You are now able to tap into additional data through the process flow (sales.process) that was configured earlier and generate business events. As the process flow is processing the batched sales transactions, it is triggering the sales.process.tap2 tap, which runs the corresponding expression. As a result, three events are now generated for three product types, which are being processed.
C:\Sales_Demo\sales_data\in
The iWay Service Manager Tools pane opens.
The Views pane opens, as shown in the following image.
The contents of the Events tab are displayed, as shown in the following image.
Note: The new events do not have any associated feeds. However, the previously created events that are already used in the Real Time Line chart do have a default enable feed associated with them as well as the enable.sales.total.graph feed, which was created automatically by the chart.
The iWay Service Manager Tools pane opens.
The Resources pane opens and displays the Gauges tab by default, as shown in the following image.
The Charts tab opens and displays the available charts that can be configured, as shown in the following image.
The Real Time Column Chart configuration pane opens, as shown in the following image. A visual representation of the selected chart (for example, Real Time Column) is displayed on the left. There are five configuration tabs (Sources, Data, Labels, Visuals, and Extras) located on the right. By default, the Sources tab is selected.
The Data tab is used to specify what events will be used to feed the data. Since more than one event will be monitored using the Real Time Line chart, you must manually type in the events instead of selecting a single event from the Events drop down list.
Parameter |
Value |
---|---|
Events |
sales.quantity.product1|sales.quantity.product2|sales.quantity.product3 |
Aggregation |
SUM |
History |
600000 (Default) |
Data Range |
5 |
Parameter |
Value |
---|---|
Title |
Product Sales |
Subtitle |
Comparative Sales |
X Axis Name |
Time Line |
Y Axis Name |
Total Sales |
Notice that as you type values in the various label fields, the chart on the left updates to reflect the new data you entered.
The Save as Portlet dialog box opens.
You are returned to the main Resources pane where the Portlets tab is now selected.
The new Real Time Column chart (ProductSalesGraph) is now added to the table.
The ProductSalesGraph window opens and displays the Real Time Column chart you configured.
The Real Time Column chart contains multiple vertical columns, which represent the earlier runs of data (total product sales). This data will be updated using the two second interval that was configured. You can also click the name of the chart in the title bar to view the chart in full-screen mode.
C:\Sales_Demo\sales_data\in
The Real Time Column chart will update in a few seconds to reflect new data.
iWay Software |