Service data analysis is crucial in understanding and optimizing their effective usage. For this reason, functionality to capture and collect statistics related to service data is integrated by default into service-hosting WSO2 products such as the WSO2 Application Server (AS), WSO2 Data Services Server (DSS), WSO2 Business Process Server (BPS), WSO2 Business Rules Server (BRS) etc. Once captured, these statistics are transferred to a data analysis product like WSO2 Business Activity Monitor (BAM) or WSO2 Complex Even Processor for processing and deriving business-critical information.
WSO2 BAM receives data events via its Thrift API. This uses a binary protocol and enables fast data transmission between the service-hosting product and BAM server. BAM's Service Data Agent can be configured early so that the statistics to be extracted from service data can be pre-defined. In the configuration panel, the user can specify the BAM server (Thrift server) related information and properties to be extracted from the service of the service-hosting product. The user should define the Event Stream related parameters uniquely identified by a name and a version.
The service data publishing capability is provided by the following feature in the WSO2 feature repository:
Name: WSO2 Carbon - BAM Service Data Agent Aggregate
If it is not included in your product by default, you can add it by installing the above feature using the instructions given in section, Feature Management.
Follow the instructions below to setup service data publishing in a running Carbon instance.
1. Log on to the product's Management Console select "Configure -> Service Data Publishing."
2. The "Service Data Publisher Configuration" window opens. Fill it appropriately. For example,
Enable Service stats: Tick to get the activity statistics.
Enable Activity Service: This enables message tracing with BAM, CEP or other data analysis servers. Typically, a request is sent to an endpoint after being passed through some intermediate stages. Messaging tracing enables to track each messages and visualize the message body in each of these intermediate stages.
Enable Activity Service feature will be implemented from the next major release of BAM.
Stream Definition Configuration:
Properties: A BAM deployment can receive events from different data agents. In order to uniquely identify events triggering from one agent, a property can be associated it. This feature is particularly useful in clustered environments.
Click the "Update" button once done. The service-hosting server is now ready to collect and send service data to any data analysis server like the BAM and CEP. Specific instructions to receive this data and analyze it can be found in the respective documentation of the data analysis servers.