Response Time Testing – Test response time.

Tram Ho

1. What is response time testing?

  • Response time testing is a type of test that measures the average response time of a request sent to the server.
  • As the time it takes for the system to process an input until the processing is finished, we can understand that an input is a query or that each processing includes execution. determine the beginning and end point (transaction).
  • Generally speaking, it is the time between when the user sent the request until the application indicated that the request was completed.

2. How to measure response time?

a. Measure response time.

  • We cannot measure the response time of the system using manual testing, we have to use tools.
  • Of course, the unit of measure for response time is the unit of time (m, s, ms), most commonly used in testing tools is the millisecond (ms).

b. Common Response Time Measurement Tools

  • In the same process, the response time measured from different tools will return slightly different results, because:
    • The difference in calculation method, data income of each tool.
    • The influence of load and capture speed simulation tools, used in each tool.
    • Goals are used to record and track progress (report).
    • The resource consumption when calculating the data collected in each tool differs.
    • Architectural difference of each tool.

3. The feedback metrics

There are 3 data used to collect and evaluate Response time.

Average response time

  • The average response time of each request is a metric after calculating the average of all response times for that request. Is a reflection of the speed of the web application being tested – the BEST indicator of how the site is performing from the user’s point of view. That is when using, users feel satisfied with the speed of response when operating on the website.
  • The average response time is affected by many components, including the delivery of HTML, images, CSS, XML, Javascript files, and any other resources being used.
    • In addition, a small impact from a geographical location such as a remote end-user affects the response time.
  • Average response time can be measured, through JMeter.
  • The chart above shows the average response time of 400 requests sent to https://tiki.vn . Thereby, we can see, the tool has collected and analyzed the average response time is 6727 milliseconds.

Peak response time

  • Peak response time will tell us which request has the highest response time. From there, it is possible to detect potentially problematic components, anomalies in the website or possibly inaccurate processing.
    • It can be understood that in the process of using a lot of data queries, uploading image files or calling large JS libraries, those requests will need a higher response time than other requests. As a result, the peak response time data will help the developer to identify the cause of the reduced average response time (high response time), so that solutions can be improved. .
  • Example: After running requests in JMeter, we have the results table:

(How to run to have the table below, I will update the link later)

    • The request “PHU KIEN” is the Peak response time, as it takes up the highest response time (red – 4795 ms).
    • Request “BACH HOA” has the lowest response time (yellow – 223 ms)
    • The average response time of all 4 requests is 1402 ms.

Error rate

  • The error rate represents the percentage of requests that crashed across all requests sent throughout the process. It also includes requests that have timed out response.
  • It is calculated by counting all the HTTP status codes displayed on the server.
  • Example: The error rate in the example below is 20% of all requests.

4. Three response time values ​​are important

Normally, the time it takes for a user to wait for the server to respond is listed in the following three main values:

Response time
0.1 secondIt is the ideal response time. Users will feel the system responds to requests immediately and without any interruptions.
1.0 secondIt is seen as the maximum limit of acceptable response time. Users may still experience no disruption when the server responds to requests. However, it still affects the user experience.
10 secondsThis is the maximum limit that exceeds the acceptable limit, it greatly affects the user experience and normally when waiting for more than 6s users will exit the website.

References:

Share the news now

Source : Viblo