This section describes the statistics available in the SOA Gateway.
The existing functionality helps determine the level of work flow activity through a server system. The infrastructure is also in place to enable other forms of statistics gathering such as performance monitoring, number of users, driver specific data and so on.
Work flow monitoring is set off by default. When on it will provide Key Performance Indicators (KPIs) on well know operations list, get, add, delete, update, invoke, select, selectCount, selectNext and selectEnd.
The KPIs gathered for each operation are as follows:
total_count
This is the number of times the operation has been called. If successful then the round trip time is added to total_time. If applicable high_time or low_time may be updated. If the operation is unsuccessful then errors_occurred is incremented.
total_time
This is the accumulated round trip time for the operation.
high_time
This is the highest round trip time for the operation.
low_time
This is the lowest round trip time for the operation.
errors_occurred
This is the number of times the operation has failed.
Setup is carried out using the SOA Gateway Control Centre.
Click on the server to be monitored in the list of SOA Gateway Servers. Then click on the Statistics tab within the Properties View as shown below:

Statistics can be collected in 2 modes, Normal and Cumulative.
Statistics are gathered from when the SOA Gateway Server is started to when it is stopped. On stopping the server a file is written with the KPIs at that point. The name of the file has the format soag_normal_statistics_yyyy_mm_dd_hh_mm_ss_millisec.xml e.g.
soag_normal_statistics_2008_10_09_12_56_11_364.xml
Statistics gathering continues over server stop/starts until the mode is set to Normal. When the server is stopped the data is written to the file soag_cumulative_statistics.xml. On restart the same file is read and used to initialise the statistics.
Statistics monitoring can be carried out on an ad hoc basis, again using the SOA Gateway Control Centre.
Open/click on the SOA Gateway Statistics View:

Pick the server from the Server listbox. The Name can be wildcarded or set to an individual method. Then click on the Show Statistics button to refresh the data.
The statistics can be reset at any time by selecting the Reset Statistics button.
The format of the normal and cumulative report is identical. Here is an extract from a normal file:

The statistic reports are written to the configuration folder where the SOA Gateway is installed.
The statistics are reported in XML and there are many programs which can consume this format e.g. here is the result of importing the above report into Excel:

Access to statistics is also made available via the statService web service as described by the WSDL http://server:port/statService?WSDL.
Statistics can be retrieved via a SOAP request using the statService web service. Using a WSDL consumer such as soapUI, as shown below, a request can be made using Group, Type and Name. As with the Control Centre, the ‘*’ construct enables the entire set of statistics to be returned or a subset. The Reset option can be set to True or False as required. The default value is False if omitted.

The statistics can also be retrieved via a URL-based request in a browser such as Internet Explorer. The statService service exposes one method, GET. As with previous requests this can be restricted by Group, Type and Name. Again the ‘*’ construct enables the entire set of statistics to be returned or a subset by specifying a value. The option is also provided to reset the current set of statistics. The example below restricts the search to the list method.
http://localhost:56000/statService?GET&Group=Server&Type=Request&Name=list

Let us assume that the server has been started for the first time and that statistics collection has been set on for the first time. An Adabas database is available and a web service created to access it. Both queries below are issued via a browser such as IE. The LIST successfully retrieves the data for employees whose ids start with 200. The GET query fails because the syntax is incorrect.
http://localhost:56005/Adabas_Driver_1_9?GET=20020000
http://localhost:56005/Adabas_Driver_1_9?LIST&AA=200*
Now get the statistics so far by issuing a GET on statService as shown below. Note that the entry for the get request does not show any effect on the times. Note that for list, for the moment, all times are identical. The time is 0.203 or 203 milliseconds. This is the round trip time spent in the SOA Gateway Server.

Let us issue the LIST and GET again, this time correcting the GET syntax and changing the LIST to retrieve ids starting with 20:
http://localhost:56005/Adabas_Driver_1_9?GET&AA=20020000
http://localhost:56005/Adabas_Driver_1_9?LIST&&AA=20*
Note the now successful entry for the get operation. Note also that for list the high time is now 0.234 as the query took slightly longer. As there have been only 2 list requests so far the total time equals the sum of low and high times.
