CN113722193A - Method and device for detecting page abnormity - Google Patents

Method and device for detecting page abnormity Download PDF

Info

Publication number
CN113722193A
CN113722193A CN202010479108.9A CN202010479108A CN113722193A CN 113722193 A CN113722193 A CN 113722193A CN 202010479108 A CN202010479108 A CN 202010479108A CN 113722193 A CN113722193 A CN 113722193A
Authority
CN
China
Prior art keywords
page
abnormal
request
identifier
cache
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202010479108.9A
Other languages
Chinese (zh)
Inventor
董焕强
姜岩
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Jingdong Century Trading Co Ltd
Beijing Wodong Tianjun Information Technology Co Ltd
Original Assignee
Beijing Jingdong Century Trading Co Ltd
Beijing Wodong Tianjun Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Jingdong Century Trading Co Ltd, Beijing Wodong Tianjun Information Technology Co Ltd filed Critical Beijing Jingdong Century Trading Co Ltd
Priority to CN202010479108.9A priority Critical patent/CN113722193A/en
Publication of CN113722193A publication Critical patent/CN113722193A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/34Recording or statistical evaluation of computer activity, e.g. of down time, of input/output operation ; Recording or statistical evaluation of user activity, e.g. usability assessment
    • G06F11/3452Performance evaluation by statistical analysis
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3604Software analysis for verifying properties of programs

Abstract

The invention discloses a method and a device for detecting page abnormity, and relates to the technical field of computers. One embodiment of the method comprises: counting the number of times of requests and abnormal times of key inquiry in a cache, wherein the request times and the abnormal times are generated by a user identifier and a page identifier within a preset time interval; calculating the page abnormality rate according to the ratio of the abnormality times to the request times; and comparing the page abnormal rate with a preset abnormal standard to determine that the page is in an abnormal state. The implementation method avoids the technical defects that the page abnormity can be detected only by excessively depending on the abnormal information of the client side in the prior art and the server cannot be compatible with the technical defect that the server normally sends the access request, so that the detection on whether the page is abnormal or not can be finished without depending on the data actively reported by the client side, and the technical effect of having compatibility on the conditions of mistaken clicking and the like of the user can be realized by the technical means of detecting through the server.

Description

Method and device for detecting page abnormity
Technical Field
The invention relates to the technical field of computers, in particular to a method and a device for detecting page abnormity.
Background
In the prior art, when detecting a page abnormality, a client sends information data of the website abnormality, and a server analyzes the information data to judge whether the page is abnormal.
In the process of implementing the invention, the inventor finds that at least the following problems exist in the prior art:
1. excessively depending on abnormal information of the client;
2. the determination of an abnormal page is not quantified.
Disclosure of Invention
In view of this, the embodiments of the present invention provide a method and system for detecting a page anomaly, which can avoid the technical defect that the page anomaly can be detected only by excessively depending on anomaly information of a client in the prior art and cannot be compatible with the technical defect that a server normally sends an access request, so that whether the page anomaly exists can be detected without depending on data actively reported by the client, and the technical effect of compatibility with the situations of a user clicking by mistake can be achieved by using a technical means for detecting the page anomaly by the server.
To achieve the above object, according to an aspect of the embodiments of the present invention, there is provided a method for detecting a page exception, including:
counting the number of times of requests and abnormal times of key inquiry in a cache, wherein the request times and the abnormal times are generated by a user identifier and a page identifier within a preset time interval;
Calculating the page abnormality rate according to the ratio of the abnormality times to the request times;
and comparing the page abnormal rate with a preset abnormal standard to determine that the page is in an abnormal state.
Optionally, the counting, within a preset time interval, the determining the number of times of requests and the number of times of exceptions of the query in the cache by the key generated by the user identifier and the page identifier includes:
judging whether a key generated by the user identifier and the page identifier exists in the cache or not according to the user identifier and the page identifier in the queue;
if yes, accumulating the request times in the preset time period, and accumulating the abnormal times in the preset time period;
if the request times do not exist, accumulating the request times in the preset time period;
and counting the preset time period, the request times and the abnormal times.
Optionally, comparing the page exception rate with a preset exception criterion, and determining that the page is in an exception state before the page is in the exception state, includes:
acquiring historical request times and historical abnormal times of querying in a cache by using keys generated by the user identification and the page identification;
and determining the historical abnormal frequency as a preset abnormal reference according to the ratio of the historical abnormal frequency to the historical request frequency.
Optionally, determining whether a key generated by the user identifier and the page identifier exists in the cache according to the user identifier and the page identifier in the queue includes:
receiving a page tail request;
and deleting the key consisting of the user identifier and the page identifier from the cache according to the page tail request.
Optionally, deleting a key formed by the user identifier and the page identifier from the cache according to the request of the page tail includes:
receiving a page uniform resource locator request;
storing the user identification corresponding to the page uniform resource locator request and the information corresponding to the page identification in a queue; generating a user identifier corresponding to the page uniform resource locator request and a key corresponding to the page identifier; storing the key in a cache and setting an expiration time of the key in the cache.
Optionally, comparing the page exception rate with a preset exception criterion, and after determining that the page is in an exception state, the method includes:
generating alarm information according to the page in the abnormal state;
and alarming according to the alarm information.
According to another aspect of the embodiments of the present invention, there is provided an apparatus for detecting a page exception, including:
The counting module is used for counting the request times and abnormal times of the key inquiry in the cache generated by the user identification and the page identification within a preset time interval;
the calculation module is used for calculating the page abnormality rate according to the ratio of the abnormality times to the request times;
and the determining module is used for comparing the page abnormity rate with a preset abnormity reference and determining that the page is in an abnormal state.
Optionally, the counting, within a preset time interval, the determining the number of times of requests and the number of times of exceptions of the query in the cache by the key generated by the user identifier and the page identifier includes:
judging whether a key generated by the user identifier and the page identifier exists in the cache or not according to the user identifier and the page identifier in the queue;
if yes, accumulating the request times in the preset time period, and accumulating the abnormal times in the preset time period;
if the request times do not exist, accumulating the request times in the preset time period;
and counting the preset time period, the request times and the abnormal times.
Optionally, the method further comprises: a benchmark determining module, configured to compare the page exception rate with a preset exception benchmark to determine that the page is in an exception state,
Acquiring historical request times and historical abnormal times of querying in a cache by using keys generated by the user identification and the page identification;
and determining the historical abnormal frequency as a preset abnormal reference according to the ratio of the historical abnormal frequency to the historical request frequency.
According to another aspect of the embodiments of the present invention, there is provided an electronic device for detecting page abnormality, including:
one or more processors;
a storage device for storing one or more programs,
when the one or more programs are executed by the one or more processors, the one or more processors implement the method for detecting page faults provided by the invention.
According to still another aspect of the embodiments of the present invention, there is provided a computer readable medium, on which a computer program is stored, which when executed by a processor implements the method for detecting a page fault provided by the present invention.
One embodiment of the above invention has the following advantages or benefits:
according to the optional embodiment of the application, the technical means of detecting the page abnormity at the server is adopted, the technical defects that in the prior art, the page abnormity can be detected only by excessively depending on the abnormity information of the client and the server cannot be compatible to normally send out the access request are avoided, whether the page is abnormal or not can be detected without depending on the data actively reported by the client is further achieved, and the technical means of detecting through the server can achieve the technical effect of compatibility on the conditions of error clicking and the like of a user.
Further effects of the above-mentioned non-conventional alternatives will be described below in connection with the embodiments.
Drawings
The drawings are included to provide a better understanding of the invention and are not to be construed as unduly limiting the invention. Wherein:
FIG. 1 is a schematic diagram of a main flow of a method for detecting a page fault according to an embodiment of the present invention;
FIG. 2 is a schematic flow chart diagram according to an embodiment of the present invention;
FIG. 3 is a diagram illustrating major blocks of an apparatus for detecting page faults according to an embodiment of the present invention;
FIG. 4 is an exemplary system architecture diagram in which embodiments of the present invention may be employed;
fig. 5 is a schematic block diagram of a computer system suitable for use in implementing a terminal device or server of an embodiment of the invention.
Detailed Description
Exemplary embodiments of the present invention are described below with reference to the accompanying drawings, in which various details of embodiments of the invention are included to assist understanding, and which are to be considered as merely exemplary. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the invention. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
Fig. 1 is a schematic diagram of a main flow of a method for detecting a page exception according to an embodiment of the present invention, as shown in fig. 1, including:
step S101, determining the number of times of requests and the number of abnormal times of key inquiry in a cache, wherein the keys (keys) are generated by user identification (user ID) and page identification (page ID) within a preset time interval;
step S102, calculating the page abnormal rate according to the ratio of the abnormal times to the request times;
step S103, comparing the page abnormal rate with a preset abnormal standard, and determining that the page is in an abnormal state.
The preset time interval is set according to actual needs, for example, one minute. I.e. counting the number of requests and anomalies in one minute.
In the application, a key (key) generated by a page identifier (page ID) is mainly stored, so that whether the key exists in the cache or not is conveniently judged subsequently, namely whether the key is consumed or not or whether the key is expired or not is judged.
Due to the fact that the page detection can allow a certain abnormal rate, the abnormal rate of the page is compared with a preset abnormal standard, and the technical effect that the page is determined to be in an abnormal state is achieved conveniently.
The prior art has the technical defects that the page abnormity can be detected only by excessively depending on the abnormal information of the client, and the server can not be compatible to normally send out an access request. The steps S101-S103 are implemented in the server, so that the technical defects are avoided, the detection on whether the page is abnormal or not can be finished without depending on data actively reported by the client, and the technical effect of compatibility on the conditions of error clicking and the like of the user can be realized by the technical means of detection by the server.
According to the optional embodiment of the application, the detection main body of the page abnormity is placed at the server side, the abnormity information of the client side is not depended on, and the condition that the request is made by the server and is not reached due to the operation of error points and the like of a user can be compatible.
In the application, the key values generated by the user ID and the page ID are stored in the cache, so that the operations of adding, inquiring, deleting and overdue the keys can be realized. Wherein the expiration operation is to prevent the cache space from being filled; the query is used for satisfying the condition of querying the key so as to determine whether the request at the tail part of the page reaches the server side; the add operation is used for adding a key to identify that the page is accessed; the delete operation is used to delete the key corresponding to the page that has been successfully opened.
The request of the page tail refers to the last request sent from the browser, and the request of the page tail can assist in determining whether the request sent by the browser reaches the server or not.
Optionally, the counting, within a preset time interval, the determining the number of times of requests and the number of times of exceptions of the query in the cache by the key generated by the user identifier and the page identifier includes:
judging whether a key generated by the user identifier and the page identifier exists in the cache or not according to the user identifier and the page identifier in the queue;
if yes, accumulating the request times in the preset time period, and accumulating the abnormal times in the preset time period;
if the request times do not exist, accumulating the request times in the preset time period;
and counting the preset time period, the request times and the abnormal times.
The queue is a channel between producer and consumer, in this application producer is a web service of a page and consumer is a computing service.
And acquiring the user identifier and the page identifier through the queue, caching and searching keys generated by the user identifier and the page identifier, and further determining whether the keys in the cache complete consumption. Specifically, after the cache queue receives the page tail request, the key corresponding to the page tail request in the cache is deleted, and when the cache is queried again, the key is not queried, and the abnormal times are not accumulated. Otherwise, if the key is found, it is indicated that the key exists in the cache, and the cache does not normally receive the request of the page tail, that is, it is indicated that the page does not complete loading and rendering, and the page to be detected is abnormal, and the abnormal times are accumulated.
Alternative embodiments of the present application use delayed consumption of queue messages in conjunction with proper cache validity to confirm whether a page tail request has been issued.
In practical application, a page web service may be adopted to provide a normal web service, and specifically, a request for a page type may obtain a current page ID and a current user ID, and send the page ID and the user ID to a queue and a cache. For asynchronous requests, in the present application, the request at the very end of the page is obtained, and then the key composed of the user ID and the page ID in the cache is deleted after the current user ID and the page ID are obtained.
Optionally, comparing the page exception rate with a preset exception criterion, and determining that the page is in an exception state before the page is in the exception state, includes:
acquiring historical request times and historical abnormal times of querying in a cache by using keys generated by the user identification and the page identification;
and determining the historical abnormal frequency as a preset abnormal reference according to the ratio of the historical abnormal frequency to the historical request frequency.
The technical means of quantizing the historical data to form the preset abnormal reference is used for generating the standard for judging whether the page is abnormal or not, so that a theoretical basis is provided for determining whether the page is abnormal or not, and the technical scheme of the application can be also adopted for the page abnormity caused by the fact that static resources cannot be loaded on the page.
The abnormal reference can be sorted, classified and calculated at preset time intervals, and the abnormal reference is updated according to actual conditions.
Optionally, determining whether a key generated by the user identifier and the page identifier exists in the cache according to the user identifier and the page identifier in the queue includes:
receiving a page tail request;
and deleting the key consisting of the user identifier and the page identifier from the cache according to the page tail request.
The page tail request is asynchronous request data, and can be delayed, that is, a key corresponding to the page tail request is deleted from the cache after a certain delay time.
Optionally, deleting a key formed by the user identifier and the page identifier from the cache according to the request of the page tail includes:
receiving a page Uniform Resource Locator (URL) request;
storing the user identification corresponding to the page uniform resource locator request and the information corresponding to the page identification in a queue; generating a user identifier corresponding to the page uniform resource locator request and a key corresponding to the page identifier; storing the key in a cache and setting an expiration time of the key in the cache.
Optionally, comparing the page exception rate with a preset exception criterion, and after determining that the page is in an exception state, the method includes:
generating alarm information according to the page in the abnormal state;
and alarming according to the alarm information.
Specifically, when the page abnormal rate is obviously greater than the preset abnormal reference difference, the alarm service can be called to alarm.
A method for detecting page faults according to the present application is described in detail below with an embodiment.
FIG. 2 is a schematic flow chart diagram according to an embodiment of the present invention; as shown in fig. 2, includes:
step S201, the browser sends a page URL request to a page web service;
step S202, after receiving a page URL request, a page web service stores a user ID and a page ID as keys in a cache, and sets the expiration time of the keys in the cache;
step S203, storing the message containing the user ID and the page ID in a queue;
step S204, the message computing service asynchronously obtains the message about the user ID and the page ID stored in the queue;
step S205, the web page service receives a page tail request of the browser;
step S206, sending the page tail request to a cache, and deleting a user ID and a key generated by the page ID;
Step S207, the consumption computing service inquires whether a key for storing the user ID and the page ID exists in the cache by using the information of the user ID and the page ID;
if yes, executing step S208, accumulating the request times in the preset time period, and accumulating the abnormal times in the preset time period;
if not, executing step S209, and accumulating the request times within the preset time period;
step S210, counting the preset time period, the request times and the abnormal times, and calculating the abnormal rate.
Step S211, comparing the page abnormal rate with a preset abnormal standard, and judging whether the page is in an abnormal state; if yes, executing step S212, generating alarm information according to the page in the abnormal state, and giving an alarm.
FIG. 3 is a diagram illustrating major blocks of an apparatus for detecting page faults according to an embodiment of the present invention; as shown in fig. 3, there is provided an apparatus 300 for detecting a page fault, including:
the counting module 301 is configured to count the number of requests and the number of exceptions of the query in the cache of the key generated by the user identifier and the page identifier within a preset time interval;
A calculating module 302, configured to calculate a page exception rate according to a ratio of the exception times to the request times;
the determining module 303 is configured to compare the page exception rate with a preset exception criterion, and determine that the page is in an exception state.
Fig. 4 illustrates an exemplary system architecture 400 to which the method or apparatus for detecting page faults of embodiments of the present invention may be applied.
As shown in fig. 4, the system architecture 400 may include terminal devices 401, 402, 403, a network 404, and a server 405. The network 404 serves as a medium for providing communication links between the terminal devices 401, 402, 403 and the server 405. Network 404 may include various types of connections, such as wire, wireless communication links, or fiber optic cables, to name a few.
A user may use terminal devices 401, 402, 403 to interact with a server 405 over a network 404 to receive or send messages or the like. The terminal devices 401, 402, 403 may have installed thereon various communication client applications, such as shopping-like applications, web browser applications, search-like applications, instant messaging tools, mailbox clients, social platform software, etc. (by way of example only).
The terminal devices 401, 402, 403 may be various electronic devices having a display screen and supporting web browsing, including but not limited to smart phones, tablet computers, laptop portable computers, desktop computers, and the like.
The server 405 may be a server providing various services, such as a background management server (for example only) providing support for shopping websites browsed by users using the terminal devices 401, 402, 403. The backend management server may analyze and perform other processing on the received data such as the product information query request, and feed back a processing result (for example, target push information, product information — just an example) to the terminal device.
It should be noted that the method for detecting a page fault provided by the embodiment of the present invention is generally executed by the server 405, and accordingly, the device for detecting a page fault is generally disposed in the server 405.
It should be understood that the number of terminal devices, networks, and servers in fig. 4 is merely illustrative. There may be any number of terminal devices, networks, and servers, as desired for implementation.
Referring now to FIG. 5, shown is a block diagram of a computer system 500 suitable for use with a terminal device implementing an embodiment of the present invention. The terminal device shown in fig. 5 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present invention.
As shown in fig. 5, the computer system 500 includes a Central Processing Unit (CPU)501 that can perform various appropriate actions and processes according to a program stored in a Read Only Memory (ROM)502 or a program loaded from a storage section 508 into a Random Access Memory (RAM) 503. In the RAM 503, various programs and data necessary for the operation of the system 500 are also stored. The CPU 501, ROM 502, and RAM 503 are connected to each other via a bus 504. An input/output (I/O) interface 505 is also connected to bus 504.
The following components are connected to the I/O interface 505: an input portion 506 including a keyboard, a mouse, and the like; an output portion 507 including a display such as a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), and the like, and a speaker; a storage portion 508 including a hard disk and the like; and a communication section 509 including a network interface card such as a LAN card, a modem, or the like. The communication section 509 performs communication processing via a network such as the internet. The driver 510 is also connected to the I/O interface 505 as necessary. A removable medium 511 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on the drive 510 as necessary, so that a computer program read out therefrom is mounted into the storage section 508 as necessary.
In particular, according to the embodiments of the present disclosure, the processes described above with reference to the flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code for performing the method illustrated in the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network through the communication section 509, and/or installed from the removable medium 511. The computer program performs the above-described functions defined in the system of the present invention when executed by the Central Processing Unit (CPU) 501.
It should be noted that the computer readable medium shown in the present invention can be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present invention, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In the present invention, however, a computer readable signal medium may include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, fiber optic cable, RF, etc., or any suitable combination of the foregoing.
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams or flowchart illustration, and combinations of blocks in the block diagrams or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The modules described in the embodiments of the present invention may be implemented by software or hardware. The described modules may also be provided in a processor, which may be described as: a processor includes a sending module, an obtaining module, a determining module, and a first processing module. The names of these modules do not form a limitation on the modules themselves in some cases, and for example, the sending module may also be described as a "module sending a picture acquisition request to a connected server".
As another aspect, the present invention also provides a computer-readable medium that may be contained in the apparatus described in the above embodiments; or may be separate and not incorporated into the device. The computer readable medium carries one or more programs which, when executed by a device, cause the device to comprise:
counting the number of times of requests and abnormal times of key inquiry in a cache, wherein the request times and the abnormal times are generated by a user identifier and a page identifier within a preset time interval;
calculating the page abnormality rate according to the ratio of the abnormality times to the request times;
and comparing the page abnormal rate with a preset abnormal standard to determine that the page is in an abnormal state.
According to the technical scheme of the embodiment of the invention, the following beneficial effects can be achieved:
according to the optional embodiment of the application, the technical means of detecting the page abnormity at the server is adopted, the technical defects that in the prior art, the page abnormity can be detected only by excessively depending on the abnormity information of the client and the server cannot be compatible to normally send out the access request are avoided, whether the page is abnormal or not can be detected without depending on the data actively reported by the client is further achieved, and the technical means of detecting through the server can achieve the technical effect of compatibility on the conditions of error clicking and the like of a user.
The above-described embodiments should not be construed as limiting the scope of the invention. Those skilled in the art will appreciate that various modifications, combinations, sub-combinations, and substitutions can occur, depending on design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

Claims (11)

1. A method for detecting page exceptions, comprising:
counting the number of times of requests and abnormal times of key inquiry in a cache, wherein the request times and the abnormal times are generated by a user identifier and a page identifier within a preset time interval;
calculating the page abnormality rate according to the ratio of the abnormality times to the request times;
and comparing the page abnormal rate with a preset abnormal standard to determine that the page is in an abnormal state.
2. The method of claim 1, wherein the counting the number of requests and the number of exceptions of the key query in the cache generated by the user identifier and the page identifier within the preset time interval comprises:
judging whether a key generated by the user identifier and the page identifier exists in the cache or not according to the user identifier and the page identifier in the queue;
If yes, accumulating the request times in the preset time period, and accumulating the abnormal times in the preset time period;
if the request times do not exist, accumulating the request times in the preset time period;
and counting the preset time period, the request times and the abnormal times.
3. The method of claim 2, wherein comparing the page exception rate with a preset exception criterion to determine that the page is in an exception state comprises:
acquiring historical request times and historical abnormal times of querying in a cache by using keys generated by the user identification and the page identification;
and determining the historical abnormal frequency as a preset abnormal reference according to the ratio of the historical abnormal frequency to the historical request frequency.
4. The method according to claim 2 or 3, wherein determining whether a key generated by the user identifier and the page identifier exists in the cache before the key according to the user identifier and the page identifier in the queue comprises:
receiving a page tail request;
and deleting the key consisting of the user identifier and the page identifier from the cache according to the page tail request.
5. The method of claim 4, wherein deleting the key comprising the user identifier and the page identifier from the cache according to the page tail request comprises:
Receiving a page uniform resource locator request;
storing the user identification corresponding to the page uniform resource locator request and the information corresponding to the page identification in a queue; generating a user identifier corresponding to the page uniform resource locator request and a key corresponding to the page identifier; storing the key in a cache and setting an expiration time of the key in the cache.
6. The method of claim 1, wherein comparing the page exception rate with a preset exception criterion and determining that the page is in an exception state comprises:
generating alarm information according to the page in the abnormal state;
and alarming according to the alarm information.
7. An apparatus for detecting page faults, comprising:
the counting module is used for counting the request times and abnormal times of the key inquiry in the cache generated by the user identification and the page identification within a preset time interval;
the calculation module is used for calculating the page abnormality rate according to the ratio of the abnormality times to the request times;
and the determining module is used for comparing the page abnormity rate with a preset abnormity reference and determining that the page is in an abnormal state.
8. The apparatus of claim 7, wherein the counting the number of requests and the number of exceptions of the key query in the cache generated by the user identifier and the page identifier within the preset time interval comprises:
judging whether a key generated by the user identifier and the page identifier exists in the cache or not according to the user identifier and the page identifier in the queue;
if yes, accumulating the request times in the preset time period, and accumulating the abnormal times in the preset time period;
if the request times do not exist, accumulating the request times in the preset time period;
and counting the preset time period, the request times and the abnormal times.
9. The apparatus of claim 8, further comprising: a benchmark determining module, configured to compare the page exception rate with a preset exception benchmark to determine that the page is in an exception state,
acquiring historical request times and historical abnormal times of querying in a cache by using keys generated by the user identification and the page identification;
and determining the historical abnormal frequency as a preset abnormal reference according to the ratio of the historical abnormal frequency to the historical request frequency.
10. An electronic device for detecting page anomalies, comprising:
one or more processors;
a storage device for storing one or more programs,
when executed by the one or more processors, cause the one or more processors to implement the method of any one of claims 1-6.
11. A computer-readable medium, on which a computer program is stored, which, when being executed by a processor, carries out the method according to any one of claims 1-6.
CN202010479108.9A 2020-05-29 2020-05-29 Method and device for detecting page abnormity Pending CN113722193A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010479108.9A CN113722193A (en) 2020-05-29 2020-05-29 Method and device for detecting page abnormity

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010479108.9A CN113722193A (en) 2020-05-29 2020-05-29 Method and device for detecting page abnormity

Publications (1)

Publication Number Publication Date
CN113722193A true CN113722193A (en) 2021-11-30

Family

ID=78672249

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010479108.9A Pending CN113722193A (en) 2020-05-29 2020-05-29 Method and device for detecting page abnormity

Country Status (1)

Country Link
CN (1) CN113722193A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116756453A (en) * 2023-08-16 2023-09-15 浙江飞猪网络技术有限公司 Method, equipment and medium for user anomaly analysis and model training based on page

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116756453A (en) * 2023-08-16 2023-09-15 浙江飞猪网络技术有限公司 Method, equipment and medium for user anomaly analysis and model training based on page

Similar Documents

Publication Publication Date Title
CN113761565B (en) Data desensitization method and device
CN112118352B (en) Method and device for processing notification trigger message, electronic equipment and computer readable medium
CN113760982A (en) Data processing method and device
CN113722193A (en) Method and device for detecting page abnormity
CN113535420A (en) Message processing method and device
CN112948138A (en) Method and device for processing message
CN112685481A (en) Data processing method and device
CN110866001A (en) Method and device for determining order to be processed
CN112688982B (en) User request processing method and device
CN112825519B (en) Method and device for identifying abnormal login
CN109087097B (en) Method and device for updating same identifier of chain code
CN110019671B (en) Method and system for processing real-time message
CN112699116A (en) Data processing method and system
CN112862554A (en) Order data processing method and device
CN113761433A (en) Service processing method and device
CN112749204A (en) Method and device for reading data
CN113114611A (en) Method and device for managing blacklist
CN112783716B (en) Monitoring method and device
CN112448931B (en) Network hijacking monitoring method and device
CN113778909B (en) Method and device for caching data
CN110262756B (en) Method and device for caching data
CN114065001B (en) Data processing method, device, equipment and storage medium
CN113157828B (en) Method and device for pushing data
CN110120958B (en) Task pushing method and device based on crowdsourcing mode
CN113760572A (en) Message processing method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination