Page lagging detection method and system, electronic equipment, storage medium and product
By collecting page perception information on the client and reporting it to the server, the problem of untimely feedback from traditional page stutter detection methods and low matching of front-end perception is solved, and the rapid detection of page stuttering and timely perception of front-end usage is achieved. Improves the accuracy of fault handling efficiency and impact range.
Patent Information
- Application Number
- CN202411232900.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-04
- Publication Date
- 2025-01-10
AI Technical Summary
The traditional page stutter detection method is post-event analysis, and the feedback is not timely and the front-end usage cannot be sensed in time, which makes the front-end stuttering difficult to detect autonomously, and the impact range is difficult to accurately measure. The front-line salesperson has a relatively weak understanding of Internet technology, which leads to information transmission errors. , affect the direction of troubleshooting analysis.
By collecting the perceived information of the user when browsing the business system page on the client, the duration of the target page element, the status of the browser resource usage and abnormal information are detected. If a lag is detected, it will be reported to the server. The server determines the user's browsing based on this information. The system fluency during the page enables real-time and effective monitoring of front-end perception.
It realizes rapid detection of page lag and timely perception of front-end usage, ensures consistency with user perception, analyzes front-end user experience in real time, reduces fault processing time, improves accurate measurement of the impact range, and reduces the possibility of information transmission errors sex.
Smart Images

Figure CN119293358A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer technology, and in particular to a page jam detection method, system, electronic device, storage medium and product. Background Art
[0002] Page jams refer to the delay and unsmoothness that occurs when a page is loaded or scrolled when browsing the web using a computer, mobile phone or other device. Currently, methods such as network delay, network jitter, packet loss, system performance, and resource capacity are commonly used to detect page jams.
[0003] However, the traditional method of detecting page jams is a post-analysis method, which has problems such as delayed feedback, difficulty in reproduction, and difficulty in case collection. In addition, the traditional detection method is a back-end detection method and cannot perceive the front-end usage in a timely manner.
[0004] Therefore, how to quickly detect page freezes and timely perceive front-end usage is a problem that needs to be solved urgently. Summary of the invention
[0005] The present invention provides a page jam detection method, system, electronic device, storage medium and product, which are used to solve the defects of the traditional page jam detection method in the prior art, that is, post-analysis, untimely feedback, and inability to timely perceive the front-end usage, and realize rapid detection of page jams and timely perception of the front-end usage.
[0006] The present invention provides a page jam detection method, which is applied to a client, and the method comprises: Collecting user perception information when browsing business system pages; the perception information includes target page elements used to represent the content being loaded; If it is detected that the target page element continues to appear in the business system page for a time longer than the preset freeze duration, it is determined that the business system is freezed, and the first type of freeze information is reported to the server, so that the server determines the system fluency perceived by the user when browsing the business system page based on the reported freeze information.
[0007] According to a page jam detection method provided by the present invention, the duration of the continuous appearance of the target page element is determined by the following method: If the target page element is detected in the business system page in the current detection cycle, the appearance time of the target page element is recorded; If the target page element is detected to exist in the business system page in the next detection cycle, continue to detect until it is detected that the target page element does not exist in the business system page, and record the disappearance time of the target page element; Based on the disappearance time of the target page element and the appearance time of the target page element, the continuous appearance time of the target page element in the business system page is calculated.
[0008] According to a page jam detection method provided by the present invention, the perception information also includes the browser resource usage status, abnormal information for indicating the existence of a problem, and operation information for a business system menu; the method also includes: If it is detected that the browser resource usage state is in a busy state, it is determined that the business system is stuck, and the second type of stuck information is reported to the server; If abnormal information is detected on the business system page, it is determined that there is a freeze in the business system, and the third type of freeze information is reported to the server; If it is detected that the frequency of opening operations on the business system menu is greater than the preset frequency, it is determined that there is a freeze in the business system, and the fourth type of freeze information is reported to the server.
[0009] According to a page jam detection method provided by the present invention, the browser resource usage status is determined in the following manner: Inserting a preset task execution request into the browser's thread queue at a preset time interval; If the execution time interval of the preset task is greater than the preset time interval, determining that the browser resource usage state is a busy state; If the execution time interval of the preset task is equal to the preset time interval, it is determined that the browser resource usage state is an idle state.
[0010] According to a page jam detection method provided by the present invention, the collecting of perception information of a user when browsing a business system page includes: When the business system loads the page, start the perception information collection script; The perception information collection script is used to periodically collect the perception information of users when they browse the business system pages.
[0011] The present invention also provides another page jam detection method, which is applied to a server, and the method comprises: Get various freeze information reported by the client; For each jamming indicator, determine the number of jamming points of the jamming indicator according to the number of reports of jamming information corresponding to the jamming indicator within a preset time period; Determine the weight of each jam indicator based on its importance to the jam of the business system; Based on the number of jamming points and corresponding weights of each jamming indicator within the preset time period, the system fluency perceived by the user when browsing the business system page on the client within the preset time period is determined.
[0012] According to a page jamming detection method provided by the present invention, the weight of each jamming indicator is determined based on the importance of each jamming indicator to the jamming of the business system, including: Determine the order relationship of each jam indicator based on its importance to the jam of the business system; The weight of each jamming indicator is determined based on the ratio of the importance of two adjacent jamming indicators in the jamming indicator sequence relationship.
[0013] According to a page jamming detection method provided by the present invention, the system fluency perceived by the user when browsing the business system page on the client within the preset time period is determined based on the number of jamming points and the corresponding weights of each jamming indicator within the preset time period, including: Calculate the quantified value of the degree of jamming of the business system running on the client within the preset time period based on the number of jamming points and the corresponding weight of each jamming indicator within the preset time period; Based on the pre-fitted polynomial curve, the system fluency corresponding to the quantified value of the jamming degree of the business system is determined.
[0014] The present invention also provides a page jam detection system, comprising: The client is used to collect perception information of the user when using the business system; if a freeze is detected in the business system based on the perception information, the freeze information is reported to the server; The server is used to obtain various types of jamming information reported by the client; for each jamming indicator, according to the amount of jamming information corresponding to the jamming indicator within a preset time period, determine the number of jamming points of the jamming indicator; based on the importance of each jamming indicator to the jamming of the business system, determine the weight of each jamming indicator; based on the number of jamming points of each jamming indicator within the preset time period and the corresponding weight, determine the system fluency perceived by the user when browsing the business system page on the client within the preset time period.
[0015] The present invention also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the page jam detection method described above is implemented.
[0016] The present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the page jam detection method as described in any one of the above is implemented.
[0017] The present invention also provides a computer program product, including a computer program, which, when executed by a processor, implements any of the page jam detection methods described above.
[0018] The page jamming detection method, system, electronic device, storage medium and product provided by the present invention collect the perception information of the user when browsing the business system page through the front end, the perception information includes the target page element used to characterize the content being loaded, and detects whether the continuous appearance time of the target page element is greater than the preset jamming time to determine whether there is jamming in the business system. This can realize the rapid detection of the front-end jamming situation to ensure consistency with the user's perception; when it is detected that the continuous appearance time of the target page element in the business system page is greater than the preset jamming time, it is determined that there is jamming in the business system, and the first type of jamming information is reported to the server, so that the server determines the system fluency perceived by the user when browsing the business system page based on the reported jamming information, so that the back-end server can analyze the front-end user's perceived experience in real time, and realize real-time and effective monitoring of the front-end perception. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] In order to more clearly illustrate the technical solutions in the present invention or the prior art, a brief introduction will be given below to the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0020] Figure 1 This is one of the flow charts of the page jam detection method provided in an embodiment of the present invention.
[0021] Figure 2 It is a flow chart of performing page jam detection based on target page elements provided by an embodiment of the present invention.
[0022] Figure 3 It is a flow chart of detecting page jamming based on the occurrence of abnormal information provided by an embodiment of the present invention.
[0023] Figure 4 It is a flow chart of detecting page jamming based on the frequency of opening a business system menu provided by an embodiment of the present invention.
[0024] Figure 5 It is a schematic diagram of a browser JavaScript engine thread provided by an embodiment of the present invention.
[0025] Figure 6 It is a flow chart of detecting page freeze based on browser resource usage status provided by an embodiment of the present invention.
[0026] Figure 7 This is the second flow chart of the page jam detection method provided in an embodiment of the present invention.
[0027] Figure 8 4 is a schematic diagram of a relationship curve between F(w) and system fluency provided in an embodiment of the present invention.
[0028] Fig. 9 It is a structural diagram of a page jam detection system provided in an embodiment of the present invention.
[0029] Fig.10 It is a schematic diagram of the structure of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0030] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be clearly and completely described below in conjunction with the drawings of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0031] Front-end page performance is a key factor affecting user experience. If users spend too much time opening the website, the white screen lasts too long, or the operation is stuck, etc., these will cause users to leave the page, seriously affecting user retention rate.
[0032] Page lags can be caused by a variety of reasons: (1) Insufficient hardware performance: If the device's processing power, memory or graphics processing capabilities are insufficient, the computing resources required to load and render the page will be limited, resulting in page lags; (2) Network problems: If the network connection is unstable or slow, the page download time will be extended, resulting in slow page loading or even loading failure; (3) Complex web page content: Web pages contain a large number of images, videos, animations or complex scripts. These elements require more resources to load and process, which may cause page lags; (4) Script conflicts or errors: JavaScript scripts in web pages may contain errors or conflict with other scripts, resulting in problems with page loading and interaction; (5) Third-party plug-ins or extensions: Some browser plug-ins, ad blockers or security software may interfere with page loading or execution, resulting in page lags.
[0033] When a page freezes, users may experience slow page loading, unsmooth scrolling, or no response when clicking buttons or links. This is an important indicator of user experience. Currently, the detection method for page freezes is mainly through user feedback and retry and reproduction. It can also be detected through traditional back-end detection methods and tools, such as network latency, network jitter, packet loss, system performance, resource capacity, etc.
[0034] However, traditional page jam detection is a post-analysis method, which has problems such as delayed feedback, difficulty in reproducing, and difficulty in collecting cases. In addition, traditional detection methods do not match the front-end perception, cannot truly reflect the front-end perception, and do not have the ability to collect, store, and analyze page information in real time. Due to the lack of effective monitoring of the front end, the following problems are mainly faced in actual operation and maintenance: (1) Front-end lag is difficult to detect autonomously: Feedback on front-end lag is usually first discovered by front-line sales staff, who then report it to the superior back-end operation and maintenance through layers of escalation. The process is time-consuming and affects the efficiency of fault handling.
[0035] (2) The scope of impact is difficult to measure accurately: Due to the lack of effective monitoring at the front end, front-line sales staff can only provide feedback on the situation of a single business hall. The superior fault control center needs to inquire one by one and wait for statistical feedback at each level. There is no way to accurately determine the scope of impact.
[0036] (3) The scope of impact is difficult to measure accurately: Since front-line sales staff have relatively weak knowledge of Internet Technology (IT) systems, problems such as lag descriptions being unclear often occur, resulting in information transmission errors and affecting the direction of troubleshooting analysis.
[0037] In response to the above problems, an embodiment of the present invention collects perception information of users when browsing business system pages through the front end, the perception information includes a target page element used to characterize the content being loaded, and detects whether the continuous appearance duration of the target page element is greater than the preset freeze duration to determine whether there is a freeze in the business system. This can achieve rapid detection of front-end freezes to ensure consistency with user perception; when it is detected that the continuous appearance duration of the target page element in the business system page is greater than the preset freeze duration and it is determined that there is a freeze in the business system, the first type of freeze information is reported to the server, so that the server determines the system fluency perceived by the user when browsing the business system page based on the reported freeze information, so that the back-end server can analyze the front-end user's perceived experience in real time to achieve real-time and effective monitoring of the front-end perception.
[0038] Figure 1 This is one of the flow charts of the page jam detection method provided by the embodiment of the present invention. Figure 1 The present invention provides a method for detecting page jamming, which may include the following steps: Step 110, collecting perception information of the user when browsing the business system page; the perception information includes a target page element used to represent that the content is being loaded.
[0039] It should be noted that the execution subject of the page jam detection method provided in the embodiment of the present invention may be a client, or an electronic device for running the client, a component in an electronic device, an integrated circuit or a chip. The electronic device may be a mobile electronic device or a non-mobile electronic device. Exemplarily, the mobile electronic device may be a mobile phone, a tablet computer, a laptop computer, a PDA, a wearable device, an ultra-mobile personal computer (UMPC), a netbook or a personal digital assistant (PDA), etc., and the non-mobile electronic device may be a server, a network attached storage (NAS), a personal computer (PC), a television (TV), a teller machine or a self-service machine, etc., which is not specifically limited in the embodiment of the present invention.
[0040] The following embodiments of the present invention are described with the client as the execution subject. In the embodiments of the present invention, the client can periodically collect the perception information of the user when browsing the business system page, so as to quickly detect whether there is a freeze in the business system based on the perception information collected periodically; if the business system is detected to be freezed, the freeze information is reported to the server. The server can determine the system fluency perceived by the user when browsing the business system page based on the freeze information reported by the client, so as to analyze the front-end user's perception experience in real time.
[0041] It should be noted that the detection of jamming in the business system by the client is different from the perception of jamming by the user. For example, when a small number of jams are detected in the business system, the front-end user may not be able to perceive the page jamming; when a large number of jams are detected in the business system, the front-end user may be able to perceive the page jamming. In the embodiment of the present invention, the client detects the jamming of the business system and reports it to the server, and the server analyzes the front-end user's perception of the page jamming based on the jamming reported by the client, thereby analyzing the front-end user's perceived experience in real time.
[0042] Specifically, the perception information collected by the client may be multi-dimensional perception information, such as target page elements representing content being loaded, browser resource usage status, abnormal information indicating problems, and operation information for business system menus.
[0043] Among them, the target page elements can be determined by analyzing the business system, for example, they can include a spinning icon, a loading animation, a text prompt of "obtaining information", a text prompt of "please wait", etc.
[0044] The target page element can be implemented through the following configuration: "circleAroundKeyWord": (keyword)
[0045] / <\ / i> <!----> Search
[0046] |class="el-loading-mask" style="">
[0047] |class="panel-loading-big">
[0048] | Authentication method is loading...
[0049] |<div class="datagrid-mask-msg" style="display: block; |
[0050] | <\ / i> / g
[0051] The above are common jamming patterns in business systems. The client can identify these configurations when collecting data, thereby collecting target page elements for page jamming analysis and determining whether there is jamming in the business system.
[0052] Step 120: If it is detected that the target page element continues to appear in the business system page for a time longer than the preset freeze duration, it is determined that the business system is freezed, and the first type of freeze information is reported to the server, so that the server determines the system fluency perceived by the user when browsing the business system page based on the reported freeze information.
[0053] The first type of jamming information may refer to a jamming indicator based on the duration of the continuous appearance of the target page element. When a jam is detected in the business system, the jam information is generated based on the detected jam. Specifically, when the user browses the business system page, the client can periodically search for the target page element that represents the content being loaded in the business system page, thereby detecting whether the duration of the continuous appearance of the target page element on the business system page is greater than the preset jam duration. If it is detected that the continuous appearance of the target page element on the business system page is greater than the preset jam duration, it means that there is a jam in the business system, and the jam information can be reported to the server.
[0054] If it is detected that the target page element appears continuously on the business system page for a time that is less than or equal to the preset freeze duration, it means that there is no freeze in the business system and the freeze information does not need to be reported.
[0055] Among them, the freeze information may include browser information, current freeze page information, freeze time, freeze duration, page parameter information, etc.
[0056] In actual applications, the preset freeze duration can be determined based on historical experience, for example, it can be set to 5s.
[0057] The embodiment of the present invention collects perception information of users when browsing business system pages through the front end, the perception information includes target page elements used to characterize that content is being loaded, and detects whether the continuous appearance duration of the target page elements is greater than the preset freeze duration to determine whether there is freeze in the business system. This can achieve rapid detection of front-end freeze conditions to ensure consistency with user perception; by detecting that the continuous appearance duration of the target page elements in the business system page is greater than the preset freeze duration and determining that there is freeze in the business system, the first type of freeze information is reported to the server, so that the server determines the system fluency perceived by the user when browsing the business system page based on the reported freeze information, so that the back-end server can analyze the front-end user's perceived experience in real time, and achieve real-time and effective monitoring of the front-end perception.
[0058] Based on any of the above embodiments, the continuous appearance duration of the target page element can be determined in the following manner: if the target page element is detected to exist in the business system page in the current detection cycle, the appearance time of the target page element is recorded; if the target page element is detected to exist in the business system page in the next detection cycle, the detection is continued until it is detected that the target page element does not exist in the business system page, and the disappearance time of the target page element is recorded; based on the disappearance time of the target page element and the appearance time of the target page element, the continuous appearance duration of the target page element in the business system page is calculated.
[0059] Figure 2 is a flow chart of detecting page jamming based on target page elements provided by an embodiment of the present invention. Figure 2 After the business system page is loaded, you can embed JavaScript to set a scheduled job on the page. For example, set 1s as the detection and collection cycle, and use regular expressions to detect the configured target page elements in the business system page.
[0060] If a target page element is detected in the business system page in the current detection cycle, the appearance time of the target page element can be recorded. Specifically, the operation time of the current detection cycle can be used as the appearance time of the target page element.
[0061] If in the next detection cycle, it is detected that the target page element still exists in the business system page, then continue to detect whether the target page element exists in the business system page in subsequent detection cycles until it is detected that the target page element does not exist in the business system page, and record the disappearance time of the target page element; if in the next detection cycle, it is detected that the target page element does not exist in the business system page, then the previously recorded appearance time of the target page element can be deleted, indicating that there is no page jamming phenomenon in this detection cycle. Specifically, if the target page element is detected to disappear until the target detection cycle, the operation time of the target detection cycle can be used as the disappearance time of the target page element.
[0062] After the target page element disappears, the difference between the disappearance time and the appearance time of the target page element can be calculated to obtain the continuous appearance time of the target page element in the business system page, so as to determine whether the business system has a jam according to the continuous appearance time of the target page element.
[0063] As an example, the operator needs to query the number information before accepting the business. After performing the number search operation, a rotating waiting animation will appear on the search button. At this time, the first detection cycle detects that there is a [ <\ / i> <!----> Search for the <\ / span>|class="el-loading-mask" style="">] element and record the time when the element appears.
[0064] In the second detection cycle, the page detection is performed. If the page is detected at this time, <\ / i> <!----> If the search <\ / span>|class="el-loading-mask" style="">】element does not exist, the information recorded in the first cycle is deleted, and it is not considered that there is a lag in this query.
[0065] If the feature element is detected in the second detection cycle, the page search continues in the third detection cycle. <\ / i> <!----> Search for the <\ / span>|class="el-loading-mask" style="">] element. If the page does not have this characteristic element, calculate the difference between the first appearance time and the disappearance time of this characteristic element. If it exists, continue to detect in the next detection cycle until the characteristic element disappears.
[0066] In the embodiment of the present invention, by detecting whether the target page element exists on the page in each detection cycle, recording the difference between the first appearance time and the disappearance time of the target page element, and obtaining the duration of continuous appearance of the element, it can be further determined whether the business system has a freeze by judging whether the duration of continuous appearance of the element is greater than the preset freeze duration. It can realize the rapid detection of the front-end freeze situation, which is beneficial to ensuring consistency with the user perception.
[0067] Based on any of the above embodiments, the collecting of the perception information when the user browses the business system page specifically may include: when the business system loads the page, start the perception information collection script; through the perception information collection script, periodically collect the perception information when the user browses the business system page.
[0068] Specifically, the front-end perception information collection script can be injected into the business system, and the collection script can be started while the business system loads the page. The collection script can collect the user's usage behavior on the browser in real time and transmit the perception information to the server in real time. The injection of the collection script into the business system can be injected in a proxy-undetectable manner to achieve zero transformation of the business system. The undetectable injection method can be as follows: "gsub": {
[0069] "": "<script type='text / javascript' src=' / / cdn.vortex.zj.chinamobile.
[0070] com / aiapm-agent / aiapm.js'>"
[0071] }
[0072] In the embodiment of the present invention, through the buried-point collection technology that is embedded in the front-end page without transformation, the collection script is started while the business system loads the page. The collection script collects the user's usage behavior on the browser in real time and transmits the collected perception information to the server in real time. Since the injection of the collection script into the business system is injected in a proxy-undetectable manner, zero transformation of the business system is achieved, which does not affect the operation of the business system. It can analyze the data of each link of the browser loading the page in real time, which is beneficial to timely discovering the freeze influencing factors and quickly detecting the page freeze.
[0073] Based on any of the above embodiments, the perception information also includes the browser resource usage status, abnormal information for indicating the existence of a problem, and operation information for the business system menu; the method may also include the following steps: Step 210: If it is detected that the browser resource usage status is busy, it is determined that the business system is stuck, and the second type of stuck information is reported to the server.
[0074] The browser resource usage state may include a busy state and an idle state. In the embodiment of the present invention, it is possible to determine whether the business system is stuck based on the browser resource usage.
[0075] The second type of jamming information may refer to jamming indicators based on the browser resource usage status. When jamming is detected in the business system, jamming information is generated based on the detected jamming situation. If the browser resource usage status is detected to be busy, it can be said that there is jamming in the business system, and the jamming information can be reported to the server. If the browser resource usage status is detected to be idle, it can be said that there is no jamming in the business system, and the jamming information may not be reported to the server.
[0076] Step 220: If abnormal information is detected on the business system page, it is determined that there is a freeze in the business system, and the third type of freeze information is reported to the server.
[0077] Abnormal information may refer to information used to indicate a problem. When there is a problem with the business system server, network, or page code, abnormal information will appear on the business system page.
[0078] The abnormal information may be determined by analyzing the business system, for example, as shown in the following Table 1: Table 1
[0079] Figure 3 1 is a flow chart of detecting page jamming based on abnormal information provided by an embodiment of the present invention. Figure 3 After the business system page is loaded, you can embed JavaScript to set a scheduled job on the page. For example, set 1s as the detection and collection cycle, and use regular expressions to detect the configured abnormal information keywords in the business system page.
[0080] The third type of jamming information may refer to jamming indicators based on whether abnormal information appears on the page. When jamming is detected in the business system, jamming information is generated based on the detected jamming situation. If abnormal information keywords are detected in the business system page, it means that there is jamming in the business system, and the jamming information can be reported to the server. If no abnormal information is detected on the business system page, it means that there is no jamming in the business system, and there is no need to report the jamming information.
[0081] In some optional embodiments, when it is detected that abnormal information appears frequently in the business system page, it can be determined that there is a freeze in the business system, and the freeze information is reported.
[0082] Step 230: If it is detected that the frequency of opening the business system menu is greater than the preset frequency, it is determined that there is a freeze in the business system, and the fourth type of freeze information is reported to the server.
[0083] The fourth type of jamming information may refer to a jamming indicator based on the frequency of opening the business system menu. When a jamming is detected in the business system, jamming information is generated based on the detected jamming situation.
[0084] Figure 4 1 is a flow chart of detecting page jamming based on the frequency of opening a menu of a business system according to an embodiment of the present invention. Figure 4 If the frequency of opening the business system menu is greater than the preset frequency, it means that the business system has a stuck phenomenon, and the stuck information can be reported to the server. If the frequency of opening the business system menu is less than or equal to the preset frequency, it means that the business system does not have a stuck phenomenon, and there is no need to report the stuck information.
[0085] The embodiments of the present invention collect multi-dimensional perception information such as target page elements that characterize the loading of content, browser resource usage status, abnormal information that indicates problems, and operation information for business system menus, and detect whether there is a jam in the business system based on the multi-dimensional perception information. This allows page jam detection to match the actual user perception. Furthermore, the scope of jam impact can be changed from difficult to measure to measurable, and front-end jam problems can be detected and discovered before front-line personnel report the fault, thereby achieving rapid detection of front-end jam conditions.
[0086] Based on any of the above embodiments, the browser resource usage status can be determined in the following manner: inserting a preset task execution request into the browser's thread queue at a preset time interval; if the execution time interval of the preset task is greater than the preset time interval, determining that the browser resource usage status is a busy state; if the execution time interval of the preset task is equal to the preset time interval, determining that the browser resource usage status is an idle state.
[0087] Figure 5 Schematic diagram of a browser JavaScript engine thread provided by an embodiment of the present invention. Figure 5 , the browser rendering is single-threaded, and only JavaScript calculations or user interface (UI) rendering can be performed at the same time point, and the two actions cannot be performed at the same time. The browser JavaScript engine threads are executed one by one in chronological order. If the function block currently being processed at time point t1 takes a long time, then the click event at time point t2 will not be able to proceed, and must wait for the row number block to be executed. At this time, the user's click action will feel a lag.
[0088] Since the browser is single-threaded, if a freeze occurs, the subsequent queue accumulation method cannot be executed. The embodiment of the present invention configures a timer to insert a preset task into the browser's thread queue for execution every time t (i.e., periodic dotting); if the thread queue is idle, the browser can check that the preset task can be called once on time at the preset time interval t each time; if the thread queue is busy, the execution time interval of the preset task will be greater than the preset time interval t.
[0089] Figure 6 1 is a flow chart of detecting page jamming based on the browser resource usage status provided by an embodiment of the present invention. Figure 6 After the business system page is loaded, you can embed JavaScript in the page to set a scheduled job. For example, set 100ms as the detection and collection period. By periodically marking, calculate the time interval between two adjacent markings, and analyze the page rendering and JavaScript runtime central processing unit (CPU) resource usage. The page that takes more than the preset time interval between two markings is considered a stuck page.
[0090] The embodiment of the present invention inserts a preset task execution request into the browser's thread queue, and determines whether there is a jam in the business system by judging whether the execution time interval of the preset task is greater than the preset time interval. This can achieve rapid detection of front-end jams, which is conducive to ensuring consistency with user perception.
[0091] Figure 7 This is a second flow chart of the page jam detection method provided by an embodiment of the present invention. Figure 7 The present invention provides a method for detecting page jamming, which may include the following steps: Step 710, obtaining various types of freeze information reported by the client.
[0092] It should be noted that the execution subject of the page jam detection method provided in the embodiment of the present invention may be a server. In the embodiment of the present invention, the client can regularly collect various types of perception information when the user browses the business system page, so as to quickly detect whether the business system has jams based on the regularly collected perception information; if jams are detected in the business system, the jam information is reported to the server.
[0093] Specifically, the jam information reported by the client in real time can be received asynchronously. After receiving the request, the server can immediately respond to the client, pre-process the reported jam information and send it to the message middleware (kafka), so as to avoid affecting the business system. Messages can be consumed from the message middleware, and the jam information can be classified and processed, so that different types of jam information can be stored in the vector database. The server can analyze and mine various types of jam information to determine the system fluency perceived by users when browsing the business system pages, so as to timely perceive the front-end usage.
[0094] Step 720, for each jamming indicator, determine the number of jamming points of the jamming indicator according to the number of reports of jamming information corresponding to the jamming indicator within a preset time period.
[0095] Different types of jamming information are obtained by performing page jamming detection on different types of perception information, and different types of perception information correspond to different jamming indicators. In an embodiment of the present invention, for each jamming indicator, the number of jamming points of each jamming indicator can be determined according to the number of reports of jamming information corresponding to each jamming indicator within a preset time period.
[0096] Exemplarily, for the following four types of jamming indicators: jamming indicators of the duration of the target page elements (hereinafter referred to as the first type of indicators), jamming indicators of the browser resource usage status (hereinafter referred to as the second type of indicators), jamming indicators of the frequency of opening the business system menu (hereinafter referred to as the third type of indicators), and jamming indicators of whether abnormal information appears on the page (hereinafter referred to as the fourth type of indicators). If within the preset time period, the client reports the first type of jamming information to the server 3 times, the second type of jamming information 4 times, the third type of jamming information 3 times, and the fourth type of jamming information 2 times, then it can be determined that the number of jamming points of the first type of jamming indicator is 3, the number of jamming points of the second type of jamming indicator is 4, the number of jamming points of the third type of jamming indicator is 3, and the number of jamming points of the fourth type of jamming indicator is 2.
[0097] It should be noted that when certain jamming indicators exceed a certain proportion and become abnormal, it is possible to consider whether other reasons are causing the problem, such as network, database, firewall, host or system failure, so that manual intervention can be required to check and solve the problem.
[0098] Step 730, based on the importance of each jamming indicator to the jamming of the business system, determine the weight of each jamming indicator.
[0099] Specifically, based on the importance of various types of jamming indicators relative to the jamming impact of the business system, multiple indicators can be comprehensively considered, and corresponding weights can be assigned to each jamming indicator to obtain the weight of each jamming indicator.
[0100] Step 740, based on the number of jamming points and the corresponding weights of each jamming indicator within the preset time period, determine the system fluency perceived by the user when browsing the business system page on the client within the preset time period.
[0101] Specifically, a weighted average calculation can be performed based on the number of jamming points and corresponding weights of each jamming indicator within a preset time period, thereby determining the system fluency perceived by the user when browsing the business system page on the client within the preset time period.
[0102] The embodiment of the present invention obtains the jamming information reported by the client in real time, determines the number of jamming points of each jamming indicator based on the number of reports of each type of jamming information, and determines the system fluency perceived by the user when browsing the business system page on the client within the preset time period based on the number of jamming points of each jamming indicator within the preset time period and the corresponding weight. It can not only analyze the front-end user perceived experience in real time, but also quantify the user's front-end perception by quantifying the impact of different factors on page jams, thereby realizing real-time and effective monitoring of the front-end perception.
[0103] Based on any of the above embodiments, determining the weight of each jamming indicator based on the importance of each jamming indicator to the jamming of the business system may specifically include: determining the jamming indicator sequence relationship based on the importance of each jamming indicator to the jamming of the business system; determining the weight of each jamming indicator based on the ratio of the importance of two adjacent jamming indicators in the jamming indicator sequence relationship.
[0104] In the embodiment of the present invention, multiple jamming indicators can be considered according to the importance of each type of jamming indicator to the jamming of the business system, and a corresponding weight can be assigned to each jamming indicator. k-1 With x k The relative importance between k =x k-1 / x k The assignment can be referred to in Table 2: Table 2
[0105] Specifically, if the importance of the jamming indicator relative to the jamming of the business system is greater than or equal to another jamming indicator, it can be recorded as x k-1 >x k About r k If x1, x2, ..., x m With the order relationship x1>x2>…>x m, Then r k With r k-1 Satisfies the following relationship
[0106] (1); If r is given k The reference assignment satisfies the above relationship, then the jam index x m The weight w m for
[0107] (2); and (3); The weights corresponding to each jam indicator can be calculated through the above formula.
[0108] As an example, the evaluation index for user-perceived page jamming may include the first index x1, the second index x2, the third index x3, and the fourth index x4, and determine that x1, x2, x3, and x4 have an order relationship x2>x1>x4>x3, giving r k The values of r2=w1 / w2=1.4, r3=w2 / w3=1.2, r4=w3 / w4=1.6, and r2r3r4=2.688, r3r4=1.920, r4=1.600, r2r3r4+r3r4+r4=6.208, so the weight w4 corresponding to the fourth category of indicators can be calculated based on formula (2) = (1+6.208) -1 =0.1387. Based on formula (3), the weight corresponding to the third category of indicators is w3=0.2220, the weight corresponding to the second category of indicators is w2=0.2664, and the weight corresponding to the first category of indicators is w1=0.3729.
[0109] Based on any of the above embodiments, determining the system fluency perceived by the user when browsing the business system page on the client within the preset time period based on the number of jamming points of each jamming indicator within the preset time period and the corresponding weight, can specifically include: calculating the quantified value of the jamming degree of the business system running on the client within the preset time period based on the number of jamming points of each jamming indicator within the preset time period and the corresponding weight; determining the system fluency corresponding to the quantified value of the jamming degree of the business system based on a pre-fitted polynomial curve.
[0110] Specifically, the jam level of the business system can be composed of front-end jam collection indicators, and the quantified value of the jam level of the business system can be as follows: (4); Among them, w i is the jam index x i The corresponding weight, F(x i ) is the jam index x i The embodiment of the present invention obtains a quantified value of the jamming degree of the business system by performing weighted summation according to the number of jamming points of each jamming indicator and the corresponding weight. The magnitude of the quantified value of the jamming degree can reflect the jamming degree of the business system within a preset time.
[0111] When fitting, the ability to provide feedback on jams can be added to the front end of the business system. When front-line users feel jams, they can send feedback to the server with one click. The server can perform machine learning on the F(w) calculated at each time slice and the front-line perception collected in real time, and train the relationship curve between F(w) and system fluency.
[0112] Specifically, a polynomial curve can be used for fitting. In order to obtain a better fitting effect, the order of the curve equation can be N=9. The polynomial curve equation can be shown as follows: (5); In an embodiment of the present invention, the system fluency corresponding to the quantified value F(w) of the degree of jamming of the business system can be determined based on a pre-fitted polynomial curve between F(w) and the system fluency, and then corresponding processing measures can be taken based on the system fluency.
[0113] Figure 8 is a schematic diagram of the relationship curve between F(w) and system fluency provided by an embodiment of the present invention. Figure 8 ,System fluency can include three stages, and different treatment measures can be taken based on ,different stages.
[0114] When it is in stage ①, it means that the system occasionally freezes, and the number of perceptible freezes is less than 12 times, which can be considered as good perception. At this time, the system can issue risk warnings for some of the freezes, and intervene to check the specific freezes and menus, analyze the causes, and formulate corresponding solutions and avoidance emergency measures.
[0115] When it is in stage ②, it means that the system has a large-scale freeze, the number of perceptible freeze points is between 13 and 30 times, and the front-line users can feel it clearly. At this time, a business impact warning can be issued, various system monitoring methods can be checked, and measures such as restart and capacity expansion can be implemented.
[0116] If the system is in stage ③, it means that the system is seriously stuck and the number of times the stuck points are felt exceeds 30 times. At this time, a business interruption warning can be issued and the emergency system can be switched.
[0117] The embodiment of the present invention is based on the idea of regression to quantify the impact of different factors on business stalling delays, and obtains the relationship curve between the degree of system stalling and system fluency through polynomial curve fitting, which can realize real-time and effective monitoring of front-end perception.
[0118] In summary, how to make operation and maintenance outperform user reports and quickly detect front-end freezes is an urgent problem to be solved. The embodiment of the present invention is different from traditional back-end monitoring technology, and can achieve page freeze detection that is consistent with user perception, thereby perceiving the front-end usage in real time. Since there are many factors affecting system freezes, the embodiment of the present invention adopts the idea of regression to quantify the impact of different factors on business freeze delays, and establishes a business delay freeze scenario model. It can find a response standard and normal fluctuation range for each scenario, realize the detection of front-end business responses and 1v1 real playback, quickly discover system front-end freezes, and effectively detect the front-end user experience.
[0119] Fig. 9 is a schematic diagram of the structure of a page jam detection system provided by an embodiment of the present invention. Fig. 9 , an embodiment of the present invention provides a page jam detection system, which may specifically include: The client 910 is used to collect perception information of the user when using the business system; if a freeze is detected in the business system based on the perception information, the freeze information is reported to the server; Server 920 is used to obtain various types of jamming information reported by the client; for each jamming indicator, the number of jamming points of the jamming indicator is determined according to the number of jamming information corresponding to the jamming indicator within a preset time period; the weight of each jamming indicator is determined based on the importance of each jamming indicator to the jamming of the business system; based on the number of jamming points of each jamming indicator within the preset time period and the corresponding weight, the system fluency perceived by the user when browsing the business system page on the client within the preset time period is determined.
[0120] The embodiment of the present invention collects perception information of users when browsing business system pages through the front end, the perception information includes target page elements used to characterize that content is being loaded, and detects whether the continuous appearance duration of the target page elements is greater than the preset freeze duration to determine whether there is freeze in the business system. This can achieve rapid detection of front-end freeze conditions to ensure consistency with user perception; by detecting that the continuous appearance duration of the target page elements in the business system page is greater than the preset freeze duration and determining that there is freeze in the business system, the first type of freeze information is reported to the server, so that the server determines the system fluency perceived by the user when browsing the business system page based on the reported freeze information, so that the back-end server can analyze the front-end user's perceived experience in real time, and achieve real-time and effective monitoring of the front-end perception.
[0121] Fig.10 An example of a physical structure diagram of an electronic device is shown in FIG. Fig.10 As shown, the electronic device may include: a processor 1010, a communication interface 1020, a memory 1030 and a communication bus 1040, wherein the processor 1010, the communication interface 1020 and the memory 1030 communicate with each other through the communication bus 1040. The processor 1010 may call the logic instructions in the memory 1030 to execute the page jam detection method, which includes: collecting the perception information of the user when browsing the business system page; the perception information includes the target page element used to characterize the content being loaded; if it is detected that the target page element continues to appear in the business system page for a time longer than the preset jam duration, it is determined that the business system has jams, and the first type of jam information is reported to the server, so that the server determines the system fluency perceived by the user when browsing the business system page based on the reported jam information.
[0122] In addition, the logic instructions in the above-mentioned memory 1030 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when it is sold or used as an independent product. Based on such an understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including several instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk, etc. Various media that can store program codes.
[0123] On the other hand, the present invention also provides a computer program product, which includes a computer program, and the computer program can be stored on a non-transitory computer-readable storage medium. When the computer program is executed by a processor, the computer can execute the page jam detection method provided by the above methods, and the method includes: collecting perception information of the user when browsing the business system page; the perception information includes a target page element for characterizing that the content is being loaded; if it is detected that the continuous appearance time of the target page element in the business system page is greater than the preset jam duration, it is determined that there is jam in the business system, and the first type of jam information is reported to the server, so that the server determines the system fluency perceived by the user when browsing the business system page based on the reported jam information.
[0124] On the other hand, the present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, is implemented to execute the page jam detection method provided by the above-mentioned methods, the method comprising: collecting perception information of a user when browsing a business system page; the perception information comprises a target page element for characterizing that content is being loaded; if it is detected that the target page element continues to appear in the business system page for a time period greater than a preset jam duration, it is determined that there is a jam in the business system, and a first type of jam information is reported to a server, so that the server determines the system fluency perceived by the user when browsing the business system page based on the reported jam information.
[0125] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without paying creative labor.
[0126] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, can also be implemented by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.
[0127] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A page jam detection method, characterized in that: Applied to a client, the method comprises: Collecting user perception information when browsing business system pages; the perception information includes target page elements used to represent the content being loaded; If it is detected that the target page element continues to appear in the business system page for a time longer than the preset freeze duration, it is determined that the business system is freezed, and the first type of freeze information is reported to the server, so that the server determines the system fluency perceived by the user when browsing the business system page based on the reported freeze information.
2. The page jam detection method according to claim 1, characterized in that: The duration of the target page element's continuous appearance is determined by: If the target page element is detected in the business system page in the current detection cycle, the appearance time of the target page element is recorded; If the target page element is detected to exist in the business system page in the next detection cycle, continue to detect until it is detected that the target page element does not exist in the business system page, and record the disappearance time of the target page element; Based on the disappearance time of the target page element and the appearance time of the target page element, the continuous appearance time of the target page element in the business system page is calculated.
3. The page jam detection method according to claim 1, characterized in that: The perception information also includes the browser resource usage status, abnormal information for indicating problems, and operation information for the business system menu; the method also includes: If it is detected that the browser resource usage state is in a busy state, it is determined that the business system is stuck, and the second type of stuck information is reported to the server; If abnormal information is detected on the business system page, it is determined that there is a freeze in the business system, and the third type of freeze information is reported to the server; If it is detected that the frequency of opening operations on the business system menu is greater than the preset frequency, it is determined that there is a freeze in the business system, and the fourth type of freeze information is reported to the server.
4. The page jam detection method according to claim 3, characterized in that: The browser resource usage status is determined in the following manner: Inserting a preset task execution request into the browser's thread queue at a preset time interval; If the execution time interval of the preset task is greater than the preset time interval, determining that the browser resource usage state is a busy state; If the execution time interval of the preset task is equal to the preset time interval, it is determined that the browser resource usage state is an idle state.
5. The page jam detection method according to claim 1, characterized in that: The collected user's perception information when browsing the business system page includes: When the business system loads the page, start the perception information collection script; The perception information collection script is used to periodically collect the perception information of users when they browse the business system pages.
6. A page jam detection method, characterized in that: Applied to a server, the method comprises: Get various freeze information reported by the client; For each jamming indicator, determine the number of jamming points of the jamming indicator according to the number of reports of jamming information corresponding to the jamming indicator within a preset time period; Determine the weight of each jam indicator based on its importance to the jam of the business system; Based on the number of jamming points and corresponding weights of each jamming indicator within the preset time period, the system fluency perceived by the user when browsing the business system page on the client within the preset time period is determined.
7. The page jam detection method according to claim 6, characterized in that: Determining the weight of each jam indicator based on the importance of each jam indicator to the jam of the business system includes: Determine the order relationship of each jam indicator based on its importance to the jam of the business system; The weight of each jamming indicator is determined based on the ratio of the importance of two adjacent jamming indicators in the jamming indicator sequence relationship.
8. The page jam detection method according to claim 6, characterized in that: The determining, based on the number of jamming points and corresponding weights of each jamming indicator within the preset time period, the system fluency perceived by the user when browsing the business system page on the client within the preset time period includes: Calculate the quantified value of the degree of jamming of the business system running on the client within the preset time period based on the number of jamming points and the corresponding weight of each jamming indicator within the preset time period; Based on the pre-fitted polynomial curve, the system fluency corresponding to the quantified value of the jamming degree of the business system is determined.
9. A page jam detection system, characterized in that: include: The client is used to collect user perception information when using the business system; If a freeze is detected in the business system based on the perception information, the freeze information is reported to the server; The server is used to obtain various types of jamming information reported by the client; for each jamming indicator, according to the number of jamming information corresponding to the jamming indicator in a preset time period, determine the number of jamming points of the jamming indicator; based on the importance of each jamming indicator to the jamming of the business system, determine the weight of each jamming indicator; Based on the number of jamming points and corresponding weights of each jamming indicator within the preset time period, the system fluency perceived by the user when browsing the business system page on the client within the preset time period is determined.
10. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the computer program, the page jam detection method as described in any one of claims 1-5 or 6-8 is implemented.
11. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by the processor, the page jam detection method as described in any one of claims 1-5 or 6-8 is implemented.
12. A computer program product, comprising a computer program, characterized in that When the computer program is executed by the processor, the page jam detection method as described in any one of claims 1-5 or 6-8 is implemented.