OutSystems collects metrics of how applications are performing, to allow you to monitor and troubleshoot runtime issues. This article describes what is collected and how.
What Happens when Using an Application?
When end-users are using an application, their actions send requests to a server. The server then processes the requests and sends back responses with the result. During this cycle, the Platform collects metrics to enable you to troubleshoot performance issues, for example.
The following picture shows the request-response cycle and the points where the Platform collects metrics.
- The client sends a request to the server, a request triggered by an end-user action in the application
- The request arrives to the server
- The server starts sending the response, after executing the logic to process the request
- The client starts receiving the response
- The server finishes sending the response
- The client receives the last byte of the response
- The client finishes the rendering of response to the end-user
The time spent on the client-side is measured by the Load Time (steps 4, 6, and 7), that contains the following:
- Receiving the response
- Rendering the screen
This information is registered in the events called WebScreenClientExecuted.
Besides metrics, the WebScreenClientExecuted event contains additional client-side details, like the user agent and the operating system. See all the information collected on the client.
The platform computes the network time based on metrics collected on client and server sides, namely:
Network Duration = Client Duration - Client Load Time - Server Duration
When a web application runs in a browser, the WebScreenClientExecuted event captures further network-related details. Learn more about the network-related details collected by the Platform.
During the server-side execution (steps 2, 3, and 5), the platform collects metrics in a WebScreenServerExecuted event for:
- All executed queries
- All executed consumed integration methods (SOAP, REST or SAP)
- All executed extension actions
The rest of the server-side time is spent in acquiring the session, other application logic, and page render.
About Slow Calls
Besides the metrics listed in this document, the platform also collects information about slow calls that were executed on the server.
A slow call occurs when the execution of a query exceeds a threshold (200ms by default).
If the same call is executed multiple times in an action, e.g. happens inside a loop (For Each), the time considered is the sum of all executions. For example, if the 'GetOrdersForCustomer' query is executed ten times, each call taking 30 milliseconds, then the total time spent executing that query is 300ms.
Read Metrics and Add Your Custom Metrics
OutSystems provides the PerformanceMonitoring API, that enables you to:
- Read metrics: fetch the metrics stored in the platform database and build your own dashboard, for example
- Add your custom metrics: add your own metrics to applications
Learn more about the PerformanceMonitoring API.