[go: up one dir, main page]

CN111046310B - Page processing method, device, server and computer readable storage medium - Google Patents

Page processing method, device, server and computer readable storage medium Download PDF

Info

Publication number
CN111046310B
CN111046310B CN201911278067.0A CN201911278067A CN111046310B CN 111046310 B CN111046310 B CN 111046310B CN 201911278067 A CN201911278067 A CN 201911278067A CN 111046310 B CN111046310 B CN 111046310B
Authority
CN
China
Prior art keywords
page
target page
service
routing rule
target
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.)
Active
Application number
CN201911278067.0A
Other languages
Chinese (zh)
Other versions
CN111046310A (en
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 QIYI Century Science and Technology Co Ltd
Original Assignee
Beijing QIYI Century Science and 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 QIYI Century Science and Technology Co Ltd filed Critical Beijing QIYI Century Science and Technology Co Ltd
Priority to CN201911278067.0A priority Critical patent/CN111046310B/en
Publication of CN111046310A publication Critical patent/CN111046310A/en
Application granted granted Critical
Publication of CN111046310B publication Critical patent/CN111046310B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/957Browsing optimisation, e.g. caching or content distillation
    • G06F16/9574Browsing optimisation, e.g. caching or content distillation of access to content, e.g. by caching

Landscapes

  • Engineering & Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The embodiment of the invention provides a page processing method, a page processing device, a server and a computer readable storage medium. The page processing method comprises the following steps: if an access request to a target page sent by a terminal is received, detecting whether the service of the target page is abnormal or not; if the service of the target page is abnormal, acquiring a page snapshot of the target page; and sending the page snapshot of the target page to the terminal. The embodiment of the invention can improve the reliability of page use.

Description

Page processing method, device, server and computer readable storage medium
Technical Field
The present invention relates to the field of internet technologies, and in particular, to a page processing method, a device, a server, and a computer readable storage medium.
Background
With the development of the internet, various types of websites are increasing. When the website runs, the situation that the page cannot be loaded normally possibly occurs. For the above case, the current processing method is: and automatically jumping to 404 and other relevant pages, or outputting prompt information such as 'page loading failure', and the like, wherein the user still cannot acquire page contents. It can be seen that the reliability of existing page usage is low.
Disclosure of Invention
An embodiment of the invention aims to provide a page processing method, a device, a server and a computer readable storage medium, so as to solve the problem of low reliability of the use of the existing page. The specific technical scheme is as follows:
in a first aspect of the present invention, there is provided a page processing method, including:
if an access request to a target page sent by a terminal is received, detecting whether the service of the target page is abnormal or not;
if the service of the target page is abnormal, acquiring a page snapshot of the target page;
and sending the page snapshot of the target page to the terminal.
In a second aspect of the present invention, there is also provided a page processing apparatus, including:
the detection module is used for detecting whether the service of the target page is abnormal or not if an access request to the target page sent by the terminal is received;
the acquisition module is used for acquiring a page snapshot of the target page if the service of the target page is abnormal;
and the sending module is used for sending the page snapshot of the target page to the terminal.
In a third aspect of the present invention, there is also provided a server, including a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory complete communication with each other through the communication bus;
a memory for storing a computer program;
and the processor is used for realizing the steps in the page processing method of the embodiment of the invention when executing the program stored in the memory.
In yet another aspect of the present invention, there is also provided a computer readable storage medium having instructions stored therein which, when executed on a computer, cause the computer to perform any of the above-described page processing methods.
In yet another aspect of the invention, there is also provided a computer program product containing instructions which, when run on a computer, cause the computer to perform any of the above described page processing methods.
According to the page processing method, the device, the server and the computer readable storage medium, under the condition that the service of the target page which is requested to be accessed is abnormal, the server can acquire the page snapshot of the target page and send the page snapshot of the target page to the terminal, so that the terminal can acquire the page content of the target page by receiving the page snapshot of the target page, and the reliability of page use can be improved.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below.
FIG. 1 is a schematic flow chart of a page processing method according to an embodiment of the invention;
FIG. 2 is a diagram of a page processing system architecture in an embodiment of the invention;
FIG. 3 is a second flow chart of a page processing method according to an embodiment of the invention;
FIG. 4 is a schematic diagram of a page processing apparatus according to an embodiment of the present invention;
fig. 5 is a schematic structural diagram of a server according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be described below with reference to the accompanying drawings in the embodiments of the present invention.
The page processing method of the embodiment of the invention can be applied to a server. In practical applications, the server may communicate with the terminal (i.e. the user equipment). Specifically, the server may receive an access request for a target page sent by the terminal. Further, the server may send the page content of the target page to the terminal in response to the access request.
The page processing method according to the embodiment of the present invention is described below.
As shown in fig. 1, the page processing method may include the steps of:
step 101, if an access request to a target page sent by a terminal is received, detecting whether the service of the target page is abnormal.
Step 102, if the service of the target page is abnormal, acquiring a page snapshot of the target page.
And step 103, sending the page snapshot of the target page to the terminal.
In particular implementations, the target page may be a text page, a video page, etc., and further, the video page may be a live page, but is not limited thereto. It should be understood that embodiments of the present invention are not limited to the specific representation of the target page.
A page snapshot of a target page may be understood as a backup of the target page, including the page content of the target page.
The access request is for requesting access to the target page. If the service of the target page is normal, the server can directly send the latest page content of the target page to the terminal for the user to watch. If the service of the target page is abnormal, the server can acquire the page snapshot of the target page and send the page snapshot of the target page to the terminal for the user to watch. It can be seen that, in the embodiment of the present invention, even if the service of the target page is abnormal, the terminal may obtain the page content of the target page through the page snapshot of the target page, so as to improve the reliability of page usage.
For convenience of understanding, the page processing method according to the embodiment of the invention is described with a live page.
Under the condition of abnormal service of the live broadcast page, the terminal can acquire the page snapshot of the live broadcast page, and the page snapshot of the live broadcast page comprises the live broadcast stream address, so that the terminal can acquire the live broadcast stream again through the live broadcast stream address in the page snapshot. Therefore, compared with the prior art that the terminal cannot acquire the live stream before the service of the live page is not recovered, the page processing method provided by the embodiment of the invention can improve the use reliability of the live page.
In embodiments of the present invention, the page snapshot may be stored in a cache of the server or in a remote dictionary service (Remote Dictionary Server, rdis) storage system.
In the scenario that the page snapshot is stored in the cache of the server, the obtaining the page snapshot of the target page may specifically be represented as: and acquiring a page snapshot of the target page from the cache.
In the scenario that the page snapshot is stored in the Rdis storage system through a local storage manner, the obtaining the page snapshot of the target page may specifically include: sending request information to an Rdis storage system, wherein the request information is used for requesting a page snapshot of the target page; and receiving the page snapshot of the target page sent by the Rdis storage system.
Optionally, before the access request to the target page sent by the terminal is received, the method further includes:
under the condition that the target page is successfully rendered, determining whether a routing rule of the target page is matched with a preset routing rule;
and if the routing rule of the target page is matched with the preset routing rule, storing the page snapshot of the target page into a cache.
In this alternative embodiment, the routing rule may be understood as: and (5) a packaging rule for packaging the P uniform resource locators (Uniform Resource Locator, URL), wherein P is a positive integer. Where the URL represents an internet address of a particular network resource, such as an internet address of a page. Illustratively, the routing rules for a live theatre may be expressed specifically as: a routing rule conforming to/w/: id (\\d+) for the domain name live.com, the routing rule covering URLs of all small theatre room pages, such as https:// live.com/w/76337; https:// live.com/w/76340; https:// live.com/w/37542, etc.
Based on the foregoing, it is readily understood that the routing rules have a correspondence with pages, and the routing rules may be used to identify P pages. Further, the expression form of the correspondence is related to the attribute of the routing rule, and is specifically described as follows:
in the scenario where the routing rule is a routing rule of a page, the routing rule is in a one-to-one correspondence with the page, i.e., one routing rule is used to identify one page.
In the scenario that the routing rule is that of a website, the website is formed by gathering webpages, so that in the case that the website only comprises one page, the routing rule and the page are in one-to-one correspondence, and one routing rule is used for identifying one page; in the case where the web site includes a plurality of pages, the routing rule is a one-to-many correspondence with the pages, and one routing rule is used to identify the plurality of pages.
In practical application, the routing address of the page or website that needs to ensure stable running may be set as a preset routing rule in advance, so that, optionally, the preset routing rule may include at least one of the following: routing rules of the pages; routing rules for websites. Accordingly, whether the routing rule of the target page matches the preset routing rule may include at least one of:
judging whether the preset routing rule comprises the routing rule of the target page or not;
judging whether the preset routing rule comprises a target routing rule or not, wherein a website corresponding to the target routing rule comprises the routing rule.
In practice, the following may be included.
In the first case, the preset routing rule only includes the routing rule of the page.
For the first case, whether the routing rule of the target page matches the preset routing rule may include:
and judging whether the preset routing rule comprises the routing rule of the target page.
Specifically, if the preset routing rule includes the routing rule of the target page, it may be determined that the routing rule of the target page matches the preset routing rule; otherwise, judging that the routing rule of the target page is not matched with the preset routing rule.
In the second case, the preset routing rule only includes a routing rule of the website.
For the second case, whether the routing rule of the target page matches the preset routing rule may include:
and judging whether the preset routing rule comprises a target routing rule or not.
Specifically, if the preset routing rule includes a target routing rule, it may be determined that the routing rule of the target page matches the preset routing rule; otherwise, judging that the routing rule of the target page is not matched with the preset routing rule.
And in the third case, the preset routing rule comprises a routing rule of a page and a routing rule of a website.
For the third case, whether the routing rule of the target page matches the preset routing rule may include:
judging whether the preset routing rule comprises the routing rule of the target page or not;
and judging whether the preset routing rule comprises a target routing rule or not.
In this case, the embodiment of the present invention does not limit the order of execution of the two determinations. In a first implementation, the first determination may be performed first, followed by the second determination; in a second implementation, the second determination may be performed first and then the first determination may be performed, as described in detail below.
For the first implementation manner, if the preset routing rule includes the routing rule of the target page, it may be determined that the routing rule of the target page matches the preset routing rule; if not, continuing to judge whether the preset routing rule comprises a target routing rule, and if so, judging that the routing rule of the target page is matched with the preset routing rule; otherwise, judging that the routing rule of the target page is not matched with the preset routing rule.
For the second implementation manner, if the preset routing rule includes a target routing rule, it may be determined that the routing rule of the target page matches the preset routing rule; if the preset routing rule includes the routing rule of the target page, the routing rule of the target page can be judged to be matched with the preset routing rule; otherwise, judging that the routing rule of the target page is not matched with the preset routing rule.
In this optional embodiment, it may be seen that, when the target page is rendered successfully and the routing rule of the target page matches the preset routing rule, the server stores the page snapshot of the target page in the cache in advance. In this way, when the server receives the access request to the target page and the service of the target service is abnormal, the server can send the page snapshot of the target page to the terminal, so that the terminal can acquire the page content of the target page by receiving the page snapshot of the target page, thereby improving the reliability of page use.
In addition, in this optional embodiment, in a case where the routing rule of the target page does not match the preset routing rule, the server may not store a page snapshot of the target page. Therefore, the server can only cache the page with the routing rule matched with the preset routing rule, so that the cache burden of the server can be reduced.
Further, after the server stores N page snapshots in the cache, the method may further include:
and updating N page snapshots stored in the cache according to the least recently used LRU algorithm, wherein N is a positive integer.
In particular, the page snapshot is written to the cache periodically using a least recently used (Least Recently Used, LRU) algorithm. The LRU algorithm is a commonly used page replacement algorithm that selects the most recently unused page to be eliminated. The algorithm can give each page an access field for recording the time t of the page since the last time the page was accessed, and when one page snapshot needs to be eliminated, the target page snapshot in the existing page snapshot is selected for elimination, and the t value of the page corresponding to the target page snapshot is the largest, namely the snapshot of the least recently used page is eliminated. For ease of understanding, examples are illustrated below:
assuming that N is 3, and the page snapshot of the page 1, the page snapshot of the page 2 and the page snapshot of the page 3 are cached in the cache of the server, and the sequence of accessing the 3 pages by the terminal is as follows: page 2, page 1, and page 3. On this basis, if the terminal accesses the page 4 and the rendering of the page 4 is successful, and the routing rule of the page 4 is matched with the preset routing rule, the server may delete the page snapshot of the page 2 from the cache and store the page snapshot of the page 4 into the cache.
Therefore, the page snapshots of the N most active pages can be always stored in the cache, and the smoothness of the use of the user pages is improved.
It should be noted that, for the scenario that the page snapshot is stored in the Redis storage system, the manner of storing the page snapshot may be the same as the manner of caching the page snapshot of the server, so that repetition is avoided, and no description is repeated here.
In an embodiment of the present invention, optionally, the detecting whether the service of the target page is abnormal includes at least one of:
detecting whether the service of the service layer corresponding to the target page is abnormal, wherein the abnormal service of the target page is determined under the condition that the service of the service layer is abnormal;
and detecting whether the service of the interface layer corresponding to the target page is abnormal, wherein the abnormal service of the target page is determined under the condition that the service of the interface layer is abnormal.
In the embodiment of the present invention, the service layer corresponding to the target page may be understood as: and the service layer is used for processing the target service. The interface layer corresponding to the target page can be understood as: and the interface layer is used for processing the target service.
In a specific implementation, if the processing of the target page is only related to the service layer, such as a static page, the server may only detect whether the service of the service layer is normal. In this case, if the service of the service layer is normal, it may be determined that the service of the target page is normal; otherwise, judging that the service of the target service is abnormal. In this case, after receiving an access request to a target page sent by a terminal, the server may transmit the response request to a page layer corresponding to the target page, and if the service layer corresponding to the target page cannot provide a complete target page, the server may look at that the service layer corresponding to the target page is abnormal.
If the processing of the target page is only related to the interface layer, such as a page only including an access interface, the server may only detect whether the service of the interface layer is normal. In this case, if the service of the interface layer is normal, it may be determined that the service of the target page is normal; otherwise, judging that the service of the target service is abnormal. In this case, after receiving an access request sent by a terminal to a target page, the server may transmit the access request to an interface layer of the target page, and if the interface layer of the target page returns a response message indicating that the request of the target page fails, the server may look at that the service of the interface layer corresponding to the target page is abnormal.
If the processing of the target page is related to the service layer and the interface layer, such as a live page, the server can detect whether the services of the service layer and the interface layer are normal. In this case, if the service of the service layer and the interface layer is normal, it may be determined that the service of the target page is normal; otherwise, judging that the service of the target service is abnormal. In this case, assuming that the first content of the target service is related to the service layer of the target service, the second content of the target service is related to the interface layer of the target service, after receiving an access request to a target page sent by a terminal, the server may transmit the access request to the interface layer of the target page of the service layer of the target page, and if the service layer of the target service cannot provide the first content of the target service, the service of the service layer corresponding to the target page may be abnormal; if the interface layer of the target service returns a response message indicating that the second content request requesting the target page fails, the service of the interface layer corresponding to the target page can be considered as abnormal.
In an embodiment of the present invention, after the detecting whether the service of the target page is abnormal, the method further includes:
if the service of the target page is abnormal, generating an abnormal log according to the abnormality;
and outputting the exception log.
After generating the exception log, the server may send the exception log to a preset mailbox or a preset number, but is not limited thereto. Therefore, a developer can read the exception log, know the service exception of the target page, and repair the exception, so that the reliability of page use is improved.
In a specific implementation, the exception log may include a routing rule of the target page, and further may further include an exception reason of the target page, for example, whether the service layer corresponding to the target page is abnormal or the interface layer corresponding to the target page is abnormal, so that a developer can conveniently and quickly know the exception reason, and page repair efficiency is improved.
It should be noted that, the various optional implementations described in the embodiments of the present invention may be implemented in combination with each other without collision, or may be implemented separately, which is not limited to the embodiments of the present invention.
For ease of understanding, the following is illustrated in connection with fig. 2 and 3:
as shown in fig. 2, the server 21 may include a service middle layer 211, a core interface layer 212, and a buffer 213. Further, the business middle layer 211 may include a business processing module 2111 and a judging module 2112.
As shown in fig. 3, for the page processing system architecture shown in fig. 2, the page processing method may include the following steps:
step 301, the terminal sends an access request to a target page to the service processing module.
Step 302, the service processing module sends a first response message to the judging module.
Specifically, the first response message may be used to indicate whether an exception occurs in the service processing.
Step 303, the service processing module sends a call request to the core interface layer.
In particular, the call request may be used to request a call to an application program interface (Application Programming Interface, API).
Step 304, the core interface layer sends a second response message to the judging module.
In particular, the second response message may be used to indicate whether the API was successfully called.
It should be noted that, in some embodiments, the service processing method may not include step 302; in some embodiments, the business processing method may not include step 303 and step 304.
Step 305, a judging module judges whether the service of the target page is normal according to at least one of the first response message and the second response message.
Specifically, if the first response message indicates that the service processing is abnormal or the second response message indicates that calling an API fails, the service of the target page is determined to be abnormal.
And 306, the judging module sends a judging result to the cache area.
And the buffer area executes the operation corresponding to the judging result according to the judging result.
If the result is that the service of the target page is abnormal, step 307 is executed.
If the judging result is that the service of the target page is normal, the executing the operation corresponding to the judging result may be specifically expressed as follows: and storing the page snapshot of the target page.
Step 307, the buffer area sends the stored page snapshot of the target page to the terminal.
In practical application, the method can further comprise the following steps:
setting a routing rule of a page to be ensured;
initializing storage system configuration according to specific service scenes, wherein the configuration can be simply a local memory or uniformly managed by Redis;
when the page rendering is successful, the same page snapshot needs to be written into the stored interval time;
setting the buffer expiration time of the page snapshot content in the storage system, and deleting the page snapshot from the storage system after the storage time of a certain page snapshot reaches the buffer expiration time;
the page snapshot is written into the storage system regularly by using an LRU algorithm; the number of pages to be cached, namely the cache queue length, needs to be set at the same time;
the code layer needs to have a relatively sound log system, so that when a server (i.e. a server) is abnormal, an abnormality alarm can be triggered to enable an developer to timely process on-line abnormality while an indiscriminate user experience is provided for a user page snapshot.
The embodiment of the invention provides a cache fault-tolerant strategy of page snapshots, and the cache fault-tolerant strategy script stores the snapshots of pages which accord with a preset routing rule and are successfully rendered into a cache queue at fixed time intervals. In this way, under the condition that the service of the target page is abnormal, the server can send the page snapshot of the target page to the terminal, so that the terminal can acquire the page content of the target page through the page snapshot, and the reliability of the page use can be improved. Further, for performance consideration of the cache space, an appropriate cache queue length may be set according to the specific situation, and only the snapshot of the most active page is cached according to the LRU algorithm. In addition, when the service of the page is abnormal, the snapshot of the page is taken from the cache queue and returned to the client (i.e. the terminal) while the false alarm is triggered, so that the abnormality occurring at the server (i.e. the server) is not perceived by the user, and meanwhile, the time for repairing the abnormality is strived for the developer.
Taking live broadcast service as an example, due to the specificity of live broadcast; the stable running of the website is ensured, and the user keeps good live broadcast watching experience, which is always a direction needing to be thinking and focused. Therefore, the embodiment of the invention stores the most active pages of the live broadcasting room by utilizing the LRU algorithm; the live broadcasting stability is guaranteed, so that even if the rear-end terminal is abnormal in oral administration, a user can acquire a snapshot of a live broadcasting room, and indiscriminate user experience is acquired.
Embodiments of the present invention may include the following beneficial effects:
the page storage snapshot is provided to replace 404 pages returned when the traditional back-end service is abnormal, so that the running stability of the pages is improved, the reliability of the page use can be improved, and better user experience is provided. In addition, the most active page content can be guaranteed by using the LRU replacement algorithm; by combining a sound log system, the method can provide indiscriminate page content when the back-end service is abnormal, and meanwhile, precious time is striven for developers to repair online abnormality.
The page processing apparatus according to the embodiment of the present invention is described below.
As shown in fig. 4, the page processing apparatus 400 may include:
the detection module 401 is configured to detect whether a service of a target page is abnormal if an access request to the target page sent by a terminal is received;
an obtaining module 402, configured to obtain a page snapshot of the target page if the service of the target page is abnormal;
and the sending module 403 is configured to send a page snapshot of the target page to the terminal.
Optionally, the page processing apparatus 400 further includes:
the determining module is used for determining whether the routing rule of the target page is matched with a preset routing rule under the condition that the target page is successfully rendered before the access request of the target page sent by the terminal is received;
and the storage module is used for storing the page snapshot of the target page into a cache if the routing rule of the target page is matched with the preset routing rule.
Optionally, the page processing apparatus 400 further includes:
and the updating module is used for updating N page snapshots stored in the cache according to the least recently used LRU algorithm, wherein N is a positive integer.
Optionally, the detection module 401 is specifically configured to at least one of the following:
detecting whether the service of the service layer corresponding to the target page is abnormal, wherein the abnormal service of the target page is determined under the condition that the service of the service layer is abnormal;
and detecting whether the service of the interface layer corresponding to the target page is abnormal, wherein the abnormal service of the target page is determined under the condition that the service of the interface layer is abnormal.
According to the page processing device provided by the embodiment of the invention, under the condition that the service of the target page which is requested to be accessed is abnormal, the server can acquire the page snapshot of the target page and send the page snapshot of the target page to the terminal, so that the terminal can acquire the page content of the target page by receiving the page snapshot of the target page, and the reliability of page use can be improved.
The embodiment of the invention also provides a server, as shown in fig. 5, which comprises a processor 501, a communication interface 502, a memory 503 and a communication bus 504, wherein the processor 501, the communication interface 502 and the memory 503 complete communication with each other through the communication bus 504.
A memory 503 for storing a computer program;
the processor 501 is configured to execute the program stored in the memory 503, and implement the following steps:
if an access request to a target page sent by a terminal is received through a communication interface 502, detecting whether the service of the target page is abnormal;
if the service of the target page is abnormal, acquiring a page snapshot of the target page;
and sending the page snapshot of the target page to the terminal through the communication interface 502.
Optionally, the processor 501, when configured to execute the program stored on the memory 503, may further implement the following steps:
under the condition that the target page is successfully rendered, determining whether a routing rule of the target page is matched with a preset routing rule;
and if the routing rule of the target page is matched with the preset routing rule, storing the page snapshot of the target page into a cache.
Optionally, the processor 501, when configured to execute the program stored on the memory 503, may further implement the following steps:
and updating N page snapshots stored in the cache according to the least recently used LRU algorithm, wherein N is a positive integer.
Optionally, the processor 501, when configured to execute the program stored on the memory 503, may further implement at least one of the following steps:
detecting whether the service of the service layer corresponding to the target page is abnormal, wherein the abnormal service of the target page is determined under the condition that the service of the service layer is abnormal;
and detecting whether the service of the interface layer corresponding to the target page is abnormal, wherein the abnormal service of the target page is determined under the condition that the service of the interface layer is abnormal.
The communication bus mentioned by the server may be a peripheral component interconnect standard (Peripheral Component Interconnect, abbreviated as PCI) bus or an extended industry standard architecture (Extended Industry Standard Architecture, abbreviated as EISA) bus, etc. The communication bus may be classified as an address bus, a data bus, a control bus, or the like. For ease of illustration, the figures are shown with only one bold line, but not with only one bus or one type of bus.
The communication interface is used for communication between the server and other devices.
The memory may include random access memory (Random Access Memory, RAM) or non-volatile memory (non-volatile memory), such as at least one disk memory. Optionally, the memory may also be at least one memory device located remotely from the aforementioned processor.
The processor may be a general-purpose processor, including a central processing unit (Central Processing Unit, CPU for short), a network processor (Network Processor, NP for short), etc.; but also digital signal processors (Digital Signal Processing, DSP for short), application specific integrated circuits (Application Specific Integrated Circuit, ASIC for short), field-programmable gate arrays (Field-Programmable Gate Array, FPGA for short) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.
In yet another embodiment of the present invention, a computer readable storage medium is provided, in which instructions are stored, which when run on a computer, cause the computer to perform the page processing method according to any one of the above embodiments.
In yet another embodiment of the present invention, there is also provided a computer program product containing instructions that, when run on a computer, cause the computer to perform the page processing method of any of the above embodiments.
In the above embodiments, it may be implemented in whole or in part by software, hardware, firmware, or any combination thereof. When implemented in software, may be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When loaded and executed on a computer, produces a flow or function in accordance with embodiments of the present invention, in whole or in part. The computer may be a general purpose computer, a special purpose computer, a computer network, or other programmable apparatus. The computer instructions may be stored in or transmitted from one computer-readable storage medium to another, for example, by wired (e.g., coaxial cable, optical fiber, digital Subscriber Line (DSL)), or wireless (e.g., infrared, wireless, microwave, etc.). The computer readable storage medium may be any available medium that can be accessed by a computer or a data storage device such as a server, data center, etc. that contains an integration of one or more available media. The usable medium may be a magnetic medium (e.g., floppy Disk, hard Disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium (e.g., solid State Disk (SSD)), etc.
It is noted that relational terms such as first and second, and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Moreover, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
In this specification, each embodiment is described in a related manner, and identical and similar parts of each embodiment are all referred to each other, and each embodiment mainly describes differences from other embodiments. In particular, for system embodiments, since they are substantially similar to method embodiments, the description is relatively simple, as relevant to see a section of the description of method embodiments.
The foregoing description is only of the preferred embodiments of the present invention and is not intended to limit the scope of the present invention. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention are included in the protection scope of the present invention.

Claims (6)

1. A method of page processing, the method comprising:
if an access request to a target page sent by a terminal is received, detecting whether the service of the target page is abnormal or not;
if the service of the target page is abnormal, acquiring a page snapshot of the target page;
sending a page snapshot of the target page to the terminal;
before the access request to the target page sent by the terminal is received, the method further comprises the following steps:
under the condition that the target page is successfully rendered, determining whether a routing rule of the target page is matched with a preset routing rule, wherein the preset routing rule is a routing rule of a page or a website which needs to guarantee stable operation;
if the routing rule of the target page is matched with the preset routing rule, storing the page snapshot of the target page into a cache, and if the routing rule of the target page is not matched with the preset routing rule, not storing the page snapshot of the target page;
the detecting whether the service of the target page is abnormal comprises at least one of the following steps:
detecting whether the service of the service layer corresponding to the target page is abnormal or not under the condition that the service layer corresponding to the target page is related to the first content of the target page, wherein the service abnormality of the target page is determined under the condition that the service layer cannot provide the first content of the target page;
and detecting whether the service of the interface layer corresponding to the target page is abnormal or not under the condition that the interface layer corresponding to the target page is related to the second content of the target page, wherein the service of the target page is determined to be abnormal under the condition that the interface layer of the target page returns a response message indicating that the request of the second content of the target page is failed.
2. The method according to claim 1, wherein the method further comprises:
and updating N page snapshots stored in the cache according to the least recently used LRU algorithm, wherein N is a positive integer.
3. A page processing apparatus, characterized in that the page processing apparatus comprises:
the detection module is used for detecting whether the service of the target page is abnormal or not if an access request to the target page sent by the terminal is received;
the acquisition module is used for acquiring a page snapshot of the target page if the service of the target page is abnormal;
the sending module is used for sending the page snapshot of the target page to the terminal;
the determining module is used for determining whether the routing rule of the target page is matched with a preset routing rule before the access request to the target page sent by the terminal is received, and the preset routing rule is a routing rule of a page or a website which needs to guarantee stable operation under the condition that the target page is successfully rendered;
the storage module is used for storing the page snapshot of the target page into a cache if the routing rule of the target page is matched with the preset routing rule, and not storing the page snapshot of the target page under the condition that the routing rule of the target page is not matched with the preset routing rule;
the detection module is specifically used for at least one of the following:
detecting whether the service of the service layer corresponding to the target page is abnormal or not under the condition that the service layer corresponding to the target page is related to the first content of the target page, and determining that the service of the target page is abnormal under the condition that the service layer cannot provide the first content of the target page;
and detecting whether the service of the interface layer corresponding to the target page is abnormal or not under the condition that the interface layer corresponding to the target page is related to the second content of the target page, and determining that the service of the target page is abnormal under the condition that the interface layer of the target page returns a response message indicating that the request of the second content of the target page is failed.
4. A page processing apparatus as recited in claim 3, further comprising:
and the updating module is used for updating N page snapshots stored in the cache according to the least recently used LRU algorithm, wherein N is a positive integer.
5. The server is characterized by comprising a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory are communicated with each other through the communication bus;
a memory for storing a computer program;
a processor for implementing the method steps of any of claims 1-2 when executing a program stored on a memory.
6. A computer readable storage medium, on which a computer program is stored, characterized in that the program, when being executed by a processor, implements the method according to any of claims 1-2.
CN201911278067.0A 2019-12-12 2019-12-12 Page processing method, device, server and computer readable storage medium Active CN111046310B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911278067.0A CN111046310B (en) 2019-12-12 2019-12-12 Page processing method, device, server and computer readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911278067.0A CN111046310B (en) 2019-12-12 2019-12-12 Page processing method, device, server and computer readable storage medium

Publications (2)

Publication Number Publication Date
CN111046310A CN111046310A (en) 2020-04-21
CN111046310B true CN111046310B (en) 2024-03-19

Family

ID=70235927

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911278067.0A Active CN111046310B (en) 2019-12-12 2019-12-12 Page processing method, device, server and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN111046310B (en)

Families Citing this family (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111666516A (en) * 2020-04-24 2020-09-15 北京奇艺世纪科技有限公司 Page loading method and device, electronic equipment and storage medium
CN112437148B (en) * 2020-11-20 2023-03-07 北京奇艺世纪科技有限公司 Service request processing method and device, service server and system
CN112732757B (en) * 2020-12-30 2023-07-25 北京奇艺世纪科技有限公司 Method, system, device, equipment and storage medium for processing degraded data
CN112910973B (en) * 2021-01-21 2022-11-25 云账户技术(天津)有限公司 Application page selection method and device
CN113613063B (en) * 2021-07-16 2023-08-04 深圳市明源云科技有限公司 Application anomaly reduction method, device and storage medium
CN113965385B (en) * 2021-10-25 2024-06-11 恒安嘉新(北京)科技股份公司 Monitoring processing method, device, equipment and medium for abnormal website
CN117130692B (en) * 2023-10-23 2024-01-23 成都赛力斯科技有限公司 Application management method, device, electronic equipment and storage medium

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102937981A (en) * 2012-10-18 2013-02-20 北京奇虎科技有限公司 Webpage representing system and method
CN106649389A (en) * 2015-11-03 2017-05-10 阿里巴巴集团控股有限公司 Page pushing method and apparatus, and network system
CN106919600A (en) * 2015-12-25 2017-07-04 青岛海信移动通信技术股份有限公司 One kind failure network address access method and terminal
CN107784011A (en) * 2016-08-30 2018-03-09 广州市动景计算机科技有限公司 Web access method, client, web page server and programmable device
CN107864173A (en) * 2017-06-26 2018-03-30 平安普惠企业管理有限公司 Terminal page caching method, system and readable storage medium storing program for executing
CN108075922A (en) * 2016-11-14 2018-05-25 普天信息技术有限公司 A kind of telecommunication network management system
CN108400884A (en) * 2018-01-10 2018-08-14 链家网(北京)科技有限公司 A kind of method, system and device improving website service stability
CN109766354A (en) * 2018-12-04 2019-05-17 北京辰森世纪科技股份有限公司 Optimization method, device and the equipment of business datum inquiry
CN110096659A (en) * 2019-03-27 2019-08-06 北京三快在线科技有限公司 A kind of page display method, device, equipment and readable storage medium storing program for executing
CN110162720A (en) * 2019-04-16 2019-08-23 平安科技(深圳)有限公司 Webpage loading method, device, computer equipment and storage medium

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10176052B2 (en) * 2017-04-24 2019-01-08 International Business Machines Corporation Snapshot backup with unified restore information
CN112905175B (en) * 2021-02-08 2024-05-28 中国工商银行股份有限公司 Page generation method, device and equipment

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102937981A (en) * 2012-10-18 2013-02-20 北京奇虎科技有限公司 Webpage representing system and method
CN106649389A (en) * 2015-11-03 2017-05-10 阿里巴巴集团控股有限公司 Page pushing method and apparatus, and network system
CN106919600A (en) * 2015-12-25 2017-07-04 青岛海信移动通信技术股份有限公司 One kind failure network address access method and terminal
CN107784011A (en) * 2016-08-30 2018-03-09 广州市动景计算机科技有限公司 Web access method, client, web page server and programmable device
CN108075922A (en) * 2016-11-14 2018-05-25 普天信息技术有限公司 A kind of telecommunication network management system
CN107864173A (en) * 2017-06-26 2018-03-30 平安普惠企业管理有限公司 Terminal page caching method, system and readable storage medium storing program for executing
CN108400884A (en) * 2018-01-10 2018-08-14 链家网(北京)科技有限公司 A kind of method, system and device improving website service stability
CN109766354A (en) * 2018-12-04 2019-05-17 北京辰森世纪科技股份有限公司 Optimization method, device and the equipment of business datum inquiry
CN110096659A (en) * 2019-03-27 2019-08-06 北京三快在线科技有限公司 A kind of page display method, device, equipment and readable storage medium storing program for executing
CN110162720A (en) * 2019-04-16 2019-08-23 平安科技(深圳)有限公司 Webpage loading method, device, computer equipment and storage medium

Also Published As

Publication number Publication date
CN111046310A (en) 2020-04-21

Similar Documents

Publication Publication Date Title
CN111046310B (en) Page processing method, device, server and computer readable storage medium
US8782799B2 (en) Triggering a private browsing function of a web browser application program
US8856325B2 (en) Network element failure detection
US9183072B1 (en) Error troubleshooting using a correlated knowledge base
US11012339B2 (en) Web site reachability management for content browsing
CN106533944B (en) Distributed API gateway, management method and management system
CN103095530B (en) The monitoring of a kind of sensitive information based on preposition gateway and leakage prevention method and system
CN108683668A (en) Resource checksum method, apparatus, storage medium and equipment in content distributing network
US9379849B2 (en) Content delivery failover
US20200057714A1 (en) Testing data changes in production systems
CN112153170A (en) Method, device and equipment for accessing server and storage medium
CN106911735B (en) Data acquisition method and device
US7367508B2 (en) System and method for tracking URL usage
CN112600797A (en) Method and device for detecting abnormal access behavior, electronic equipment and storage medium
CN112685211B (en) Error information display method and device, electronic equipment and medium
CN108108126B (en) Data processing method, device and equipment
CN111694639B (en) Updating method and device of process container address and electronic equipment
CN111416844B (en) Service start-stop method, system, device and storage medium
CN112115521B (en) Data access method and device
CN110347955B (en) Resource detection method and device
CN112866062A (en) Distributed pressure test system, method, device, equipment and storage medium
CN111783005A (en) Method, apparatus and system for displaying web page, computer system and medium
CN110825603A (en) Page first loading time determining method and device, electronic equipment and storage medium
CN112653736B (en) Parallel source returning method and device and electronic equipment
CN114465926B (en) Recursive server monitoring method, device, equipment and storage medium

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
GR01 Patent grant
GR01 Patent grant