WO2019205192A1 - 一种网页加载方法、网页加载系统和服务器 - Google Patents

一种网页加载方法、网页加载系统和服务器 Download PDF

Info

Publication number
WO2019205192A1
WO2019205192A1 PCT/CN2018/086186 CN2018086186W WO2019205192A1 WO 2019205192 A1 WO2019205192 A1 WO 2019205192A1 CN 2018086186 W CN2018086186 W CN 2018086186W WO 2019205192 A1 WO2019205192 A1 WO 2019205192A1
Authority
WO
WIPO (PCT)
Prior art keywords
loading
loaded
page
user terminal
list
Prior art date
Application number
PCT/CN2018/086186
Other languages
English (en)
French (fr)
Inventor
韩天添
李琛
黄克伟
Original Assignee
网宿科技股份有限公司
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 网宿科技股份有限公司 filed Critical 网宿科技股份有限公司
Priority to US16/099,335 priority Critical patent/US20200319954A1/en
Priority to EP18906706.9A priority patent/EP3584669B1/en
Publication of WO2019205192A1 publication Critical patent/WO2019205192A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/0703Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation
    • G06F11/0793Remedial or corrective actions
    • 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
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/0703Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation
    • G06F11/079Root cause analysis, i.e. error or fault diagnosis
    • 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/9577Optimising the visualization of content, e.g. distillation of HTML documents
    • 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/958Organisation or management of web site content, e.g. publishing, maintaining pages or automatic linking
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • H04L61/45Network directories; Name-to-address mapping
    • H04L61/4505Network directories; Name-to-address mapping using standardised directories; using standardised directory access protocols
    • H04L61/4511Network directories; Name-to-address mapping using standardised directories; using standardised directory access protocols using domain name system [DNS]

Definitions

  • Embodiments of the present invention relate to the field of Internet, and in particular, to a webpage access acceleration technology.
  • a script is an extension of a batch file. It is a plain text save program.
  • a computer script program is a combination of a series of control operations that perform operations on a computer, in which certain logical branches can be implemented.
  • HTML HyperText Markup Language
  • JS Short for JavaScript
  • CSS CSS
  • images There are multiple elements in a page, such as HTML, JS (short for JavaScript), CSS (Cascading Style Sheet), and images.
  • JS scripts work in the browser. By default, when a script is encountered, the browser needs to stop and wait for it to complete before it can finish drawing the page.
  • the download and rendering of the page must stop and wait for the script to complete. If the loading sequence is not correct, it will cause a large number of element requests to be blocked, resulting in a longer page load time.
  • the main method of the prior art is to modify the structure of the website, adjust the loading order, and put the script tag at the bottom, thereby increasing the speed at which the page is presented to the user.
  • the inventors have found that at least the following problems exist in the prior art: although the above method can theoretically optimize the access speed of the webpage, practical compatibility problems still occur, such as display errors of some webpages when displayed, and even Can not be displayed, and these problems are often overlooked, and there is no further way to solve them.
  • An object of the embodiments of the present invention is to provide a webpage loading method, a webpage loading system, and a server, so as to optimize the user experience in the process of optimizing webpage loading, and to facilitate promotion, without modifying the source code and reducing the technology of the website owner. Development time.
  • an embodiment of the present invention provides a webpage loading method, which is applied to an edge server of a content distribution network, and includes: after enabling the front-end optimization function, acquiring a page to be loaded according to a page loading request from the user terminal.
  • the original load list ; the original load list is optimized, the optimized load list is obtained; the optimized load list is sent to the user terminal; and it is determined whether the page to be loaded is loaded incorrectly on the user terminal; If the loading error is determined, the original loading list is sent to the user terminal.
  • Embodiments of the present invention also provide a server comprising: at least one processor; and a memory communicatively coupled to the at least one processor; wherein the memory is stored for execution by the at least one processor An instruction executed by the at least one processor to enable the at least one processor to perform a web page loading method as described above.
  • Embodiments of the present invention also provide a computer readable storage medium storing a computer program that, when executed by a processor, implements the web page loading method described above.
  • the main difference between the embodiments of the present invention and the effect thereof is that after the front-end optimization function is started in the prior art, the webpage display may not be normal or even displayed due to the compatibility problem of the browser.
  • the optimized loading list is temporarily bypassed, so that the user terminal can load according to the original list request, and the web page is displayed as normal as possible.
  • the embodiment of the present invention is implemented by the content distribution network, the established website optimization mode is innovatively improved, neither changing the configuration of the user terminal nor changing the code of the source station, and changing the page source to be accessed.
  • the website structure of the station is convenient to implement, which can reduce the technology development time of the website owner, provide a better online experience for the user terminal side, and facilitate the promotion of the embodiment of the present invention. It can be seen that the embodiment of the present invention optimizes the user experience in the process of optimizing the loading of the webpage, and is convenient for promotion, and does not need to modify the source station code, thereby reducing the technical development time of the website owner.
  • the optimization of the original loading list specifically includes: adding a monitoring script to the original loading list; determining whether the page to be loaded is loaded on the user terminal is incorrect, specifically: using the monitoring script to determine the location Whether the loading page is loaded with an error on the user terminal.
  • the monitoring script is further limited to automatically detect the loading of the page, so as to accurately understand the loading of the page on the user terminal side.
  • the monitoring script is configured to send a loading error report to the edge server when detecting that the page to be loaded is in error; and determining whether the page to be loaded is loaded on the user terminal, specifically including When receiving the loading error report from the monitoring script, it is determined that the page to be loaded is loaded with an error on the user terminal. Further limiting the monitoring script will automatically report an error, so that the edge server side can know the status of the loading error more quickly.
  • determining whether the page to be loaded is loaded with an error on the user terminal specifically: determining, according to the number of times the user terminal receives the loading request for the same add-on in the first preset time, Whether the page to be loaded is loaded with errors on the user terminal. Further limiting the detection of page load errors by simply monitoring the number of load requests of the same add-on.
  • determining whether the page to be loaded is loaded on the user terminal is incorrect according to the number of times the user terminal receives the loading request for the same add-on in the first preset time which includes: When the number of times the user terminal receives the loading request for the same add-on in the first preset time reaches the first preset number of times, it is determined that the page to be loaded is loaded on the user terminal. Since the user terminal side may be repeatedly loaded by the user operation when the loading error occurs, it is confirmed that the page loading error on the user terminal is detected when the same loading request is received for a short time.
  • the method further includes: when sending the original loading list to the user terminal, recording an error for the reported add-on; monitoring an error count for the add-on; if the number of errors reaches a second preset And sending, to the administrator of the to-be-loaded page, the alarm information for the add-on, where the second preset number of times is greater than the first preset number of times. Further limit the number of error records of the add-on records. When there are too many error reports, it can be considered as a problem with the front-end optimization function. Therefore, it needs to be further reported to the administrator.
  • the automatic detection and reporting mechanism ensures that the page is loaded normally while greatly reducing the manpower.
  • the method further includes: suspending the front-end optimization function when sending the alarm information for the add-on to the administrator of the to-be-loaded page.
  • the pause front-end optimization function By using the pause front-end optimization function, the alarm is not repeated for a short period of time to avoid mail storms.
  • the method further includes: suspending the front-end optimization function for a preset preset duration, and then restoring the front-end optimization function. Further limit the duration of the suspension to ensure that the alarm will be re-issued when the problem still exists to avoid false negatives.
  • the method further includes: turning off the front-end optimization function when sending the alarm information for the add-on to the administrator of the to-be-loaded page.
  • the front-end optimization function can be directly turned off during the alarm to ensure normal loading of the webpage.
  • the optimizing the original loading list specifically includes: rewriting the to-accelerated resource in the loading list according to a predetermined optimization scheme. Using the rewriting method to optimize the original loading list, while ensuring the user's website loading experience, the website developer's development time is further reduced, and the time of website technology development is accelerated.
  • the method further includes: determining, according to the cookie record information carried in the page loading request, whether the original loading needs to be optimized. a list; if it is determined to be necessary, performing the step of optimizing the original load list; if it is determined to be unnecessary, performing the step of transmitting the original load list to the user terminal.
  • the embodiment of the present application uses the cookie record information to determine which load list the feedback load list is, so as to obtain a suitable load list afterwards.
  • FIG. 1 is a flowchart of a webpage loading method according to a first embodiment of the present invention
  • FIG. 2 is a flowchart of a webpage loading method according to a third embodiment of the present invention.
  • FIG. 3 is a flowchart of a webpage loading method according to a fourth embodiment of the present invention.
  • FIG. 4 is a schematic diagram of an alarm mechanism 1 in a webpage loading method according to a third embodiment of the present invention.
  • FIG. 5 is a schematic diagram of an alarm mechanism 2 in a webpage loading method according to a third embodiment of the present invention.
  • FIG. 6 is a schematic diagram of an alarm mechanism 3 in a webpage loading method according to a third embodiment of the present invention.
  • FIG. 7 is a schematic structural diagram of a server according to a fifth embodiment of the present invention.
  • FIG. 8 is a schematic diagram of a webpage loading system in accordance with a sixth embodiment of the present invention.
  • a first embodiment of the present invention relates to a web page loading method.
  • the embodiment can be applied to a server, which can be an edge server under a CDN architecture (such as an accelerated cloud platform).
  • a server which can be an edge server under a CDN architecture (such as an accelerated cloud platform).
  • CDN content delivery network
  • Service providers typically provide content delivery services on behalf of third parties (such as customers) who use the service provider infrastructure.
  • This type of distributed system generally refers to a collection of autonomous computers linked by one or more networks, as well as software, systems, protocols, and technologies designed to facilitate various services, such as content delivery, web application acceleration, or other support outsourcing. Origin of the infrastructure.
  • CDN service providers typically provide service delivery through digital attributes such as websites, which are provisioned in the customer portal and then deployed to the network.
  • Digital assets are typically tied to one or more edge configurations to allow service providers to bill traffic and bill their customers.
  • the overlay network as above can be combined or interoperable with a front end optimization (FEO) scheme.
  • FEO is the process of speeding up a web page by modifying the HTML and the resources on it. The goal is to eliminate bottlenecks and inefficiencies in the front end of the website that is being used.
  • FEO there are a number of specific optimizations that can be used. Their goal is to do one or more of the following: reduce the number of HTTP requests required to load a page, rather than download more data in one request; more efficient by using it. Format to reduce the total size of the page and its parts, improve caching and remove unnecessary content; and speed up rendering by having the browser load items in different orders or times, such as preventing third-party scripts from delaying all of the pages Other events.
  • a distributed computer system is configured as a CDN and is assumed to have a set of machines 1 ⁇ 2a-n distributed around the Internet.
  • machines are servers located near the edge of the Internet, either at the end user access network or adjacent to the end user access network.
  • the network operations command center (“NOCC”) manages the operation of various machines in the system.
  • Third-party sites such as websites, offloaded content (eg, HTML, embedded page objects, streaming media, software downloads, etc.) to distributed computer systems, particularly "edge" servers.
  • a content provider offloads its content delivery by aliasing an alias of a given content provider domain or subdomain (eg, via a DNS CNAME) to a domain managed by the service provider's authoritative domain name service. It is desirable that the end user of the content be directed to a distributed computer system to obtain content more reliably and efficiently.
  • a distributed computer system may also include other infrastructure, such as a distributed data collection system that collects usage and other data from an edge server, aggregating the data over a region or set of regions, and Data to other back-end systems to facilitate monitoring, logging, alerting, billing, management, and other operational and management functions.
  • FIG. 1 The flow of the webpage loading method in this embodiment is shown in FIG. 1, and the details are as follows:
  • step 101 the front end optimization function is started.
  • the specific startup method can be automatic startup.
  • Step 102 Obtain an original loading list according to the loading request.
  • the step acquires the original loading list of the page to be loaded according to the page loading request from the user terminal.
  • the page load request may be issued when the user accesses the webpage through the browser, or may be issued when viewing a certain page of the application (ie, "APP").
  • the load list (ie, the HTML document) includes the add-in of the page and the loading order of each add-on.
  • the load list may be pre-stored locally on the server. Even if the actual location of the server to which the web page belongs is remote, it can be mirrored to the local. Then, when the page load request is received, the pre-stored load list can be directly fed back to the user terminal, and then The user's browser performs subsequent operations.
  • the loading list corresponding to the page to be accessed may not be pre-stored locally, and the server may also request the source station to which the web page belongs, and the request is fed back to the user terminal.
  • the customer such as the user terminal
  • the overlay network is provided to provide the use of the customer portal CDN edge server to provide an indication that the FEO should be applied to the customer's site ( Or some of its parts) configuration data using the FEO service.
  • the first user request ie, the page's load request
  • the Edge Server GHost Global Host
  • the Edge Server GHost applies its configuration data and determines that this request should use FEO. It then looks up the standardized information for this digital property in the FEO configuration cache.
  • the global host process communicates with the FEO network using a RESTful request and the data is exchanged to an API (such as a Google Protocol Buffer).
  • the API responds to the normalization request and returns the information by performing a database lookup on the digital property.
  • the response to the RESTful request is cached.
  • the Edge Server Global Host process receives the second user request, then applies the configuration and determines that the request should use FEO.
  • the global host process looks up the normalized information for this client, and this information is now available.
  • step 103 the original loading list is optimized to obtain an optimized loading list.
  • the step rewrites the to-be-accelerated resource in the loading list according to a predetermined optimization scheme, where the predetermined optimization scheme includes at least one of the following: an asynchronous rewriting scheme, an accelerated rewriting scheme, and a mask rewriting scheme.
  • the predetermined optimization scheme is determined by the preset policy by rewriting the to-be-accelerated resources in the load list according to a predetermined optimization scheme.
  • the preset policy may specify that each of the to-be-accelerated resources adopts one optimization scheme, and may also specify different optimization schemes for different resources to be accelerated.
  • other optimization schemes may be added as needed, and the number and content of the optimization schemes are not limited herein.
  • the optimization manner in this embodiment further includes: adding a monitoring script to the original loading list, where the monitoring script is used to detect an error of loading the page to be loaded (such as when the page to be loaded is incomplete), to the edge server. Send a load error report.
  • the content of the monitoring script can be written according to its function, and will not be described here.
  • Step 104 Send the optimized loading list to the user terminal.
  • the user terminal After receiving the reloaded load list, the user terminal requests each resource according to the load list.
  • Step 105 Determine whether the page to be loaded is loaded incorrectly on the user terminal; if yes, execute step 106; if not, return to step 105.
  • the inventor of the present application found that, because the added front-end optimization function may be incompatible with the script, the user terminal cannot normally request the optimized load list, so that the page to be loaded is loaded incorrectly, and may not be completely displayed. It may even be impossible to display at all.
  • the monitoring script added to the original loading list is used to determine whether the page to be loaded is loaded incorrectly on the user terminal. More specifically, based on whether or not a loading error report from the monitoring script is received, it is determined whether the page to be loaded is loaded incorrectly on the user terminal. Wherein, when receiving the loading error report from the monitoring script, it is determined that the page to be loaded is loaded on the user terminal with an error. In the actual application, if the loading error report from the monitoring script is not received, the process returns to the determining step of step 105 to repeat the determination.
  • Step 106 Send the original loading list to the user terminal.
  • the original loading list sent in this step is the original loading list obtained in step 102.
  • the present invention utilizes Whether the loading page is loaded with error detection on the user terminal, by returning the original page loading list, temporarily bypassing the optimized loading list, so that the user terminal can load according to the original list request, and try to ensure that the web page is displayed normally.
  • the embodiment of the present invention is implemented by the content distribution network, the established website optimization mode is innovatively improved, neither changing the configuration of the user terminal nor changing the code of the source station, and changing the page source to be accessed.
  • the website structure of the station is convenient to implement, which can reduce the technology development time of the website owner, provide a better online experience for the user terminal side, and facilitate the promotion of the embodiment of the present invention.
  • the implementation method optimizes the user experience in the process of optimizing the loading of the webpage, and is convenient for promotion, and does not need to modify the source station code, thereby reducing the technical development time of the website owner.
  • the present embodiment monitors page integrity by inserting a JS script into the edge server. When an error occurs, a URL jump is performed to re-acquire a page that does not use the JS optimization function to the edge server.
  • a second embodiment of the present invention relates to a web page loading method.
  • the second embodiment is substantially the same as the first embodiment, and the main difference and the effect thereof are as follows: in the first embodiment, the automatic execution of the monitoring script is added to the original loading list to determine whether the page loading is erroneous, and the present embodiment utilizes Counting the load request sent by the user terminal, and determining whether the page load is wrong. In this embodiment, by monitoring the number of loading requests of the same add-on, the detection of the page loading error is easily and easily implemented.
  • step 105 when it is determined whether the page to be loaded is loaded on the user terminal, the user terminal receives the same add-on according to the first preset time. The number of times the request is loaded, and it is determined whether the page to be loaded is loaded incorrectly on the user terminal.
  • the user terminal may repeatedly issue a load request when the page is loaded incorrectly, if the load request of the same user terminal for the same add-on is received multiple times in a short time, it may be determined that the user terminal side is loaded incorrectly.
  • the edge server receives the repeated loading request after two times. That is, the original loading list is fed back to the user terminal, so that the user terminal can ignore the optimized loading list as soon as possible, and use the original loading list to request various resources, so that the user can view the normal page as soon as possible and increase the user experience.
  • the specific method for determining whether the page to be loaded is loaded on the user terminal is determined by the statistically received repeated loading request, so that the judging process is simple and feasible.
  • the threshold of the repeated loading request is further defined, so that the page to be loaded can be loaded as soon as possible, and the user terminal browser is separated from the white screen interface as soon as possible to provide a better access experience for the user.
  • the method for determining the page loading error used in the embodiment may be used in combination with the method for determining the page loading error in the first embodiment, and details are not described herein again.
  • a third embodiment of the present invention relates to a web page loading method.
  • the third embodiment is further improved on the basis of the first embodiment.
  • the main improvement is that in the third embodiment of the present invention, an alarm mechanism is added, so that after temporarily bypassing the front-end optimization mechanism, it is possible The error is escalated so that the administrator can better screen for troubleshooting.
  • FIG. 2 The flowchart of the webpage loading method in this embodiment is shown in FIG. 2, and the details are as follows:
  • Steps 201 to 206 in this embodiment are similar to steps 101 to 106 in the first embodiment, and are not described herein again.
  • Step 207 Record an error for the page to be loaded, and accumulate the total number of errors.
  • Step 208 Determine whether the number of error reports reaches the second preset number of times; if yes, execute step 209; if not, return to step 208.
  • the second preset number of times may be five times, which is not limited herein.
  • Step 209 Send an alarm information for the add-on to the administrator of the page to be loaded.
  • the edge server can count the number of error reports. If the number of error reports is too large (for example, the number of error times reaches the second preset number of times), it can be basically confirmed that the front-end optimization function is abnormal, and then the page is to be loaded.
  • the administrator sends the alarm information for the add-on.
  • the alarm information can be sent to the administrator terminal by email.
  • multiple user terminals may request a page to be loaded from an edge server, so the edge server may receive an error from a different user terminal, because the page loading error may be due to compatibility problems of the front-end optimization function,
  • Such a problem causes a loading error, which may affect more than one user terminal, so when monitoring the number of error reports, the number of error times of multiple user terminals can be accumulated.
  • the number of error times for the add-on is cleared, and after clearing, the process returns to step 208. That is to say, after the number of error times reaches the second preset number, the administrator is alerted.
  • a further mechanism thereafter may be to directly turn off the front-end optimization function after alerting the administrator twice to avoid short-term repeated alarms.
  • the alarm process diagram can be as shown in Figure 4.
  • the front-end optimization function is suspended, and the pause duration is continued, and after the preset duration is reached, the front-end optimization function is resumed.
  • the preset duration can be set to 5-10 minutes, and the pause front-end optimization function is used to avoid repeated error reporting and short-term repeated alarms. After the preset duration is reached, the front-end optimization function is restarted. If the function is not turned off, the alarm mechanism will be restored.
  • the alarm process diagram can be as shown in Figure 5.
  • the front-end optimization function is directly turned off. Wait for the administrator to troubleshoot the alarm information. If it is determined that it is not caused by the front-end optimization function, you can enable the front-end optimization function.
  • the alarm process diagram can be as shown in Figure 6.
  • the alarm mechanism is added in this embodiment, so that after the front-end optimization mechanism is temporarily bypassed, the situation that may be wrong is reported, so that the administrator can better screen the troubleshooting.
  • the number of error records of the add-on record is considered to be a problem with the front-end optimization function when the number of error times is too large. Therefore, it needs to be further reported to the administrator.
  • the automatic detection and reporting mechanism ensures that the page is loaded normally while greatly reducing the manpower. At the same time, three mechanisms are provided to suspend or disable the front-end optimization function, so that the alarm is not repeated in a short period of time, and the mail storm of the administrator is avoided.
  • a fourth embodiment of the present invention relates to a web page loading method.
  • the fourth embodiment is further improved on the basis of the first embodiment.
  • the main improvement is that in the fourth embodiment of the present invention, the detection of the cookie record information is added, and the original load list is automatically determined or optimized.
  • the load list, the edge server can send a load list for the user terminal as soon as possible, speeding up the overall loading speed.
  • Steps 301 and 302 in this embodiment are similar to steps 101 and 102 in the first embodiment, and are not described herein again.
  • step 303 it is determined whether it is necessary to optimize the original loading list; if the determination is yes, step 304 is performed; if the determination is no, step 307 is performed.
  • this step it is determined according to the cookie record information carried in the page loading request.
  • the original loading list is directly sent to the user terminal. , no longer perform the steps of optimizing the load list.
  • Steps 304 and 307 in this embodiment are similar to steps 103 and 106 in the first embodiment, and are not described herein again.
  • the embodiment uses the cookie record information to determine which load list the feedback load list is, so that it can quickly obtain a suitable load list afterwards, speed up the loading speed of the add-on, and further speed up the access speed of the webpage.
  • a fifth embodiment of the present invention relates to a server, as shown in FIG. 7, including:
  • At least one processor and a memory communicatively coupled to the at least one processor; wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to perform Any one of the webpage loading methods of the fourth to fourth embodiments.
  • the memory and the processor are connected in a bus manner, and the bus may include any number of interconnected buses and bridges that connect the various circuits of one or more processors and memories.
  • the bus can also connect various other circuits, such as peripherals, voltage regulators, and power management circuits, as is well known in the art, and therefore, will not be further described herein.
  • the bus interface provides an interface between the bus and the transceiver.
  • the transceiver can be an element or a plurality of elements, such as multiple receivers and transmitters, providing means for communicating with various other devices on a transmission medium.
  • the data processed by the processor is transmitted over the wireless medium via an antenna. Further, the antenna also receives the data and transmits the data to the processor.
  • the processor is responsible for managing the bus and normal processing, as well as providing various functions including timing, peripheral interfaces, voltage regulation, power management, and other control functions.
  • the memory can be used to store data used by the processor when performing operations.
  • a sixth embodiment of the present invention relates to a webpage loading system, as shown in FIG. 8, specifically comprising: a user terminal and a server as mentioned in the fifth embodiment, wherein the server may be an edge server under the CDN architecture.
  • the webpage loading system in this embodiment may further include a source station server to which the webpage to be loaded belongs.
  • a seventh embodiment of the present invention relates to a computer readable storage medium storing a computer program.
  • the above method embodiments are implemented when the computer program is executed by the processor.
  • the foregoing storage medium includes: a U disk, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk, and the like. .

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Quality & Reliability (AREA)
  • Health & Medical Sciences (AREA)
  • Biomedical Technology (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

本发明实施例涉及互联网领域,公开了一种网页加载方法、网页加载系统和服务器。本发明中,一种网页加载方法,应用于内容分发网络的边缘服务器,包括:在启用前端优化功能后,根据来自用户终端的页面加载请求,获取待加载页面的原加载清单;优化所述原加载清单,获得优化后的加载清单;向所述用户终端发送所述优化后的加载清单;判断所述待加载页面在所述用户终端上是否加载出错;若判定加载出错,则向所述用户终端发送所述原加载清单。本发明实施方式使得在优化网页加载的过程中,优化用户体验,且便于推广,同时无需修改源站代码,减少网站拥有者的技术开发时间的。

Description

一种网页加载方法、网页加载系统和服务器 技术领域
本发明实施例涉及互联网领域,特别涉及网页访问加速技术。
背景技术
脚本(Script)是批处理文件的延伸,是一种纯文本保存的程序,一般来说的计算机脚本程序是确定的一系列控制计算机进行运算操作动作的组合,在其中可以实现一定的逻辑分支等。一个页面中有多种元素,如HTML、JS(即JavaScript的缩写)、CSS(Cascading Style Sheet,层叠样式表单)和图片等等。JS脚本在浏览器的工作方式中,默认情况下遇到一段脚本时,浏览器需要停止并等待它执行完成,然后才能完成绘制页面,这意味着,文件是一个一个加载和执行,这将影响浏览器的执行时间,当页面架构不合理,JS脚本位置靠前时,就会出现首屏加载缓慢,图片出不来,长期显示白屏,用户体验差的问题。
当JavaScript在执行时,页面的下载和渲染都必须停下来等待脚本执行完成。如果加载顺序不当,会导致阻塞大量元素请求,从而造成页面加载时间变长。对于请求加载顺序的优化,现有技术主要的方法是修改网站结构,调整加载顺序,还有将script标签放底部,从而提高页面展现给用户的速度。然而,发明人发现现有技术中至少存在如下问题:虽然上述方法可以在理论上对网页访问速度进行优化,但实际仍会出现兼容性的问题,比如部分网页在显示时,出现显示错误,甚至无法显示,而这些问题往往被忽视,并没有进一步的方法进行解决。
发明内容
本发明实施方式的目的在于提供一种网页加载方法、网页加载系统和服务器,使得在优化网页加载的过程中,优化用户体验,且便于推广,同时无需修改源站代码,减少网站拥有者的技术开发时间的。
为解决上述技术问题,本发明的实施方式提供了一种网页加载方法,应用于内容分发网络的边缘服务器,包括:在启用前端优化功能后,根据来自用户终端的页面加载请求,获取待加载页面的原加载清单;优化所述原加载清单,获得优化后的加载清单;向所述用户终端 发送所述优化后的加载清单;判断所述待加载页面在所述用户终端上是否加载出错;若判定加载出错,则向所述用户终端发送所述原加载清单。
本发明的实施方式还提供了一种服务器,包括:至少一个处理器;以及,与所述至少一个处理器通信连接的存储器;其中,所述存储器存储有可被所述至少一个处理器执行的指令,所述指令被所述至少一个处理器执行,以使所述至少一个处理器能够执行如上述的网页加载方法。
本发明的实施方式还提供了一种计算机可读存储介质,存储有计算机程序,所述计算机程序被处理器执行时实现上述的网页加载方法。
本发明实施方式相对于现有技术而言,主要区别及其效果在于:现有技术在启动前端优化功能后,仍可能因为浏览器的兼容问题造成网页显示不正常,甚至无法显示,本申请中利用对待加载页面在用户终端上是否加载出错的检测,通过返回原始的页面加载清单,暂时绕过优化后的加载清单,使得用户终端可以根据原始清单请求加载,尽量保证网页正常显示。另外,由于本发明实施方式由内容分发网络实施,创新地改进了行内既定的网站优化模式,既不需要改变用户终端的配置,也不需要改变源站的代码,又不需要改变需访问页面源站的网站构架,实施便捷,可以减少网站拥有者的技术开发时间,给用户终端侧提供更优质的上网体验,便于本发明实施方式的推广。可见,本发明实施方式使得在优化网页加载的过程中,优化用户体验,且便于推广,同时无需修改源站代码,减少网站拥有者的技术开发时间的。
作为进一步改进,优化原加载清单,具体包括:将监控脚本添加至所述原加载清单;所述判断待加载页面在所述用户终端上是否加载出错,具体为:利用所述监控脚本,判断所述待加载页面在所述用户终端上是否加载出错。进一步限定监控脚本自动对页面的加载情况进行检测,便于准确了解用户终端侧页面的加载情况。
作为进一步改进,所述监控脚本用于在检测到所述待加载页面加载出错时,向所述边缘服务器发送加载出错报告;所述判断待加载页面在所述用户终端上是否加载出错,具体包括:在收到来自所述监控脚本的加载出错报告时,判定为所述待加载页面在所述用户终端上加载出错。进一步限定监控脚本会自动报错,使得边缘服务器侧可以更快获知加载出错的状态。
作为进一步改进,判断待加载页面在所述用户终端上是否加载出错,具体为:根据在所述第一预设时间内收到所述用户终端针对同一加载项的加载请求的次数,判断所述待加载页面在所述用户终端上是否加载出错。进一步限定通过监控同一加载项的加载请求的次数,简便易行地实现对页面加载出错的检测。
作为进一步改进,根据在第一预设时间内收到所述用户终端针对同一加载项的加载请求 的次数,判断所述待加载页面在所述用户终端上是否加载出错,具体包括:若在所述第一预设时间内收到所述用户终端针对同一加载项的加载请求的次数达到第一预设次数时,则判定为所述待加载页面在所述用户终端上加载出错。由于用户终端侧在加载出错时,可能被用户操作反复加载,所以检测收到短时多次的相同加载请求时,可确认为用户终端上页面加载出错。
作为进一步改进,还包括:在向所述用户终端发送所述原加载清单时,记录针对所报错的加载项的一次报错;监测针对加载项的报错次数;若所述报错次数达到第二预设次数,则向所述待加载页面所属管理员发送针对所述加载项的告警信息,所述第二预设次数大于所述第一预设次数。进一步限定加载项记录报错次数,在报错次数过多时,即可认为是前端优化功能出现问题,所以需要进一步上报管理员,自动检测上报机制在保证页面被正常加载的同时,大大减少人力。
作为进一步改进,还包括:在向所述待加载页面所属管理员发送针对所述加载项的告警信息时,暂停所述前端优化功能。利用暂停前端优化功能,使得短时间内不重复告警,避免邮件风暴。
作为进一步改进,所述暂停前端优化功能后,还包括:暂停所述前端优化功能持续预设时长后,恢复启用所述前端优化功能。进一步限定暂停时长,保证在问题仍然存在时会再次告警,避免漏报。
作为进一步改进,还包括:在向所述待加载页面所属管理员发送针对所述加载项的告警信息时,关闭所述前端优化功能。本申请实施方式可以在告警时直接关闭前端优化功能,保证网页的正常加载。
作为进一步改进,所述优化原加载清单具体包括:根据预定的优化方案改写所述加载清单中的所述待加速资源。利用改写方式优化原加载清单,使得在保证用户的网站加载体验的同时,进一步减少网站开发者的开发时间,加快网站技术开发的时间。
作为进一步改进,在所述获取待加载页面的原加载清单之后,在所述优化原加载清单之前,还包括:根据所述页面加载请求中携带的cookies记录信息,判断是否需要优化所述原加载清单;若判定为需要,则执行所述优化原加载清单的步骤;若判定为不需要,则执行所述向所述用户终端发送所述原加载清单的步骤。本申请实施方式利用cookies记录信息确定所反馈的加载清单为哪种加载清单,便于后续后快获取到合适的加载清单。
附图说明
一个或多个实施例通过与之对应的附图中的图片进行示例性说明,这些示例性说明并不构成对实施例的限定,附图中具有相同参考数字标号的元件表示为类似的元件,除非有特别申明,附图中的图不构成比例限制。
图1是根据本发明第一实施方式中的网页加载方法流程图;
图2是根据本发明第三实施方式中的网页加载方法流程图;
图3是根据本发明第四实施方式中的网页加载方法流程图;
图4是根据本发明第三实施方式中的网页加载方法中告警机制一的示意图;
图5是根据本发明第三实施方式中的网页加载方法中告警机制二的示意图;
图6是根据本发明第三实施方式中的网页加载方法中告警机制三的示意图;
图7是根据本发明第五实施方式中的服务器的结构示意图;
图8是根据本发明第六实施方式中的网页加载系统的示意图。
具体实施方式
为使本发明实施例的目的、技术方案和优点更加清楚,下面将结合附图对本发明的各实施方式进行详细的阐述。然而,本领域的普通技术人员可以理解,在本发明各实施方式中,为了使读者更好地理解本申请而提出了许多技术细节。但是,即使没有这些技术细节和基于以下各实施方式的种种变化和修改,也可以实现本申请所要求保护的技术方案。
本发明的第一实施方式涉及一种网页加载方法。
本实施方式可以应用于一种服务器,具体可以为CDN架构(如加速云平台)下的边缘服务器。关于现有的分布式计算机系统,是由服务提供商操作和管理的“内容传送网络”或“CDN”。服务提供商通常代表使用服务提供商基础设施的第三方(如客户)提供内容交付服务。这种类型的分布式系统通常是指由一个或多个网络链接的自主计算机集合,以及为便于各种服务而设计的软件、系统、协议和技术,诸如内容传递,Web应用加速或其他支持外包的原产地基础设施。CDN服务提供商通常通过数字属性(例如网站)来提供服务交付,其在客户门户中供应,然后部署到网络。数字资产通常绑定到一个或多个边缘配置,以允许服务提供商对流量进行计费并为其客户计费。如上的覆盖网络可以与前端优化(FEO)方案结合或互操作。FEO是通过修改HTML和其上的资源来加速网页的过程。目标是消除使用覆盖的网站前端的瓶颈和低效率。在FEO中,有许多特定的优化可以使用,他们的目标是做以下 一项或多项:减少加载页面所需的HTTP请求数量,而不是在一个请求中下载更多的数据;通过使用更有效的格式来减小网页及其部分的总大小,提高缓存能力并去除不必要的内容;并通过使浏览器以不同的顺序或时间加载项来加速呈现,例如防止第三方脚本延迟页面上的所有其他事件。
具体的说,在已知的覆盖网络系统中,分布式计算机系统被配置为CDN并且假定具有分布在因特网周围的一组机器1^2a-n。通常,大多数机器是位于互联网边缘附近的服务器,即位于最终用户接入网络处或邻近最终用户接入网络。网络操作命令中心(network operations command center,简称“NOCC”)管理系统中各种机器的操作。诸如网站之类的第三方站点将分派的内容(例如,HTML,嵌入式页面对象,流媒体,软件下载等)卸载到分布式计算机系统,特别是“边缘”服务器。通常,内容提供商通过将给定内容提供商域或子域的别名(例如,通过DNS CNAME)别名到由服务提供商的权威性域名服务管理的域来卸载其内容传送。希望内容的最终用户被引导到分布式计算机系统以更可靠和有效地获得内容。虽然没有详细示出,但是分布式计算机系统还可以包括其他基础设施,诸如从边缘服务器收集使用量和其他数据的分布式数据收集系统,在一个区域或一组区域上聚合该数据,并将该数据到其他后端系统以促进监视、记录、警报、计费、管理和其他操作和管理功能。
本实施方式中网页加载方法的流程如图1所示,具体如下:
步骤101,启动前端优化功能。
具体的说,由于现有针对待加载页面上的资源是一个一个加载和执行,这将影响浏览器的执行时间,当页面架构不合理,JS脚本位置靠前时,JS加载速度会影响到网站的整体加载效果。尤其是当页面上具备第三方JS文件时,其加载速度更不可控。所以,可能设置前端优化功能对其加载过程进行优化。具体的启动方法可以是自动启动,
步骤102,根据加载请求获得原加载清单。
具体的说,本步骤在接收到来自用户终端的页面加载请求时,根据来自用户终端的页面加载请求,获取待加载页面的原加载清单。
需要说明的说,页面加载请求可以是在用户通过浏览器进行网页访问时发出,也可以是在查看应用程序(即“APP”)的某一页面时发出的。
具体的说,加载清单(即HTML文档)中包括页面的加载项和各加载项的加载顺序。同时,加载清单可能预存于服务器本地,即使网页所属服务器实际位置较远,也可以预先镜像至本地,那么在接收到页面加载请求时,就可以直接将预存的加载清单反馈至用户终端,继而由用户浏览器进行后续操作。实际应用中,需访问的页面对应的加载清单也可能并未预存 于本地,那么服务器也可以向网页所属的源站请求,请求到后反馈给用户终端。
关于边缘服务器针对来自用户终端的请求的处理,以下根据实际应用中的实现方式具体描述,覆盖网络的客户(如用户终端)被提供使用客户门户CDN边缘服务器提供指示FEO应适用于客户的现场(或其一些部分)配置数据使用FEO服务。然后在边缘服务器处接收到第一个用户请求(即页面的加载请求)。边缘服务器GHost(全局主机)进程应用其配置数据并确定此请求应使用FEO。然后,它在FEO配置缓存中查找这个数字财产的标准化信息。在一个实施例中,全局主机进程使用RESTful请求与FEO网络通信,并且数据被交换到API(诸如Google协议缓冲器)。API通过对该数字财产进行数据库查找来对归一化请求做出响应并返回该信息。对RESTful请求的响应被缓存。然后,在边缘服务器全局主机进程接收第二个用户请求,然后应用配置并确定这个请求应该使用FEO。全球主机进程然后查找这个客户的规范化信息,这个信息现在出现了。
步骤103,优化原加载清单,获得优化后的加载清单。
具体的说,本步骤根据预定的优化方案改写加载清单中的待加速资源,其中,预定的优化方案至少包括以下之一:异步改写方案、加速改写方案和屏蔽改写方案。更具体的说,根据预定的优化方案改写加载清单中的待加速资源中,预定的优化方案由预设策略确定。其中,预设策略中可以指定各个待加速资源均采用某一种优化方案,也可以针对不同的待加速资源指定不同的优化方案。另外,实际应用中除了上述三种优化方案外,还可以根据需要增加其他优化方案,在此不对优化方案的数量和内容做限定。
需要说明的是,本实施方式中优化方式还包括:将监控脚本添加至原加载清单,该监控脚本用于在检测到待加载页面加载出错(如待加载页面显示不完整)时,向边缘服务器发送加载出错报告。实际应用中,监控脚本的内容可以根据其功能撰写,在此不再赘述。
步骤104,向用户终端发送优化后的加载清单。
具体的说,用户终端在收到改写后的加载清单后,根据加载清单请求各项资源。
步骤105,判断待加载页面在用户终端上是否加载出错;若是,则执行步骤106;若否,则返回步骤105。
具体的说,本申请发明人发现,由于增加的前端优化功能可能由于和脚本的不兼容,造成用户终端无法对优化后的加载清单正常请求,使得待加载页面加载出错,可能是没有完整显示,甚至可能完全无法显示。
本实施方式利用添加至原加载清单的监控脚本,判断待加载页面在用户终端上是否加载出错。更具体的说,根据是否收到来自监控脚本的加载出错报告,判断待加载页面在用户终 端上是否加载出错。其中,在收到来自监控脚本的加载出错报告时,判定为待加载页面在用户终端上加载出错。实际应用中,如果未收到来自监控脚本的加载出错报告时,则返回步骤105的判断步骤重复判断。
步骤106,向用户终端发送原加载清单。
具体的说,本步骤发送的原加载清单即为步骤102中获得的原加载清单。
本实施方式相对于现有技术而言,主要区别及其效果在于:现有技术在启动前端优化功能后,仍可能因为浏览器的兼容问题造成网页显示不正常,甚至无法显示,本申请中利用对待加载页面在用户终端上是否加载出错的检测,通过返回原始的页面加载清单,暂时绕过优化后的加载清单,使得用户终端可以根据原始清单请求加载,尽量保证网页正常显示。另外,由于本发明实施方式由内容分发网络实施,创新地改进了行内既定的网站优化模式,既不需要改变用户终端的配置,也不需要改变源站的代码,又不需要改变需访问页面源站的网站构架,实施便捷,可以减少网站拥有者的技术开发时间,给用户终端侧提供更优质的上网体验,便于本发明实施方式的推广。可见,本实施方式使得在优化网页加载的过程中,优化用户体验,且便于推广,同时无需修改源站代码,减少网站拥有者的技术开发时间的。更具体的说,本实施方式通过边缘服务器插入JS脚本,监测页面完整性,当出现报错时,进行URL跳转重新向边缘服务器获取不使用JS优化功能的页面。
本发明的第二实施方式涉及一种网页加载方法。第二实施方式和第一实施方式大致相同,主要区别及其效果在于:第一实施方式中利用在原加载清单中增加自动执行的监控脚本,进行页面加载是否出错的判断,而本实施方式中利用对用户终端发来的加载请求计数,进行页面加载是否出错的判断。本实施方式通过监控同一加载项的加载请求的次数,简便易行地实现对页面加载出错的检测。
本实施方式中的网页加载方法流程图如图1所示,其中的步骤105在判断待加载页面在用户终端上是否加载出错时,根据在第一预设时间内收到用户终端针对同一加载项的加载请求的次数,判断待加载页面在用户终端上是否加载出错。
由于用户终端侧在页面加载出错时,用户可能重复发出加载请求,所以如果短时间内多次收到同一用户终端针对同一加载项的加载请求,即可判定为用户终端侧加载出错。
具体的说,在收到的重复加载请求在达到第一预设次数时,判定为加载出错,其中,第一预设次数可以是两次,那么边缘服务器在收到两次重复的加载请求后,即向用户终端反馈原加载清单,使得用户终端可以尽快忽略优化后的加载清单,利用原始加载清单请求各项资源,也使得用户可以尽快查看到正常的页面,增加用户体验。
可见,本实施方式限定判断待加载页面在用户终端上是否加载出错的具体方法,具体通过统计收到的重复加载请求来判断,使得判断过程简单可行。另外,进一步限定重复加载请求的阈值,使得待加载页面可以尽快被加载,用户终端浏览器尽快脱离白屏界面,为用户提供更优的访问体验。
值得一提的是,本实施方式中采用的页面加载出错的判断方法可以和第一实施方式中的页面加载出错的判断方法结合使用,在此不再赘述。
本发明的第三实施方式涉及一种网页加载方法。第三实施方式是在第一实施方式的基础上做了进一步改进,主要改进之处在于:在本发明第三实施方式中,新增告警机制,使得在暂时绕开前端优化机制后,将可能出错的情况进行上报,以便管理员更好地筛查排错。
本实施方式中的网页加载方法流程图如图2所示,具体如下:
本实施方式中的步骤201至206与第一实施方式中的步骤101至106相类似,在此不再赘述。
步骤207,记录针对待加载页面的一次报错,累计出报错总数。
也就是说,在记录报错后,监测针对加载项的报错次数。
步骤208,判断报错次数是否达到第二预设次数;若达到,则执行步骤209;若未达到,则返回步骤208。
具体的说,第二预设次数可以是五次,在此不做限定。
步骤209,向待加载页面所属管理员发送针对加载项的告警信息。
具体的说,步骤207至步骤209中,边缘服务器可以统计报错次数,一旦报错次数过多(如报错次数达到第二预设次数),则可基本确认是前端优化功能异常,随后向待加载页面所属管理员发送针对加载项的告警信息,告警信息可以通过邮件形式发送给管理员终端。
实际应用中多个用户终端可能从一个边缘服务器处请求待加载页面,所以该边缘服务器可能收到来自不同用户终端的报错,由于页面的加载出错可能由于前端优化功能的兼容问题,所以,一旦由于这样的问题造成加载出错,就可能影响不止一个用户终端,所以在监测报错次数时,可以累加多个用户终端的报错次数。
在此需要说明的是,在向管理员发送告警信息后,可以根据需要选择多种机制进行进一步操作。
其一,将针对加载项的报错次数清零,清零后返回执行步骤208。也就是说,在报错次数每达到第二预设次数后,向管理员告警。此后的进一步机制可以是在向管理员告警两次后,则直接关闭前端优化功能,避免短时反复告警。实际应用中,其告警流程示意图可以如图4 所示。
其二,在发出告警信息时,暂停前端优化功能,且暂停持续预设时长,在预设时长达到后,恢复启用前端优化功能。其中的预设时长可以设置5-10分钟,利用暂停前端优化功能,避免重复报错,短时反复告警产生的邮件风暴。预设时长达到后,重启前端优化功能,如果该功能没有被关闭,那么将恢复告警机制。实际应用中,其告警流程示意图可以如图5所示。
其三,在发出告警信息后,直接关闭前端优化功能。等待管理员对告警信息的错误排查,如果确定不是由前端优化功能引起,则后续可以再行开启前端优化功能。实际应用中,其告警流程示意图可以如图6所示。
总的来说,以上三种机制可以根据需要择一执行,或设置一定机制结合执行,在此不再赘述。
可见,本实施方式新增告警机制,使得在暂时绕开前端优化机制后,将可能出错的情况进行上报,以便管理员更好地筛查排错。加载项记录报错次数,在报错次数过多时,即可认为是前端优化功能出现问题,所以需要进一步上报管理员,自动检测上报机制在保证页面被正常加载的同时,大大减少人力。同时,提供三种机制,暂停或关闭前端优化功能,使得短时间内不重复告警,避免管理员处的邮件风暴。
本发明的第四实施方式涉及一种网页加载方法。第四实施方式是在第一实施方式的基础上做了进一步改进,主要改进之处在于:在本发明第四实施方式中,增加了cookies记录信息的检测,自动判断发送原始加载清单或优化后的加载清单,边缘服务器可以尽快发送适用于用户终端的加载清单,加快整体加载速度。
本实施方式中的网页加载方法流程图如图3所示,具体如下:
本实施方式中的步骤301和302与第一实施方式中的步骤101和102相类似,在此不再赘述。
步骤303,判断是否需要优化原加载清单;若判定为是,则执行步骤304;若判定为否,则执行步骤307。
具体的说,本步骤中具体根据页面加载请求中携带的cookies记录信息判断,当cookies中显示之前该用户终端由于加载出错接收过原始加载清单,那么这次直接将原加载清单发送至该用户终端,不再执行加载清单的优化等步骤。
本实施方式中的步骤304和307与第一实施方式中的步骤103和106相类似,在此不再赘述。
可见,本实施方式利用cookies记录信息确定所反馈的加载清单为哪种加载清单,便于后 续后快获取到合适的加载清单,加快加载项的加载速度,进一步加快网页的访问速度。
本发明第五实施方式涉及一种服务器,如图7所示,包括:
至少一个处理器;以及,与至少一个处理器通信连接的存储器;其中,存储器存储有可被至少一个处理器执行的指令,指令被至少一个处理器执行,以使至少一个处理器能够执行如第一实施方式至第四实施方式中任一个网页加载方法。其中,存储器和处理器采用总线方式连接,总线可以包括任意数量的互联的总线和桥,总线将一个或多个处理器和存储器的各种电路连接在一起。总线还可以将诸如外围设备、稳压器和功率管理电路等之类的各种其他电路连接在一起,这些都是本领域所公知的,因此,本文不再对其进行进一步描述。总线接口在总线和收发机之间提供接口。收发机可以是一个元件,也可以是多个元件,比如多个接收器和发送器,提供用于在传输介质上与各种其他装置通信的单元。经处理器处理的数据通过天线在无线介质上进行传输,进一步,天线还接收数据并将数据传送给处理器。
处理器负责管理总线和通常的处理,还可以提供各种功能,包括定时,外围接口,电压调节、电源管理以及其他控制功能。而存储器可以被用于存储处理器在执行操作时所使用的数据。
本发明第六实施方式涉及一种网页加载系统,如图8所示,具体包括:用户终端和如第五实施方式中提到的服务器,其中的服务器可以是CDN架构下的边缘服务器。实际应用中,本实施方式中的网页加载系统还可以包括待加载网页所属的源站服务器。
本发明第七实施方式涉及一种计算机可读存储介质,存储有计算机程序。计算机程序被处理器执行时实现上述方法实施例。
即,本领域技术人员可以理解,实现上述实施例方法中的全部或部分步骤是可以通过程序来指令相关的硬件来完成,该程序存储在一个存储介质中,包括若干指令用以使得一个设备(可以是单片机,芯片等)或处理器(processor)执行本申请各个实施例方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、磁碟或者光盘等各种可以存储程序代码的介质。
本领域的普通技术人员可以理解,上述各实施方式是实现本发明的具体实施例,而在实际应用中,可以在形式上和细节上对其作各种改变,而不偏离本发明的精神和范围。

Claims (17)

  1. 一种网页加载方法,其特征在于,应用于内容分发网络的边缘服务器,包括:
    在启用前端优化功能后,根据来自用户终端的页面加载请求,获取待加载页面的原加载清单;
    优化所述原加载清单,获得优化后的加载清单;
    向所述用户终端发送所述优化后的加载清单;
    判断所述待加载页面在所述用户终端上是否加载出错;
    若判定加载出错,则向所述用户终端发送所述原加载清单。
  2. 根据权利要求1所述的网页加载方法,其特征在于,所述优化原加载清单,具体包括:将监控脚本添加至所述原加载清单;
    所述判断待加载页面在所述用户终端上是否加载出错,具体为:
    利用所述监控脚本,判断所述待加载页面在所述用户终端上是否加载出错。
  3. 根据权利要求2所述的网页加载方法,其特征在于,所述监控脚本用于在检测到所述待加载页面加载出错时,向所述边缘服务器发送加载出错报告;
    所述判断待加载页面在所述用户终端上是否加载出错,具体包括:在收到来自所述监控脚本的加载出错报告时,判定为所述待加载页面在所述用户终端上加载出错。
  4. 根据权利要求2所述的网页加载方法,其特征在于,所述加载出错包括所述待加载页面显示不完整。
  5. 根据权利要求1所述的网页加载方法,其特征在于,所述判断待加载页面在所述用户终端上是否加载出错,具体为:
    根据在所述第一预设时间内收到所述用户终端针对同一加载项的加载请求的次数,判断所述待加载页面在所述用户终端上是否加载出错。
  6. 根据权利要求5所述的网页加载方法,其特征在于,所述根据在第一预设时间内收到所述用户终端针对同一加载项的加载请求的次数,判断所述待加载页面在所述用户终端上是否加载出错,具体包括:
    若在所述第一预设时间内收到所述用户终端针对同一加载项的加载请求的次数达到第一预设次数时,则判定为所述待加载页面在所述用户终端上加载出错。
  7. 根据权利要求6所述的网页加载方法,其特征在于,所述第一预设次数为两次。
  8. 根据权利要求1所述的网页加载方法,其特征在于,还包括:
    在向所述用户终端发送所述原加载清单时,记录针对所报错的加载项的一次报错;
    监测针对加载项的报错次数;
    若所述报错次数达到第二预设次数,则向所述待加载页面所属管理员发送针对所述加载项的告警信息,所述第二预设次数大于所述第一预设次数。
  9. 根据权利要求8所述的网页加载方法,其特征在于,所述向网页所属管理员发送针对所述加载项的告警信息后,还包括:
    将针对加载项的报错次数清零;
    继续执行所述监测针对所述加载项的报错次数。
  10. 根据权利要求8所述的网页加载方法,其特征在于,还包括:
    在向所述待加载页面所属管理员发送针对所述加载项的告警信息时,暂停所述前端优化功能。
  11. 根据权利要求10所述的网页加载方法,其特征在于,所述暂停前端优化功能后,还包括:暂停所述前端优化功能持续预设时长后,恢复启用所述前端优化功能。
  12. 根据权利要求8所述的网页加载方法,其特征在于,还包括:
    在向所述待加载页面所属管理员发送针对所述加载项的告警信息时,关闭所述前端优化功能。
  13. 根据权利要求1所述的网页加载方法,其特征在于,所述优化原加载清单具体包括:
    根据预定的优化方案改写所述加载清单中的所述待加速资源。
  14. 根据权利要求1所述的网页加载方法,其特征在于,在所述获取待加载页面的原加载清单之后,在所述优化原加载清单之前,还包括:
    根据所述页面加载请求中携带的cookies记录信息,判断是否需要优化所述原加载清单;
    若判定为需要,则执行所述优化原加载清单的步骤;
    若判定为不需要,则执行所述向所述用户终端发送所述原加载清单的步骤。
  15. 一种服务器,其特征在于,包括:
    至少一个处理器;以及,
    与所述至少一个处理器通信连接的存储器;其中,
    所述存储器存储有可被所述至少一个处理器执行的指令,所述指令被所述至少一个处理器执行,以使所述至少一个处理器能够执行如权利要求1至14中任一项所述的网页加载方法。
  16. 一种网页加载系统,其特征在于,包括:用户终端和如权利要求15所述的服务器。
  17. 一种计算机可读存储介质,存储有计算机程序,其特征在于,所述计算机程序被处 理器执行时实现权利要求1至14中任一项所述的网页加载方法。
PCT/CN2018/086186 2018-04-25 2018-05-09 一种网页加载方法、网页加载系统和服务器 WO2019205192A1 (zh)

Priority Applications (2)

Application Number Priority Date Filing Date Title
US16/099,335 US20200319954A1 (en) 2018-04-25 2018-05-09 Webpage loading method, webpage loading system and server
EP18906706.9A EP3584669B1 (en) 2018-04-25 2018-05-09 Webpage loading method, webpage loading system, and server

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201810380726.0A CN108804515B (zh) 2018-04-25 2018-04-25 一种网页加载方法、网页加载系统和服务器
CN201810380726.0 2018-04-25

Publications (1)

Publication Number Publication Date
WO2019205192A1 true WO2019205192A1 (zh) 2019-10-31

Family

ID=64092988

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2018/086186 WO2019205192A1 (zh) 2018-04-25 2018-05-09 一种网页加载方法、网页加载系统和服务器

Country Status (4)

Country Link
US (1) US20200319954A1 (zh)
EP (1) EP3584669B1 (zh)
CN (1) CN108804515B (zh)
WO (1) WO2019205192A1 (zh)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112434235A (zh) * 2020-11-06 2021-03-02 金蝶云科技有限公司 网页图片加载方法、装置、计算机设备和存储介质
CN113377563A (zh) * 2021-06-01 2021-09-10 北京齐尔布莱特科技有限公司 一种网页监控方法及计算设备
CN112434235B (zh) * 2020-11-06 2024-06-04 金蝶云科技有限公司 网页图片加载方法、装置、计算机设备和存储介质

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112989241A (zh) * 2021-03-23 2021-06-18 浪潮云信息技术股份公司 一种基于Web前端网站的显示优化方法及系统
CN113301148B (zh) * 2021-05-21 2022-10-28 北京达佳互联信息技术有限公司 页面显示方法、装置、服务器、终端及存储介质
CN114996765A (zh) * 2022-08-01 2022-09-02 广州市千钧网络科技有限公司 一种基于JavaScript的页面控制方法、装置及电子设备

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2012014209A2 (en) * 2010-07-29 2012-02-02 Infogin Ltd. Internet communication system and method
CN102546774A (zh) * 2011-12-27 2012-07-04 厦门市美亚柏科信息股份有限公司 一种二次重定向的cdn路由方法及系统
CN103631905A (zh) * 2013-11-22 2014-03-12 北京奇虎科技有限公司 一种网页的加载方法和浏览器
CN104754073A (zh) * 2015-03-25 2015-07-01 百度在线网络技术(北京)有限公司 一种资源访问方法及装置
CN106341417A (zh) * 2016-09-30 2017-01-18 贵州白山云科技有限公司 一种基于内容分发网络的https加速方法和系统

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9906620B2 (en) * 2008-05-05 2018-02-27 Radware, Ltd. Extensible, asynchronous, centralized analysis and optimization of server responses to client requests
US9830401B2 (en) * 2013-05-16 2017-11-28 Google Llc Automatically selecting optimization filters for optimizing webpages
CN104182547A (zh) * 2014-09-10 2014-12-03 北京浩瀚深度信息技术股份有限公司 一种服务器优化页面渲染的方法及web cache服务器
US9178934B1 (en) * 2014-11-21 2015-11-03 Instart Logic, Inc. Modifying web content at a client
CN105335485A (zh) * 2015-10-15 2016-02-17 桂林电子科技大学 一种网页加载方法及网页加载装置

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2012014209A2 (en) * 2010-07-29 2012-02-02 Infogin Ltd. Internet communication system and method
CN102546774A (zh) * 2011-12-27 2012-07-04 厦门市美亚柏科信息股份有限公司 一种二次重定向的cdn路由方法及系统
CN103631905A (zh) * 2013-11-22 2014-03-12 北京奇虎科技有限公司 一种网页的加载方法和浏览器
CN104754073A (zh) * 2015-03-25 2015-07-01 百度在线网络技术(北京)有限公司 一种资源访问方法及装置
CN106341417A (zh) * 2016-09-30 2017-01-18 贵州白山云科技有限公司 一种基于内容分发网络的https加速方法和系统

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112434235A (zh) * 2020-11-06 2021-03-02 金蝶云科技有限公司 网页图片加载方法、装置、计算机设备和存储介质
CN112434235B (zh) * 2020-11-06 2024-06-04 金蝶云科技有限公司 网页图片加载方法、装置、计算机设备和存储介质
CN113377563A (zh) * 2021-06-01 2021-09-10 北京齐尔布莱特科技有限公司 一种网页监控方法及计算设备
CN113377563B (zh) * 2021-06-01 2024-02-23 北京齐尔布莱特科技有限公司 一种网页监控方法及计算设备

Also Published As

Publication number Publication date
EP3584669A1 (en) 2019-12-25
EP3584669B1 (en) 2023-09-20
US20200319954A1 (en) 2020-10-08
CN108804515A (zh) 2018-11-13
CN108804515B (zh) 2021-05-28
EP3584669A4 (en) 2020-07-15

Similar Documents

Publication Publication Date Title
US11016749B1 (en) Architecture for incremental deployment
US11032388B2 (en) Methods for prerendering and methods for managing and configuring prerendering operations
CN109073350B (zh) 应用性能数据的预测性汇总和缓存
WO2019205192A1 (zh) 一种网页加载方法、网页加载系统和服务器
WO2019205203A1 (zh) 一种网页加载方法、服务器和网页加载系统
US8745212B2 (en) Access to network content
US10007656B2 (en) DOM snapshot capture
US8589537B2 (en) Methods and computer program products for aggregating network application performance metrics by process pool
US9769285B2 (en) Access to network content
WO2019205191A1 (zh) 一种网页加载方法、网页加载系统和服务器
US10108987B2 (en) E-mail based dynamic advertising
US9229740B1 (en) Cache-assisted upload proxy
WO2014152078A1 (en) Application architecture supporting multiple services and caching
US20190303870A1 (en) Service for receiving obsolete web page copies
WO2016202206A1 (zh) 一种超文本传输请求的补发方法、装置及客户端
US8312138B2 (en) Methods and computer program products for identifying and monitoring related business application processes
WO2015195407A1 (en) Method and apparatus for monitoring and determining page load times
CN108549584B (zh) 一种服务端灰度降级方法和装置
US11288336B2 (en) Systems and methods for providing content items in situations involving suboptimal network conditions
US20240103992A1 (en) Alert rule manipulation in sync of temporary configuration change
US20230140084A1 (en) Remote system health monitoring

Legal Events

Date Code Title Description
ENP Entry into the national phase

Ref document number: 2018906706

Country of ref document: EP

Effective date: 20190826

121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 18906706

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE