[go: up one dir, main page]

HK1138965B - Method, apparatus and system for testing page performance - Google Patents

Method, apparatus and system for testing page performance Download PDF

Info

Publication number
HK1138965B
HK1138965B HK10105758.9A HK10105758A HK1138965B HK 1138965 B HK1138965 B HK 1138965B HK 10105758 A HK10105758 A HK 10105758A HK 1138965 B HK1138965 B HK 1138965B
Authority
HK
Hong Kong
Prior art keywords
page
performance
performance data
information table
page element
Prior art date
Application number
HK10105758.9A
Other languages
Chinese (zh)
Other versions
HK1138965A1 (en
Inventor
龚亮
Original Assignee
阿里巴巴集团控股有限公司
Filing date
Publication date
Priority claimed from CN2008101347517A external-priority patent/CN101635655B/en
Application filed by 阿里巴巴集团控股有限公司 filed Critical 阿里巴巴集团控股有限公司
Publication of HK1138965A1 publication Critical patent/HK1138965A1/en
Publication of HK1138965B publication Critical patent/HK1138965B/en

Links

Description

Page performance testing method, device and system
Technical Field
The invention relates to the field of performance testing, in particular to a method, a device and a system for testing page performance of a web client in a b/s architecture.
Background
When the desktop software is popularized, the performance is not taken the attention of most people, but with the increasing popularization of the internet, the performance is taken more and more attention by people due to the appearance of a c/s architecture and a b/s architecture. With the b/s architecture in particular, performance is most important to the server since all data is available from the server without downloading the client. In the prior art, a common knowledge exists in the art that when the performance of a server is improved, the performance of a corresponding client is naturally improved, and therefore, in the prior art, a performance test is usually performed on the server. Specifically, the performance test is to simulate the service pressure and the use scene combination of the production environment operation through an automatic test tool, and test various normal, peak and abnormal load conditions of the system, such as a load test, a pressure test and the like. The main purpose of the performance test is to verify whether the system can reach the performance index provided by the user, and at the same time, to find the performance bottleneck existing in the software system, to optimize the software, and finally to achieve the purpose of optimizing the system.
In fact, what directly affects the user experience is the web client, and many factors affect the performance of the web client, such as network delay, packet loss rate, configuration of the client, and so on, so in the b/s architecture, the performance test of the web client should also become an important component in the performance test system.
Therefore, one of the technical problems to be solved by those skilled in the art is to overcome the technical bias that the prior art only performs performance testing on a server side, and to provide a method for testing the page performance of a web client in a b/s architecture, so as to discover the bottleneck of the page performance and optimize the performance of the web client by simply and efficiently monitoring the performance of the web client.
Disclosure of Invention
The technical problem to be solved by the invention is to provide a method for testing the page performance, which is used for simply and efficiently monitoring the performance of a web client, discovering the bottleneck of the page performance and optimizing the performance of the web client.
The invention also aims to provide a device and a system for testing the page performance, which are used for ensuring the realization and the application of the method in practice.
In order to solve the above technical problem, an embodiment of the present invention provides a method for testing page performance, including:
collecting the whole page performance data and the page element performance data of the page monitoring points, and respectively storing the whole page performance data and the page element performance data into a whole page information table and a page element information table;
counting page element performance data with the same attribute, generating a corresponding page element performance data set, and adding the page element performance data set to the whole page information table;
and calculating the performance parameters of the page monitoring points according to the whole page performance data and/or the corresponding page element performance data set in the whole page information table, and storing the page performance parameters into a page performance parameter table.
Preferably, the whole page information table, the page element information table and the page performance parameter table are stored in the server, and the method further includes:
receiving a page performance data query condition submitted by a client;
and extracting corresponding overall page performance data, page element performance data and/or page performance parameters from the overall page information table, the page element information table and/or the page performance parameter table according to the query conditions, generating a query result and returning the query result to the client.
Preferably, the method further comprises:
and displaying the query result at the client.
Preferably, the overall page performance data includes acquisition time, total page download time, total page error number, byte number of page receiving/sending, interaction times between the page and the server, server host name of the page, and times of sending requests to the server by the page; the page element performance data comprises acquisition time, URL of the page element, page element type, downloading time of the page element, downloading state of the page element and time for starting downloading of the page element.
Preferably, the whole page performance data and the page element performance data of the page monitoring point form a corresponding relation based on the same acquisition time, and the whole page information table and the page element information table are associated according to the same acquisition time.
Preferably, the page element performance data with the same attribute is the page element performance data with the same source of the page element and/or the same type of the page element, and the source of the page element is extracted from the URL of the page element.
Preferably, the step of calculating the performance parameter of the page monitoring point further includes:
extracting the total downloading time of all pages of the page monitoring point within a certain time range from the whole page information table;
and calculating an initial average value of the total download time of the page, and storing the initial average value into a page performance parameter table.
Preferably, the step of calculating the performance parameter of the page monitoring point further includes:
generating an abnormal data judgment threshold according to the initial average value, and determining the total abnormal page downloading time and number according to the abnormal data judgment threshold;
removing the abnormal total page downloading time, and recalculating a new average value of the remaining total page downloading time;
and recording the abnormal data judgment threshold, the number of the total abnormal page downloading time and/or the new average value into a page performance parameter table.
Preferably, the step of calculating the performance parameter of the page monitoring point further includes:
extracting page element performance data sets with the same attribute of the page monitoring points within a certain time range from the whole page information table;
and calculating the average value of the downloading time of each page element in the page element performance data set, and recording the element average value into a page performance parameter table.
The embodiment of the invention also discloses a device for testing the page performance, which comprises:
the data acquisition module is used for acquiring the overall page performance data and the page element performance data of the page monitoring points and respectively storing the data into the overall page information table and the page element information table;
the classification statistical module is used for counting page element performance data with the same attribute, generating a corresponding page element performance data set and adding the corresponding page element performance data set into the whole page information table;
and the performance parameter calculation module is used for calculating the performance parameters of the page monitoring points according to the whole page performance data and/or the corresponding page element performance data set in the whole page information table and storing the page performance parameters into a page performance parameter table.
Preferably, the device further comprises:
the client interface module is used for receiving a page performance data query condition submitted by a client; and returning the query result to the client;
and the data query analysis module is used for extracting corresponding overall page performance data, page element performance data and/or page performance parameters from the overall page information table, the page element information table and/or the page performance parameter table according to the query conditions to generate a query result.
Preferably, the performance parameter calculation module further includes:
the page overall information acquisition submodule is used for extracting the overall downloading time of all pages of the page monitoring point within a certain time range from the overall page information table;
the initial average value calculation submodule is used for calculating an initial average value of the total downloading time of the page;
and the first recording submodule is used for storing the initial average value into a page performance parameter table.
Preferably, the performance parameter calculation module further includes:
the abnormal data judgment submodule is used for generating an abnormal data judgment threshold value according to the initial average value and determining the total downloading time and the number of abnormal pages according to the abnormal data judgment threshold value;
the new average value calculation submodule is used for removing the abnormal page total download time and recalculating a new average value for the remaining page total download time;
and the second recording submodule is used for recording the abnormal data judgment threshold, the quantity of the abnormal page total downloading time and/or the new average value into a page performance parameter table.
Preferably, the performance parameter calculation module further includes:
the page element information acquisition submodule is used for extracting page element performance data sets with the same attribute of the page monitoring points within a certain time range from the whole page information table;
the element average value calculating submodule is used for calculating the average value of the downloading time of each page element in the page element performance data set;
and the third recording sub-module is used for recording the element average value into a page performance parameter table.
The embodiment of the invention also discloses a system for testing the page performance, which comprises the following steps:
at the server side:
the data acquisition module is used for acquiring the overall page performance data and the page element performance data of the page monitoring points and respectively storing the data into the overall page information table and the page element information table;
the classification statistical module is used for counting page element performance data with the same attribute, generating a corresponding page element performance data set and adding the corresponding page element performance data set into the whole page information table;
and the performance parameter calculation module is used for calculating the performance parameters of the page monitoring points according to the whole page performance data and/or the corresponding page element performance data set in the whole page information table and storing the page performance parameters into a page performance parameter table.
The client interface module is used for receiving a page performance data query condition submitted by a client; and returning the query result to the client;
the data query analysis module is used for extracting corresponding overall page performance data, page element performance data and/or page performance parameters from the overall page information table, the page element information table and/or the page performance parameter table according to the query conditions to generate a query result;
at the client side:
the server communication module is used for submitting the page performance data query conditions to the server; receiving a query result returned by the server;
and the display module is used for displaying the query result.
Compared with the prior art, the invention has the following advantages:
the invention fills the blank of the traditional server performance test and monitoring, tests the performance of the whole web page and each page element by testing the page performance of the web client to monitor for 7 x 24 hours, processes the stored data uniformly, and performs data query and data analysis in a web mode so as to analyze the page performance problem, find the bottleneck of the page performance, is convenient to adjust and optimize, and can be matched with the traditional server performance test to form a complete performance test system to comprehensively monitor the performance of the server and the client and improve the user experience.
Drawings
FIG. 1 is a flow chart of a method embodiment 1 of the invention for testing page performance;
FIG. 2 is a flow chart of a method embodiment 2 of the invention for testing page performance;
FIG. 3 is a flowchart of an interaction between a client and a server for performing a page performance test in a b/s architecture, applying an embodiment of the present invention;
FIG. 4 is a graphical illustration of daily page performance curves generated in one embodiment of the present invention;
FIG. 5 is a graphical illustration of a weekly page performance curve generated in an embodiment of the present invention;
FIG. 6 is a graphical illustration of a monthly page performance curve generated in one embodiment of the present invention;
FIG. 7 is a schematic illustration of a display of query page element performance data in one embodiment of the present invention;
FIG. 8 is a diagram illustrating a multiple combined query interface in an example embodiment of the invention;
FIG. 9 is a block diagram of an embodiment of a page performance testing apparatus according to the present invention;
FIG. 10 is a flowchart of a method for performing a page performance test using the embodiment of the apparatus shown in FIG. 9;
FIG. 11 is a block diagram of a page performance testing system according to an embodiment of the present invention.
Detailed Description
In order to make the aforementioned objects, features and advantages of the present invention comprehensible, embodiments accompanied with figures are described in further detail below.
The performance test of the embodiment of the invention is a page performance test for a web client, and the core concept of the embodiment of the invention has the starting point that the system performance is generally reflected by the response time of user operation. In short, when a user performs an operation on a certain page, such as clicking a button, issuing an instruction, or clicking a link on a Web page, the time consumed in the process from when the user triggers the operation to when the system displays the result of the operation in a manner that the user can perceive the result is the intuitive impression of the system performance of the user, that is, the response time experienced by the user, that is, the response time directly affects the user experience. In practice, although this response time is susceptible to many factors, such as network speed, client performance, or different user requirements for performance, the user does not manage how long the server returns the response, but only concerns how long the page content needs to be exposed. In order to solve the problem that the response time and other data of the traditional performance test are all at the server side, and the performance of the client side is completely ignored, the embodiment of the invention provides one of the core ideas that the blank of the traditional performance test and monitoring at the server side is made up, the page performance of the web client side is tested, the performance of the whole page and each page element of the web is tested, the monitoring is carried out for 7 x 24 hours, the data is processed and stored in a unified mode, data query and data analysis are carried out in a web mode, so that the page performance problem is analyzed, the page performance bottleneck is found, tuning is convenient, and the user experience is improved.
Referring to fig. 1, a flowchart of an embodiment 1 of the page performance testing method of the present invention is shown, which may include the following steps:
step 101, collecting the whole page performance data and the page element performance data of a page monitoring point, and respectively storing the whole page performance data and the page element performance data into a whole page information table and a page element information table;
102, counting page element performance data with the same attribute, generating a corresponding page element performance data set, and adding the page element performance data set to the whole page information table;
step 103, calculating the performance parameters of the page monitoring points according to the whole page performance data and/or the corresponding page element performance data set in the whole page information table, and storing the page performance parameters into a page performance parameter table.
In the embodiment of the present invention, the monitoring point may be determined according to the specific page content that needs to be monitored and is provided by a demand party (e.g., a user or a developer). The operation of adding or deleting the monitoring points can be carried out on a web control platform, and can also be realized in code by development and maintenance personnel. In practice, data of a page monitoring point can be collected by accessing a page, and specifically, the following two methods can be adopted:
one approach to accessing the monitoring points is to use a method of collecting data, for example, using an openpage function to call methods of collecting data; another method is to use a method that does not collect data to access a non-monitoring point on a critical path, for example, a gotourl function is used to implement the method, which does not call the method of collecting data, but the whole process is always on the same browser, so as to ensure that the monitoring bottom layer program runs smoothly.
Of course, the above method is only used as an example, and any method for collecting performance data of a page monitoring point is feasible for those skilled in the art, and the present invention is not limited to this.
Preferably, the collected overall page performance data may include collection time, total page download time, total page errors, number of bytes received/sent by the page, number of interactions between the page and the server, server hostname of the page, number of requests sent by the page to the server, and the like.
Since each page has a plurality of page elements, each page element has an embodiment of corresponding performance data, that is, one page element has a corresponding set of performance data, specifically, the collected page element performance data may include collection time, URL (or name) of the page element, page element type (such as image, javascript, css, text/html), download time of the page element, download state of the page element (such as http _ code value), and time when the page element starts to be downloaded. The performance data can be used for analyzing the performance condition of the page element.
In this case, the overall page performance data and the page element performance data of the page monitoring point may form a corresponding relationship based on the same acquisition time, and accordingly, the overall page information table and the page element information table are associated according to the same acquisition time.
For example, a browser is opened, a url is input to send a request to a server, then all data interaction between the browser and the server is recorded, the starting download time and the ending download time of each page element are recorded, and the downloading time of each page element is obtained by subtracting the starting download time and the ending download time; each time a request is sent to the server, the counter is added by 1 to obtain the number of the requests sent to the server; recording the name of the page element downloaded from the server; judging the data of each page element and assigning a category; and recording the http _ code of each returned page element, the error number, the number of transmitted bytes, the number of received bytes and the like, and storing.
For example, open http:// www.taobao.com, record that the whole download time of the web page is 3.667 seconds, the url of the download is http:// www.taobao.com, the number of errors in the download of page elements is 3, 534428 bytes are totally sent out, 67578 bytes are totally received, the number of interactions between the client and the server is 83, 90 request digits are sent to the server, the host name of the page is home127.cn7, the data acquisition time is 2008-06-0417:22:04, and the specific information of 90 specific page elements, such as the name of the page element http:// cn. yimg. com/a/yushi/ksf _ 060208. swf, the acquisition time is 2008-06-0417:22:04, the type is flash, the time for downloading the element is 1.623 seconds, the flag bit of the element is 0 (no error), the time for the start of the download of the element is 1.74 seconds (the calculation of the request from the server), http _ code is 200 (normal download).
Storing the obtained overall page performance data to an overall page information table, such as a page _ performance database table, and storing the obtained page element performance data to a page element information table, such as a page _ element database table.
The step 102 is operable to further perform a classification statistical process on the page element performance data. Preferably, the page element performance data with the same attribute in this step may be the page element performance data with the same source of the page element and/or the same type of the page element, where the source of the page element is extracted from the URL of the page element.
For example, classification statistics is performed according to the category and the source of the page element, a plurality of statistical results are generated, such as a page element set inside a website, a page element set outside the website, a page element set without source division, and a whole page element set, and the statistical results are added to a page _ performance table for recording the page performance data in whole in an Update manner.
For example, the page _ element of the page element information table is represented as:
name (R) Type (B)
Collection time (collect _ time, associated with page _ performance) Date & time
Page element name (element _ name) varchar2(4000)
Page element type (element _ type) varchar2(500)
Page element download time (element _ load _ time) number
Whether a page element download is erroneous (iferror) number(1)
Page element Start download time (element _ start _ time) number
Page element download status (Http _ code) number(5)
For example, the indication of the page _ performance of the whole page information table is as follows:
name (R) Type (B)
Page monitor point name (name) varchar2(4000)
Total download time of page (total _ time) number
Collection time (collect _ time, associated with page _ element) Date & time
Total number of page faults (errors) number(10)
Page receiving byte number (received) number
Page transmitting byte number (send) number
Interaction times between page and server (round _ tries) number(10)
Server host name of page (hosts) varchar2(500)
Number of times a page sends a request to a server (number _ of _ requests) number(10)
*The following are the classification statistics
CSS type Page element full source download time (cs _ load _ time) number
Time of download of all source elements of javascript class page (js _ load _ time) number
Time of download of all sources of photo page elements (image _ load _ time) number
Time of full source download of text-type page element (text _ load _ time) number
CSS type Page element external source download time (csso _ load _ time) number
Time of download of javascript class page element from external source (jso _ load _ time) number
Time of picture page element download from external source (imageo _ load _ time) number
Time of download of text class Page element from external Source (texto _ load _ time) number
External source full page element download time (taobaoo _ load _ time) number
Internal source full page element download time (taobao _ load _ time) number
CSS type page element internal source download time (cssa _ load _ time) number
Time of source download inside javascript class page element (jsa _ load _ time) number
Time of picture type page element internal source download (imagea _ load _ time) number
Time of source download inside the text class Page element (texta _ load _ time) number
Based on the whole page information table and the page element information table, the corresponding whole page performance data and/or page element performance data can be inquired and analyzed through the web platform in the subsequent process, or a chart can be automatically generated.
The step 103 is used for generating performance parameters of the page monitoring points according to the related data in the whole page information table, and one of the performance parameters is used for searching the abnormal data of the page monitoring points, so that a performance bottleneck is found, and tuning is convenient.
Preferably, the step 103 may further include the following sub-steps:
a substep A1, extracting the total download time of all pages of the page monitoring point within a certain time range from the whole page information table;
and a substep A2, calculating an initial average value of the total download time of the page, and storing the initial average value into a page performance parameter table.
For example, at 23 points 59 points per day, the total page download time of the page monitoring point in the day is averaged and stored in a page performance parameter table, such as a page _ day database table.
More preferably, the step 103 may further include the following sub-steps:
substep A3, generating an abnormal data judgment threshold value according to the initial average value, and determining the total downloading time and the number of abnormal pages according to the abnormal data judgment threshold value;
substep A4, removing the abnormal page total download time, and recalculating new average value for the remaining page total download time;
and a substep A5, recording the abnormal data judgment threshold value, the number of abnormal page total downloading time and/or the new average value into the page performance parameter table.
For example, 5sigma processing is performed based on the initial average value, the initial average value is subtracted from the data of the total download time of all pages in one day, the value is taken as an absolute value, then the absolute value is compared with 5 times of the initial average value, the data larger than 5 times is removed as abnormal data, and a flag bit 1 is given to the abnormal data; assigning a flag bit of 0 to normal data; and then, averaging all the data with the flag bit of 0 again to obtain a new average value.
It will be appreciated that, depending on the actual requirements, performance parameters may also be calculated for the classification statistics, in which case the step 103 may also comprise the following sub-steps:
a substep B1, extracting a page element performance data set with the same attribute of the page monitoring point within a certain time range from the whole page information table;
and a substep B2 of calculating the average value of the download time of each page element in the page element performance data set and recording the element average value into a page performance parameter table.
An example of a page performance parameter table page _ day is:
name (R) Type (B)
Collection date (D _ date) date
Collection Point name (page _ name) varchar2(4000)
Original daily average (avg1) number
Average value after removal of abnormal value (pavg) number
Original daily average multiplied by 5 times value (avg2) number
Collected page address (url) varchar2(4000)
Average of Picture class Page elements for one day (image _ avg) number
CSS class Page element one day average (CSS _ avg) number
Average of one day for text-like page elements (text _ avg) number
Average of javascript class Page elements for one day (js _ avg) number
Average value of external source picture class page element (imageo _ avg) for one day number
One day average of external Source CSS class Page elements (csso _ avg) number
Average of one day (texto _ avg) of externally sourced text-like page elements number
Average of external sources javascript class Page elements for one day (jso _ avg) number
Average of all types of page elements from internal sources (taobao _ avg) for one day number
Average of all types of page elements from external sources (taobaoo _ avg) for one day number
Average value of internal source picture class page element for one day (imagea _ avg) number
Source inside CSS class Page element average one day (cssa _ avg) number
Average of one day (texta _ avg) of internal Source text class Page elements number
Average of internal sources javascript class Page elements one day (jsa _ avg) number
It can be seen that the overall page performance data, such as information of acquisition time, overall page download time, total page errors, byte number of page reception/transmission, interaction times between the page and the server, server host name of the page, and times of requests sent by the page to the server, are recorded in the overall page information table generated by applying the embodiment of the present invention; and a corresponding page element performance data set subjected to classification statistics; the page element information table records page element performance data, such as acquisition time, URL of the page element, page element type, download time of the page element, download state of the page element, time for starting downloading of the page element and the like, the whole page performance data and the page element performance data form a corresponding relation based on the same acquisition time, and the corresponding whole page information table and the corresponding page element information table are also associated according to the same acquisition time; the generated page performance parameter table records information such as an initial average value, a 5sigma value, abnormal data quantity, a new average value after abnormality removal and the like. Based on the data table, data query and data analysis can be directly and conveniently carried out in a web mode, and web interface display can be carried out, so that the bottleneck of page performance can be found, and the performance of a client side can be conveniently optimized.
Referring to fig. 2, a flowchart of embodiment 2 of the page performance testing method of the present invention is shown, which may include the following steps:
step 201, collecting the whole page performance data and the page element performance data of the page monitoring point, and respectively storing the whole page performance data and the page element performance data into a whole page information table and a page element information table;
step 202, counting page element performance data with the same attribute, generating a corresponding page element performance data set, and adding the page element performance data set to the whole page information table;
step 203, calculating the performance parameters of the page monitoring points according to the whole page performance data and/or the corresponding page element performance data set in the whole page information table, and storing the page performance parameters into a page performance parameter table;
preferably, the whole page information table, the page element information table and the page performance parameter table are stored in the server, and the method may further include the following steps:
step 204, receiving a page performance data query condition submitted by a client;
step 205, extracting corresponding overall page performance data, page element performance data and/or page performance parameters from the overall page information table, the page element information table and/or the page performance parameter table according to the query conditions, generating a query result and returning the query result to the client;
if the query condition can be:
a) inquiring the whole page performance data of the page monitoring points within a certain time;
b) inquiring classification statistical results of the page monitoring points within a certain time, such as a page element set inside a website, a page element set outside the website, a page element set without source division, and all page element sets from the inside and the outside of the website;
c) and accurately querying the performance data of all page elements of a certain page at a certain time.
Step 206, the query result is displayed on the client.
For example, the query results are presented in the form of a daily, weekly, monthly graph.
In practice, an example of an interaction process between a client and a server, which executes a page performance test in a b/s architecture by applying the embodiment of the present invention, may refer to fig. 3, and specifically may include the following steps:
the client and the server execute the following steps concurrently:
wherein the server performs:
311, executing the data acquisition script at fixed points or manually according to the test requirements;
step 312, collecting the performance data of the whole page and the performance data of the page elements by using the script according to the monitoring point collecting program of the main script;
313, respectively storing the whole page performance data and the page element performance data into a whole page information table and a page element information table;
step 314, counting page element performance data with the same attribute, generating a corresponding page element performance data set, and adding the page element performance data set to the whole page information table; and reading the whole page performance data and/or the corresponding page element performance data set within a certain time range from the whole page information table to calculate the performance parameters of the page monitoring points, and storing the page performance parameters into a page performance parameter table.
The client executes:
step 321, relevant personnel open a browser;
step 322, accessing the server side through a middleware application server (such as tomcat);
this step triggers the data interaction between the client and the server, and the interaction step includes:
step 33, submitting a page performance data query request to a server by the client;
step 34, the server extracts corresponding whole page performance data, page element performance data and/or page performance parameters from the whole page information table, the page element information table and/or the page performance parameter table according to the query conditions, generates a query result and returns the query result to the client;
and step 35, the client displays the query result.
For example, query 2008, 20.5.8, download time of all page elements in http:// www.taobao.com page, data generation day page performance graph obtained by query is shown in FIG. 4; or inquiring about download time of all page elements in the page of http:// www.taobao.com from 13 th to 19 th in 5 th month in 2008, and generating a weekly page performance curve chart by inquiring the obtained data as shown in FIG. 5; or inquiring about the download time of all page elements in the http:// www.taobao.com page in month 5 of 2008, and generating a monthly page performance curve graph by inquiring the obtained data as shown in FIG. 6; alternatively, the page element performance data for 2008, 6, 27, 03, 21:36 is queried, as shown in FIG. 7.
In practice, based on the page performance data, reference data such as website traffic, server configuration, and the like can be queried, and the query condition can be set arbitrarily according to requirements, for example, a schematic diagram of a plurality of combined query interfaces as shown in fig. 8 is set, which does not need to be limited in the present invention.
For the above method embodiments, the description of each embodiment has its own emphasis, and for parts not described in detail in a certain embodiment, reference may be made to the related description of other embodiments. While, for purposes of simplicity of explanation, the foregoing method embodiments have been described as a series of acts, it will be appreciated by those skilled in the art that the present invention is not limited by the illustrated ordering of acts, as some steps may occur in other orders and concurrently with other steps, in accordance with the invention. Further, those skilled in the art should also appreciate that the embodiments described in the specification are preferred embodiments and that the acts and modules referred to are not necessarily required by the invention.
Referring to fig. 9, a block diagram of an embodiment of the apparatus for page performance testing according to the present invention is shown, which may include the following modules:
the data acquisition module 901 is configured to acquire the overall page performance data and the page element performance data of the page monitoring point, and store the data into the overall page information table and the page element information table respectively;
a classification statistical module 902, configured to count page element performance data with the same attribute, generate a corresponding page element performance data set, and add the page element performance data set to the whole page information table;
a performance parameter calculating module 903, configured to calculate a performance parameter of the page monitoring point according to the whole page performance data in the whole page information table and/or the corresponding page element performance data set, and store the page performance parameter in a page performance parameter table.
Preferably, in the embodiment of the present invention, the following modules may be further included:
the client interface module is used for receiving a page performance data query condition submitted by a client; and returning the query result to the client;
and the data query analysis module is used for extracting corresponding overall page performance data, page element performance data and/or page performance parameters from the overall page information table, the page element information table and/or the page performance parameter table according to the query conditions to generate a query result.
Preferably, the performance parameter calculation module may further include the following sub-modules:
the page overall information acquisition submodule is used for extracting the overall downloading time of all pages of the page monitoring point within a certain time range from the overall page information table;
the initial average value calculation submodule is used for calculating an initial average value of the total downloading time of the page;
and the first recording submodule is used for storing the initial average value into a page performance parameter table.
As another embodiment, the performance parameter calculation module may further include the following sub-modules:
the abnormal data judgment submodule is used for generating an abnormal data judgment threshold value according to the initial average value and determining the total downloading time and the number of abnormal pages according to the abnormal data judgment threshold value;
the new average value calculation submodule is used for removing the abnormal page total download time and recalculating a new average value for the remaining page total download time;
and the second recording submodule is used for recording the abnormal data judgment threshold, the quantity of the abnormal page total downloading time and/or the new average value into a page performance parameter table.
Preferably, the performance parameter calculation module may further include the following sub-modules:
the page element information acquisition submodule is used for extracting page element performance data sets with the same attribute of the page monitoring points within a certain time range from the whole page information table;
the element average value calculating submodule is used for calculating the average value of the downloading time of each page element in the page element performance data set;
and the third recording sub-module is used for recording the element average value into a page performance parameter table.
Referring to fig. 10, a flowchart of a method for performing a page performance test by applying the embodiment of the apparatus shown in fig. 9 is shown, which may specifically include the following steps:
step 1001, a data acquisition module acquires overall page performance data and page element performance data of a page monitoring point and respectively stores the data into an overall page information table and a page element information table;
step 1002, the classification statistical module counts page element performance data with the same attribute, generates a corresponding page element performance data set, and adds the page element performance data set to the whole page information table;
step 1003, the performance parameter calculation module calculates the performance parameters of the page monitoring points according to the whole page performance data and/or the corresponding page element performance data set in the whole page information table, and stores the page performance parameters into a page performance parameter table;
step 1004, the client interface module receives a page performance data query condition submitted by the client;
step 1005, the data query analysis module extracts corresponding whole page performance data, page element performance data and/or page performance parameters from the whole page information table, the page element information table and/or the page performance parameter table according to the query condition to generate a query result;
step 1006, the client interface module returns the query result to the client.
For the device embodiment of the present invention, since it basically corresponds to the method embodiment, the description is relatively simple, and for the relevant points, reference may be made to the partial description of the method embodiment.
For practical application of the embodiment of the present invention, reference may be made to a structural block diagram of an embodiment of a page performance testing system shown in fig. 11, which may include the following modules:
located at server side 1101:
the data acquisition module 111 is used for acquiring the overall page performance data and the page element performance data of the page monitoring points and respectively storing the data into the overall page information table and the page element information table;
a classification statistical module 112, configured to count page element performance data with the same attribute, generate a corresponding page element performance data set, and add the page element performance data set to the whole page information table;
and the performance parameter calculation module 113 is configured to calculate a performance parameter of the page monitoring point according to the whole page performance data in the whole page information table and/or the corresponding page element performance data set, and store the page performance parameter in the page performance parameter table.
A client interface module 114, configured to receive a page performance data query condition submitted by a client; and returning the query result to the client;
the data query analysis module 115 is configured to extract corresponding overall page performance data, page element performance data, and/or page performance parameters from the overall page information table, the page element information table, and/or the page performance parameter table according to the query condition, and generate a query result;
at the client 1102:
the server communication module 121 is configured to submit a page performance data query condition to a server; receiving a query result returned by the server;
and a presentation module 122, configured to present the query result.
For the system embodiment of the present invention, since it basically corresponds to the method embodiment, the description is relatively simple, and for the relevant points, refer to the partial description of the method embodiment.
Embodiments of the invention are operational with numerous general purpose or special purpose computing device environments or configurations. For example, the following examples: personal computers, server computers, hand-held or portable devices, tablet-type devices, multi-processor apparatus, distributed computing environments that include any of the above devices or equipment, and the like.
Embodiments of the invention may be described in the general context of computer-executable instructions, such as program modules, being executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, etc. that perform particular tasks or implement particular abstract data types. The invention may also be practiced in distributed computing environments where tasks are performed by remote processing devices that are linked through a communications network. In a distributed computing environment, program modules may be located in both local and remote computer storage media including memory storage devices.
The method, the device and the system for testing the page performance provided by the invention are introduced in detail, a specific example is applied in the text to explain the principle and the implementation mode of the invention, and the description of the embodiment is only used for helping to understand the method and the core idea of the invention; meanwhile, for a person skilled in the art, according to the idea of the present invention, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present invention.

Claims (15)

1. A method for testing page performance is characterized by comprising the following steps:
collecting the whole page performance data and the page element performance data of the page monitoring points, and respectively storing the whole page performance data and the page element performance data into a whole page information table and a page element information table;
counting page element performance data with the same attribute, generating a corresponding page element performance data set, and adding the page element performance data set to the whole page information table;
and calculating the performance parameters of the page monitoring points according to the whole page performance data and/or the corresponding page element performance data set in the whole page information table, and storing the calculated page performance parameters into a page performance parameter table.
2. The method of claim 1, wherein the entire page information table, the page element information table, and the page performance parameter table are stored on the server side, the method further comprising:
receiving a page performance data query condition submitted by a client;
and extracting corresponding overall page performance data, page element performance data and/or page performance parameters from the overall page information table, the page element information table and/or the page performance parameter table according to the query conditions, generating a query result and returning the query result to the client.
3. The method of claim 2, further comprising:
and displaying the query result at the client.
4. The method of claim 1, 2 or 3, wherein the overall page performance data comprises acquisition time, total download time of the page, total number of page errors, number of bytes received/sent by the page, number of interactions of the page with the server, server hostname of the page, and number of requests sent by the page to the server; the page element performance data comprises acquisition time, URL of the page element, page element type, downloading time of the page element, downloading state of the page element and time for starting downloading of the page element.
5. The method of claim 4, wherein the whole page performance data and the page element performance data of the page monitoring point form a correspondence based on a same acquisition time, and the whole page information table and the page element information table are associated according to the same acquisition time.
6. The method according to claim 4, wherein the page element performance data having the same attribute is page element performance data having the same source of the page element and/or the same type of page element, and the source of the page element is extracted from the URL of the page element.
7. The method of claim 5 or 6, wherein the step of calculating performance parameters of a page monitoring point further comprises:
extracting the total downloading time of all pages of the page monitoring point within a certain time range from the whole page information table;
and calculating an initial average value of the total download time of the page, and storing the initial average value into a page performance parameter table.
8. The method of claim 7, wherein the step of calculating performance parameters of a page monitoring point further comprises:
generating an abnormal data judgment threshold according to the initial average value, and determining the total abnormal page downloading time and number according to the abnormal data judgment threshold;
removing the abnormal total page downloading time, and recalculating a new average value of the remaining total page downloading time;
and recording the abnormal data judgment threshold, the number of the total abnormal page downloading time and/or the new average value into a page performance parameter table.
9. The method of claim 8, wherein the step of calculating performance parameters of a page monitoring point further comprises:
extracting page element performance data sets with the same attribute of the page monitoring points within a certain time range from the whole page information table;
and calculating the average value of the downloading time of each page element in the page element performance data set, and recording the element average value into a page performance parameter table.
10. An apparatus for page performance testing, comprising:
the data acquisition module is used for acquiring the overall page performance data and the page element performance data of the page monitoring points and respectively storing the data into the overall page information table and the page element information table;
the classification statistical module is used for counting page element performance data with the same attribute, generating a corresponding page element performance data set and adding the corresponding page element performance data set into the whole page information table;
and the performance parameter calculation module is used for calculating the performance parameters of the page monitoring points according to the whole page performance data and/or the corresponding page element performance data set in the whole page information table and storing the calculated page performance parameters into the page performance parameter table.
11. The apparatus of claim 10, further comprising:
the client interface module is used for receiving a page performance data query condition submitted by a client; and returning the query result to the client;
and the data query analysis module is used for extracting corresponding overall page performance data, page element performance data and/or page performance parameters from the overall page information table, the page element information table and/or the page performance parameter table according to the query conditions to generate a query result.
12. The apparatus of claim 10 or 11, wherein the performance parameter calculation module further comprises:
the page overall information acquisition submodule is used for extracting the overall downloading time of all pages of the page monitoring point within a certain time range from the overall page information table;
the initial average value calculation submodule is used for calculating an initial average value of the total downloading time of the page;
and the first recording submodule is used for storing the initial average value into a page performance parameter table.
13. The apparatus of claim 12, wherein the performance parameter calculation module further comprises:
the abnormal data judgment submodule is used for generating an abnormal data judgment threshold value according to the initial average value and determining the total downloading time and the number of abnormal pages according to the abnormal data judgment threshold value;
the new average value calculation submodule is used for removing the abnormal page total download time and recalculating a new average value for the remaining page total download time;
and the second recording submodule is used for recording the abnormal data judgment threshold, the quantity of the abnormal page total downloading time and/or the new average value into a page performance parameter table.
14. The apparatus of claim 13, wherein the performance parameter calculation module further comprises:
the page element information acquisition submodule is used for extracting page element performance data sets with the same attribute of the page monitoring points within a certain time range from the whole page information table;
the element average value calculating submodule is used for calculating the average value of the downloading time of each page element in the page element performance data set;
and the third recording sub-module is used for recording the element average value into a page performance parameter table.
15. A system for page performance testing, comprising:
at the server side:
the data acquisition module is used for acquiring the overall page performance data and the page element performance data of the page monitoring points and respectively storing the data into the overall page information table and the page element information table;
the classification statistical module is used for counting page element performance data with the same attribute, generating a corresponding page element performance data set and adding the corresponding page element performance data set into the whole page information table;
the performance parameter calculation module is used for calculating the performance parameters of the page monitoring points according to the whole page performance data and/or the corresponding page element performance data set in the whole page information table and storing the page performance parameters into a page performance parameter table;
the client interface module is used for receiving a page performance data query condition submitted by a client; and returning the query result to the client;
the data query analysis module is used for extracting corresponding overall page performance data, page element performance data and/or page performance parameters from the overall page information table, the page element information table and/or the page performance parameter table according to the query conditions to generate a query result;
at the client side:
the server communication module is used for submitting the page performance data query conditions to the server; receiving a query result returned by the server;
and the display module is used for displaying the query result.
HK10105758.9A 2010-06-10 Method, apparatus and system for testing page performance HK1138965B (en)

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN2008101347517A CN101635655B (en) 2008-07-25 2008-07-25 Method, device and system for page performance test

Publications (2)

Publication Number Publication Date
HK1138965A1 HK1138965A1 (en) 2010-09-03
HK1138965B true HK1138965B (en) 2012-06-01

Family

ID=

Similar Documents

Publication Publication Date Title
CN111522922B (en) Log information query method, device, storage medium and computer equipment
US11588922B2 (en) Capturing and replaying application sessions using resource files
US9628349B2 (en) Interactivity analyses of web resources based on reload events
CN110245069B (en) Page version testing method and device and page display method and device
US10362086B2 (en) Method and system for automating submission of issue reports
CN101635655A (en) Method, device and system for page performance test
US20130007205A1 (en) Intelligent offline caching of non-navigated content based on usage metrics
CN112035205B (en) Data processing method, device, equipment and storage medium
CN111177623A (en) Information processing method and device
CN104765746B (en) Data processing method and device for mobile communication terminal browser
CN110929183A (en) Data processing method, device and machine readable medium
CN110750443A (en) Webpage testing method and device, computer equipment and storage medium
CN107203470B (en) Page adjustment method and device
CN109324822B (en) PWA (public warning assistant) item detection method, computer-readable storage medium and terminal device
CN114371969B (en) Page performance testing method and device, electronic equipment and storage medium
CN104753979A (en) Method, server, terminal and system for displaying website information
CN112559278A (en) Method and device for acquiring operation data
CN112835793B (en) Webpage debugging method and device
CN111651330B (en) Data acquisition method, data acquisition device, electronic equipment and computer readable storage medium
JP5300648B2 (en) RECOMMENDATION INFORMATION PROVIDING DEVICE, USER TERMINAL, OPERATION RECOMMENDING METHOD, AND PROGRAM
CN105338091A (en) High-transmission-efficiency personalized information interface display method and apparatus
CN112463398A (en) File transmission method and device, terminal equipment and storage medium
CN112671615B (en) Method, system and storage medium for collecting front-end user operation behavior data
HK1138965B (en) Method, apparatus and system for testing page performance
CN119892656B (en) Analysis method and related device of network request