Response method of content delivery network

By determining the back-intermediate layer strategy in the edge server cluster of CDN based on multiple analysis results and selecting the appropriate intermediate server cluster, the problem of slow CDN acceleration response is solved and more efficient file transfer and user experience is achieved.

CN119788658AActive Publication Date: 2025-04-08CHINA TELECOM CLOUD TECH CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202411664604.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-20
Publication Date
2025-04-08
Estimated Expiration
2044-11-20

AI Technical Summary

Technical Problem

There are problems with the response speed of existing content distribution networks (CDNs), especially when using the same set of service templates for different types of customers, the response speed after CDN acceleration may be slower than directly accessing the source site.

Method used

By obtaining file pull requests in the edge server cluster, and determining the most suitable back-to-middle-layer strategy based on address analysis results, performance loss results and full-link detection results, selecting the target intermediate server cluster, thereby optimizing the file pull process.

Benefits of technology

The response speed after CDN acceleration is significantly optimized, avoiding the problem of slower response speed than direct access to the source site, and improving the user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119788658A_ABST
    Figure CN119788658A_ABST
Patent Text Reader

Abstract

The invention provides a response method of a content distribution network, and aims to solve the problem that a service template cannot be flexibly adjusted in the related technology. The method comprises the steps of obtaining a first file pulling request; under the condition of determining that a target file pulled by the first file pulling request is not cached, determining a target intermediate layer returning strategy of the first file pulling request according to an address analysis result, a performance loss result and a full link detection result, the intermediate layer returning strategy comprises a proximity principle strategy, a consistent Hash algorithm strategy and a specified intermediate cluster strategy; determining a target intermediate server cluster according to the target intermediate layer returning strategy, and sending a second file pulling request to the target intermediate server cluster; and receiving the target file pulled from the source station by the target intermediate server cluster.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the technical field of content distribution networks, and in particular to a response method of a content distribution network. Background Art

[0002] Content Delivery Network (CDN) vendors provide services to a variety of customer channels. Based on the business characteristics of customers, customers can be divided into two categories: one is provincial customers, whose users and source stations are in the same province; the other is national customers, whose users are spread across the province and whose source stations are in a certain province. According to the conventional practice of various CDN vendors, no matter which type of customer newly connects to a CDN vendor, the service template used is the same; that is, each province has an edge cluster to respond to users. If the edge cluster has no cache, it will request and pull files from the source to the intermediate cluster in different provinces through a consistent hashing algorithm.

[0003] However, if the same service template is used for different types of customers, there will be a problem that the response speed after CDN acceleration is slower than the response speed of directly accessing the source station. When customers complain about this problem, CDN manufacturers will adjust the customer's service template. Summary of the invention

[0004] In order to overcome the problems existing in the related art, the present disclosure provides a response method of a content distribution network. The technical solution of the present disclosure is as follows: According to a first aspect of an embodiment of the present disclosure, a response method of a content distribution network is provided, which is applied to an edge server cluster, and includes: Get the first file pull request; When it is determined that the target file pulled by the first file pull request is not cached, a target return to the middle layer strategy of the first file pull request is determined according to the address analysis result, the performance loss result and the full link detection result, and the return to the middle layer strategy includes: the proximity principle strategy, the consistent hash algorithm strategy and the designated middle cluster strategy; Determine a target intermediate server cluster according to the target back to the intermediate layer strategy, and send a second file pull request to the target intermediate server cluster; Receive the target file pulled by the target intermediate server cluster from the source station.

[0005] Optionally, determining a target return strategy of the first file pull request to the middle layer according to the address analysis result, the performance loss result, and the full-link detection result includes: Obtain address analysis results from the data analysis platform; According to the address analysis result, determining whether the target service corresponding to the first file pull request is a first service; the first service indicates that the source station and the user of the target service are located in the same area; In the case where the target back to the middle layer strategy is a designated middle cluster strategy, determining the target middle server cluster according to the target back to the middle layer strategy includes: When the target service corresponding to the first file pull request is the first service, the intermediate server cluster located in the same area as the target service is determined as the target intermediate server cluster through the designated intermediate cluster strategy.

[0006] Optionally, when the target back to the intermediate layer strategy is a proximity principle strategy and the target capacity of the target file is less than or equal to the first capacity, determining a target intermediate server cluster according to the target back to the intermediate layer strategy, and sending a second file pull request to the target intermediate server cluster, includes: According to the proximity principle, the intermediate server cluster closest to the edge server cluster is determined as the target intermediate server cluster; A second file pull request for the target file is initiated to the target intermediate server cluster to receive the target file pulled by the target intermediate server cluster from the source station.

[0007] Optionally, when the target back to the intermediate layer strategy is a proximity principle strategy and the target capacity of the target file is greater than the first capacity, determining a target intermediate server cluster according to the target back to the intermediate layer strategy, and sending a second file pull request to the target intermediate server cluster, includes: By using the proximity principle, the intermediate server cluster closest to the edge server cluster is determined as the first target intermediate server cluster; by using the consistent hashing algorithm, the second target intermediate server cluster corresponding to the first file pull request is determined; Determine a first capacity of the target file as a first file, and determine the remaining capacity of the target file except the first capacity as a second file; Initiate a second file pull request for the first file to the first target intermediate server cluster to obtain the first file pulled by the first target intermediate server cluster from the source station; A second file pull request for the second file is initiated to the second target intermediate server cluster to obtain the second file pulled by the second target intermediate server cluster from the source station.

[0008] Optionally, the full-link detection result is determined by the following steps: Detect each intermediate server cluster to obtain a first detection result; receiving second detection results transmitted by each intermediate server cluster; A full-link detection result is obtained through the first detection result and the second detection result.

[0009] Optionally, the performance loss result is determined by the following steps: Collecting domain name service information required by the performance loss model; the domain name service information includes: the average requested file size of each historical first file pull request and the number of each historical first file pull request; Analyze domain name service information based on the performance loss model to obtain the middle layer processor loss and bandwidth consumption; The mid-tier processor loss and the bandwidth consumption are determined as the performance loss result.

[0010] According to a second aspect of an embodiment of the present disclosure, a response method of a content distribution network is provided, which is applied to an intermediate server cluster, and includes: Receiving a second file pull request sent from the edge server cluster, and acquiring a target file from the source station according to the second file pull request; the second file pull request is determined by a proximity principle strategy, a consistent hashing algorithm strategy, or a designated intermediate cluster strategy; The target file is transmitted to the edge server cluster.

[0011] Optionally, in the case where the second file pull request is determined by the proximity principle policy and the target capacity of the target file is greater than the first capacity, the intermediate server cluster includes: a first target intermediate server cluster and a first target intermediate server cluster; Receiving a second file pull request sent from the edge server cluster, and obtaining a target file from the source station according to the second file pull request, including The first target intermediate server cluster receives a second file pull request for the first file, where the first file is a file corresponding to a first previous capacity of the target file; Obtain the first file from the source station according to the second file pull request, and transmit the first file to the second target intermediate server cluster so that the second target intermediate server cluster caches the first file; The second target intermediate server cluster receives a second file pull request for the second file, where the second file is a file corresponding to the remaining capacity of the target file except the first capacity; The second file is obtained from the source site according to the second file pull request, and the second file is cached.

[0012] Optionally, it also includes: Detect each source station to obtain a second detection result; The second detection result is transmitted to each of the edge server clusters.

[0013] According to a third aspect of an embodiment of the present disclosure, a response method of a content distribution network is provided, which is applied to a data analysis platform, and includes: Parsing each historical first file pull request, and determining user region information corresponding to each historical first file pull request according to the user address corresponding to each historical first file pull request; Determine source station region information corresponding to each of the historical first file pull requests according to the source station addresses corresponding to each of the historical first file pull requests; Matching the user region information and the source station region information respectively corresponding to each of the historical first file pull requests, and determining a target overlap rate of a target service corresponding to the first file pull request received by the edge server cluster; According to the relationship between the target overlap rate and the first threshold, an address analysis result is obtained, wherein the address analysis result at least includes that the target service is a first service, and the first service indicates that a source station and a user of the target service are located in the same area; The address analysis result is sent to the edge server cluster.

[0014] According to a fourth aspect of an embodiment of the present disclosure, an electronic device is provided, comprising: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the computer program is executed by the processor, the steps of the content distribution network response method described in the first aspect, or the steps of the content distribution network response method described in the second aspect, or the steps of the content distribution network response method described in the third aspect are implemented.

[0015] According to a fifth aspect of an embodiment of the present disclosure, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps of the response method of the content distribution network described in the first aspect, or the steps of the response method of the content distribution network described in the second aspect, or the steps of the response method of the content distribution network described in the third aspect are implemented.

[0016] According to a sixth aspect of an embodiment of the present disclosure, a computer program product is provided, comprising a computer program. When the computer program is executed by a processor, the computer program implements the steps of the response method of the content distribution network as described in the first aspect, or the steps of the response method of the content distribution network as described in the second aspect, or the steps of the response method of the content distribution network as described in the third aspect.

[0017] The present disclosure selects the most appropriate return-to-middle-layer strategy based on the specific circumstances of the file pull request, including address analysis results, performance loss results, and full-link detection results, which can significantly optimize the response speed after CDN acceleration and avoid the problem of the response speed being slower than directly accessing the source station. The present disclosure supports multiple return-to-middle-layer strategies and can flexibly select and adjust the return-to-middle-layer strategies according to actual business needs, which can easily expand more return-to-middle-layer strategies, thereby optimizing the response speed of CDN acceleration. BRIEF DESCRIPTION OF THE DRAWINGS

[0018] In order to more clearly illustrate the technical solutions of the embodiments of the present disclosure, the drawings required for use in the description of the embodiments of the present disclosure will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments of the present disclosure. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0019] Figure 1 It is a schematic diagram of steps of a content distribution network response method shown in an embodiment of the present disclosure; Figure 2 is a schematic diagram of determining a performance loss result shown in an embodiment of the present disclosure; Figure 3 This is a machine learning SVM-related code demo and classification result comparison diagram shown in the embodiment of the present disclosure; Figure 4 is a schematic diagram of a strategy for determining a target back to the middle layer shown in an embodiment of the present disclosure; Figure 5 It is a schematic diagram of steps of a content distribution network response method shown in an embodiment of the present disclosure; Figure 6 is a schematic diagram of an intermediate server cluster obtaining a target file from a source station according to an embodiment of the present disclosure; Figure 7 It is a schematic diagram of steps of a content distribution network response method shown in an embodiment of the present disclosure; Figure 8 is a schematic diagram of determining an address analysis result shown in an embodiment of the present disclosure; Fig. 9 is a schematic diagram of an overall access architecture diagram shown in an embodiment of the present disclosure; Fig.10 It is a schematic diagram of an electronic device shown in an embodiment of the present disclosure. DETAILED DESCRIPTION

[0020] The following will be combined with the drawings in the embodiments of the present disclosure to clearly and completely describe the technical solutions in the embodiments of the present disclosure. Obviously, the described embodiments are part of the embodiments of the present disclosure, rather than all of the embodiments. Based on the embodiments in the present disclosure, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present disclosure.

[0021] The terms "first", "second", etc. in the specification and claims of the present disclosure are used to distinguish similar objects, and are not used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable when appropriate, so that the embodiments of the present disclosure can be implemented in an order other than those illustrated or described herein, and the objects distinguished by "first", "second", etc. are generally of the same type, and the number of objects is not limited. For example, the first object can be one or more. In addition, "and / or" in the specification and claims represents at least one of the connected objects, and the character " / " generally indicates that the objects associated with each other are in an "or" relationship.

[0022] For ease of understanding, the professional terms involved in the present disclosure are first explained.

[0023] SVM (support vector machine): is a binary classification model. Its basic model is a linear classifier with the largest margin defined in the feature space. The largest margin makes it different from the perceptron. SVM also includes kernel techniques, which makes it a nonlinear classifier in essence. The learning strategy of SVM is to maximize the margin, which can be formalized as a problem of solving a convex quadratic programming, which is equivalent to the problem of minimizing the regularized hinge loss function. The learning algorithm of SVM is the optimization algorithm for solving convex quadratic programming.

[0024] CDN: It is a distributed content distribution network built on a data network. The role of CDN is to use streaming media server cluster technology to overcome the shortcomings of insufficient output bandwidth and concurrent capabilities of a single-machine system, which can greatly increase the number of concurrent streams supported by the system and reduce or avoid the adverse effects of single point failures.

[0025] CDN vendors serve customers from a variety of sources, with different business characteristics. In order to improve the efficiency of customer service, each vendor will pay more attention to customers with larger bandwidth, which brings the disadvantage that small and medium-sized customers cannot be well compatible and served. The main concern of customers is the response speed of CDN acceleration. Among them, based on the business characteristics of customers, customers can be divided into two categories: one is provincial customers, that is, the customer's users and source stations are in the same province; the other is national customers, that is, the customer's users are spread across the province, and the source station is in a certain province.

[0026] According to common practice in the industry, no matter which type of customer newly connects to a CDN vendor, the service template used is the same, that is, each province has an edge cluster to respond to users. If the edge cluster has no cache, it will use the consistent hashing algorithm to request and retrieve files from the intermediate cluster in different provinces. The advantage of this solution is that a file is only returned to the source once, but the disadvantage is that the user may be in the northwest province, the parent layer is in the northeast province, and the source station is in the northwest province, causing the user to accelerate through the CDN slower than directly accessing the source station. Only when customers complain about this will the service template be adjusted, leaving only the parent layer in the same province for service.

[0027] In addition, most current CDN vendors have mature dynamic acceleration algorithms, but no mature algorithms have been proposed for static files that need to be cached. The main difference between static files and dynamic files is that dynamic files are usually very small files, have high QPS, are not cached, and have high CPU (Central Processing Unit) consumption, while static files can be small or large, need to be cached, and involve disks. If both static and dynamic files are accelerated dynamically, the need for static file caching cannot be met, bandwidth will be wasted, and machine performance may not be met.

[0028] In order to solve the above technical problems, the present disclosure proposes a response method of a content distribution network, which is applied to the response system of the content distribution network. The method can determine the strategy of returning to the middle layer according to the specific file pull request to avoid the problem that the acceleration through CDN is slower than directly accessing the source station.

[0029] The response system of the content distribution network includes an edge server cluster, an intermediate server cluster, and a data analysis platform. The response system of the content distribution network is used to determine the most suitable intermediate server cluster based on the user's first file pull request without caching the target file, and pull the target file corresponding to the first file pull request back to the source through the intermediate server cluster so that the user can obtain the target file. The response system of the content distribution network uses a back-to-middle layer strategy to determine the most suitable intermediate server cluster corresponding to the first file pull request, wherein the back-to-middle layer strategy includes a proximity principle strategy, a consistent hashing algorithm strategy, and a designated intermediate cluster strategy.

[0030] The edge server cluster is used to receive a user's first file pull request, determine a return-to-middle layer strategy based on the first file pull request; determine a target intermediate server cluster corresponding to the first file pull request through the return-to-middle layer strategy; and initiate a second pull request for a target file to the target intermediate server cluster.

[0031] The intermediate server cluster is used to receive the second pull request; pull the target file back to the source according to the second pull request; transmit the target file to the edge server cluster, and cache the target file.

[0032] The data analysis platform is used to determine what type of service provides the target file corresponding to the first file pull request, and the services include provincial customers and national customers.

[0033] Figure 1 FIG. 1 is a schematic diagram of a method for responding to a content distribution network according to an embodiment of the present disclosure. Figure 1 As shown, the method is applied to an edge server cluster and may specifically include the following steps: Step S11: Obtain a first file pull request.

[0034] An edge server cluster, or edge cluster, refers to a group of servers or computing resources deployed at the edge of the network, mainly used to process user requests and provide content delivery services.

[0035] The first file pull request sent by the user is received by a server in the edge server cluster. The first file pull request may be a URL (Uniform Resource Locator). The user can access the corresponding data resource, that is, the target file in the present disclosure, by sending the URL to the edge server cluster.

[0036] Step S12: When it is determined that the target file pulled by the first file pull request is not cached, determine the target return to the middle layer strategy of the first file pull request based on the address analysis results, performance loss results and full-link detection results. The return to the middle layer strategy includes: proximity principle strategy, consistent hashing algorithm strategy and designated intermediate cluster strategy.

[0037] Determine whether the target file corresponding to the URL is cached. The target file can be cached in each edge server cluster and / or each intermediate server cluster. If the target file is not cached in the edge server cluster that receives the URL and each intermediate server cluster, it is determined that the target file is not cached in the system and the target file corresponding to the URL needs to be pulled from the source station.

[0038] When the target file corresponding to the URL needs to be pulled from the source site, the algorithm is used to determine the return-to-middle-layer strategy from the edge server cluster to the middle layer; the return-to-middle-layer strategy is used to determine the target middle server cluster for pulling the target file from the source site.

[0039] The judgment basis includes address analysis results, performance loss results, and full-link detection results. The address analysis results are used to indicate what type of service provides the target file corresponding to the URL. The performance loss results are used to indicate the performance consumed by each intermediate server cluster in the middle layer when forwarding files. The full-link detection results are used to indicate the network delay and network performance of each node in the system.

[0040] The proximity principle is considered from the geographical space. Resources at locations closer to the center point will be preferentially selected. In the present disclosure, the edge server cluster is taken as the center point, and the intermediate server cluster geographically closest to the edge server cluster is determined as the target intermediate server cluster.

[0041] Step S13: Determine a target intermediate server cluster according to the target back to the intermediate layer strategy, and send a second file pull request to the target intermediate server cluster.

[0042] According to the target back to the middle layer strategy, the target intermediate server cluster corresponding to the URL is determined. The edge server cluster initiates a second file pull request for the target file to the target intermediate server cluster, so that the target intermediate server cluster pulls the target file from the source station.

[0043] Step S14: receiving the target file pulled by the target intermediate server cluster from the source station.

[0044] After the target intermediate server cluster pulls the target file from the source station, it transmits the target file to the edge server cluster, so that the edge server cluster can obtain the target file, so that the user can obtain the target file corresponding to the URL by initiating the URL.

[0045] By adopting the embodiments of the present disclosure, when the target file is not cached, the method can intelligently select the optimal strategy to return to the middle layer based on the address analysis results, performance loss results, and full-link detection results, which helps to optimize network traffic and improve the efficiency of file transfer. By selecting a suitable intermediate server cluster for file pulling, it helps to achieve load balancing and avoid the situation where some server clusters are overloaded while other clusters are idle. It can not only improve resource utilization, but also extend the service life of the server cluster. The present disclosure can quickly respond to file pull requests and provide high-quality content distribution services, which can significantly improve the user experience.

[0046] Among them, in an optional embodiment, the target return to the middle layer strategy of the first file pull request is determined according to the address analysis results, the performance loss results and the full-link detection results, including: obtaining the address analysis results from the data analysis platform; judging whether the target service corresponding to the first file pull request is the first service according to the address analysis results; the first service represents that the source station and the user of the target service are located in the same area; when the target return to the middle layer strategy is the specified intermediate cluster strategy, the target intermediate server cluster is determined according to the target return to the middle layer strategy, including: when the target service corresponding to the first file pull request is the first service, through the specified intermediate cluster strategy, the intermediate server cluster located in the same area as the target service is determined as the target intermediate server cluster.

[0047] Different URLs correspond to different data resources. Users can access different services through URLs, including files provided by provincial customers and national customers. The first service can be provincial customers. The source station storing provincial customer files and the users serving provincial customers are located in the same region, which can be at the provincial level.

[0048] According to the address analysis results, it can be determined which type of service provides the file corresponding to the URL initiated by the user to the edge server cluster. When it is determined through the address analysis results that the URL corresponds to the file of a customer in the province, that is, the file of the first service, it is determined that the source station where the target file corresponding to the URL is stored and the user who initiated the URL are located in the same area.

[0049] When the target service corresponding to the URL is the first service, in order to improve the response speed, it is necessary to select an intermediate server cluster located in the same area as the source station. Therefore, the designated intermediate cluster strategy is determined as the target back to the middle layer strategy, and the intermediate server cluster located in the same area as the target service is determined as the target intermediate server cluster.

[0050] By adopting the embodiment of the present disclosure, by obtaining the address analysis result from the data analysis platform, the method can accurately determine whether the target service corresponding to the first file pull request is the first service. When the target service is determined to be the first service, the target intermediate server cluster is geographically closer to the user, which significantly reduces the delay of data transmission, thereby improving the response speed. Due to the improvement of the response speed, the user can obtain the required data resources more quickly, thereby improving the user experience.

[0051] Among them, in an optional embodiment, the full-link detection result is determined by the following steps: detecting each intermediate server cluster to obtain a first detection result; receiving a second detection result transmitted by each intermediate server cluster; and obtaining a full-link detection result through the first detection result and the second detection result.

[0052] RTT (Round Trip Time) is used to evaluate network performance and directly affects the response speed of user requests and the efficiency of data transmission. RTT can be used to determine and select the optimal back-to-origin strategy to improve user access experience.

[0053] The edge server cluster includes a detection module.

[0054] Through the detection module, each edge server cluster will detect each intermediate server cluster to determine the RTT time from each edge server cluster to each intermediate server cluster; and obtain the first detection result through the RTT time from each edge server cluster to each intermediate server cluster.

[0055] Receive the second detection results transmitted by each intermediate server cluster; the second detection results include the RTT time from each intermediate server cluster detecting a large number of domain names to each source station.

[0056] The first detection result and the second detection result are aggregated to obtain a full-link detection result. The full-link detection result can evaluate and analyze the connection performance between each node in the network.

[0057] By using the embodiments of the present disclosure, the full-link detection results are determined by RTT time, and the best path for data transmission can be accurately determined, thereby selecting the optimal back-to-source strategy and improving data transmission efficiency. Based on the real-time full-link detection results, the system can automatically adjust service templates and strategies to adapt to changes in network conditions and ensure good service quality under different load and network conditions. By analyzing the full-link detection results, the computing and bandwidth resources of the intermediate cluster can be better allocated and utilized, avoiding resource waste and improving the efficiency of the overall system.

[0058] Among them, in an optional embodiment, the performance loss result is determined by the following steps: collecting domain name business information required by the performance loss model; the domain name business information includes: the average requested file size of each historical first file pull request and the number of each historical first file pull request; analyzing the domain name business information based on the performance loss model to obtain the middle layer processor loss and bandwidth consumption; determining the middle layer processor loss and the bandwidth consumption as the performance loss result.

[0059] The edge server cluster includes a data collection module.

[0060] The domain name business information required by the performance loss model is collected through the data collection module; the domain name business information includes: the average requested file size of each historical first file pull request and the number of each historical first file pull request.

[0061] The data collection module inputs the domain name business information into the performance loss model for analysis, and the performance loss model outputs the middle-layer processor loss and bandwidth consumption. The middle-layer processor loss represents the CPU consumed when the middle server cluster of non-consistent hashing forwards files. The bandwidth consumption represents the bandwidth consumed when the middle server cluster of non-consistent hashing forwards files.

[0062] Based on historical data analysis, the smaller the request file size and the higher the number of requests, the greater the loss of the middle-layer processor; and the bandwidth consumption mainly depends on the product of the average request file size and the number of requests.

[0063] The following formula is the performance loss model formula 1 proposed in this disclosure: Maximum QPS = (RT / CPU Time * Number of CPU cores * CPU utilization) * (1 / RT) Among them, RT stands for response time; CPU Time stands for the time it takes the CPU to execute a task; the number of CPU cores stands for the number of cores of the server CPU, which determines how many threads or tasks can be executed simultaneously; and CPU utilization stands for the percentage of time the CPU is busy processing tasks over a period of time.

[0064] The performance loss model formula 1 can be reversely deduced to roughly obtain the CPU utilization based on the average QPS number. The obtained CPU utilization can be used to represent the CPU loss.

[0065] The following formula is the performance loss model formula 2 proposed in this disclosure: Bandwidth consumption = average request file size * number of requests The bandwidth consumption is determined by the performance loss model formula 2.

[0066] Figure 2 FIG. 1 is a schematic diagram showing a method of determining a performance loss result according to an embodiment of the present disclosure. Figure 2 As shown, the input of the performance loss model is the domain name business information, which includes the average requested file size of each historical first file pull request and the number of each historical first file pull request. After receiving the domain name business information, the performance loss model analyzes the domain name business information to obtain the performance loss result, which includes the middle-layer processor loss and bandwidth consumption.

[0067] When determining the strategy of returning to the middle layer, it is necessary to ensure that bandwidth consumption is controllable and the CPU of the middle layer is used as much as possible without overloading the CPU.

[0068] By adopting the embodiments of the present disclosure, by collecting detailed data of historical first file pull requests, the performance requirements in actual business scenarios can be more accurately reflected. Through the analysis of the performance loss model, potential performance bottlenecks can be predicted and avoided, and the system configuration can be adjusted in advance according to the prediction results to ensure that the system selects an appropriate return to the middle layer strategy.

[0069] As for response speed, web page clients mainly use small files such as dynamic files and images, and the focus is on the speed of file loading. Video clients mainly use medium and large files, and the focus is on the first screen time. The common point between web page clients and video clients is that they are both concerned about whether the first few hundred KB (kilobytes) of the file can be loaded quickly, so you can mainly consider improving the loading speed of the first few hundred KB (kilobytes) of the file.

[0070] The first capacity can be determined by the size of the file that the customer is concerned about and needs to load quickly. The size of the first capacity can be changed accordingly according to the change of user requirements. Capacity indicates the size of the space occupied by the file in the storage medium, indicating how much data the file contains. The capacity of the file can be expressed in kilobytes (KB), megabytes (MB), gigabytes (GB), terabytes (TB), etc.

[0071] The edge server cluster includes an SVM algorithm module and uses SVM classification. The principle of SVM classification is to calculate a hyperplane that can distinguish multiple data. It is a virtual concept that can divide the input data into two groups, namely positive examples and negative examples; the interval of the hyperplane is measured by examples, so that the deviation of the hyperplane can be as small as possible, thereby obtaining the best classification result. Figure 3 It is a machine learning SVM related code demo and classification result comparison chart shown in an embodiment of the present disclosure.

[0072] The input of the SVM algorithm module is the address analysis results, performance loss results, and full-link detection results. Through the machine learning-classification algorithm, the target is output back to the middle layer strategy to achieve the purpose of increasing the first capacity of the target file.

[0073] The SVM algorithm module can determine the target SVM algorithm module corresponding to the URL in the current system environment according to actual needs. For example, when the loss of the middle-layer processor reaches 5% or the bandwidth consumption exceeds 100MB / s, the SVM algorithm module determines that the target return strategy corresponding to the URL at this time adopts the conventional strategy, that is, the consistent hashing algorithm strategy; when the loss of the middle-layer processor is less than 1% and the bandwidth consumption is less than 10MB / s, and the full-link detection result indicates that the RTT time of each middle layer is basically the same, the SVM algorithm module determines that the target return strategy corresponding to the URL at this time adopts the proximity principle strategy.

[0074] In an optional embodiment, in order to ensure that the first capacity of the target file can be quickly loaded, the present disclosure proposes that the target intermediate server cluster can be determined by the proximity principle strategy, and the first capacity of the target file can be pulled from the source station through the target intermediate server cluster; the target intermediate server cluster is the intermediate server cluster closest to the edge server cluster. If the target file is obtained from the source station using the intermediate server cluster closest to the edge server cluster, the intermediate server cluster will not cache the target file, but will transfer the target file to another intermediate server cluster for caching; however, transferring the target file to another intermediate server cluster for caching will consume additional system performance.

[0075] The present disclosure not only improves the response speed of the first capacity of the target file, but also needs to consider the consumption of system performance. Therefore, when the proximity principle strategy is used as the return to the middle layer strategy, there are two situations based on the size relationship between the target capacity of the target file and the first capacity.

[0076] The edge server cluster also includes a back-to-middle layer module, which is used to execute the target back-to-middle layer strategy and send a second file pull request to the target middle server cluster corresponding to the target back-to-middle layer strategy. If the target back-to-middle layer strategy is a proximity principle strategy, then the back-to-middle layer module also needs to determine the target capacity of the target file pulled by the first file pull request, and determine the size relationship between the target capacity of the target file and the first capacity, and based on the size relationship, initiate a second file pull request to the corresponding target middle server cluster. If the target back-to-middle layer strategy is a consistent hashing algorithm strategy or a specified middle cluster strategy, it is not necessary to determine the size relationship between the target capacity of the target file and the first capacity.

[0077] The following is a case where the target capacity of the target file is less than or equal to the first capacity.

[0078] Among them, in an optional embodiment, when the target back to the middle layer strategy is a proximity principle strategy and the target capacity of the target file is less than or equal to the first capacity, the target intermediate server cluster is determined according to the target back to the middle layer strategy, and a second file pull request is sent to the target intermediate server cluster, including: through the proximity principle, the intermediate server cluster closest to the edge server cluster is determined as the target intermediate server cluster; a second file pull request for the target file is initiated to the target intermediate server cluster; and the target file is pulled by the target intermediate server cluster from the source station.

[0079] When the target back-to-middle-layer strategy is the proximity principle strategy, and the back-to-middle-layer module determines that the target capacity of the target file is less than or equal to the first capacity, it means that the target file corresponding to the current URL is the entire loading part that the user pays attention to. The target file is the loading part that the customer pays attention to. If the target file cannot be loaded quickly, the user of the customer service will have a poor experience when using the customer's file.

[0080] Therefore, the intermediate server cluster closest to the edge server is directly determined as the target intermediate server cluster through the proximity principle strategy, and the back-intermediate layer module in the edge server cluster initiates a second file pull request for the entire target file to the target intermediate server cluster. After receiving the second file pull request, the target intermediate server cluster pulls the entire target file from the source station.

[0081] Since the target intermediate server cluster is the intermediate server cluster closest to the edge server, using the target intermediate server cluster to pull files from the source station improves the response speed to the URL.

[0082] By adopting the embodiment of the present disclosure, the intermediate server cluster closest to the edge server is determined as the target intermediate server cluster by adopting the proximity principle strategy, thereby ensuring that the target intermediate server cluster has the shortest path to pull the target file from the source station, reducing the time and delay of data transmission. For web page clients and video clients, since they are concerned about the loading speed of the first capacity before the file, when the target file is less than or equal to the first capacity, the user experience can be significantly improved by optimizing the fast loading of the entire target file.

[0083] The following is a case where the target capacity of the target file is larger than the first capacity.

[0084] Among them, in an optional embodiment, when the target back to the middle layer strategy is the proximity principle strategy and the target capacity of the target file is greater than the first capacity, the target intermediate server cluster is determined according to the target back to the middle layer strategy, and a second file pull request is sent to the target intermediate server cluster, including: through the proximity principle, the intermediate server cluster closest to the edge server cluster is determined as the first target intermediate server cluster; through the consistent hashing algorithm, the second target intermediate server cluster corresponding to the first file pull request is determined; the first capacity of the target file is determined as the first file, and the remaining capacity of the target file except the first capacity is determined as the second file; a second file pull request for the first file is initiated to the first target intermediate server cluster to obtain the first file pulled by the first target intermediate server cluster from the source station; a second file pull request for the second file is initiated to the second target intermediate server cluster to obtain the second file pulled by the second target intermediate server cluster from the source station.

[0085] When the target back to middle layer strategy is the proximity principle strategy, and the back to middle layer module determines that the target capacity of the target file is greater than the first capacity, the target file can be regarded as two parts, one part is the first capacity that the customer focuses on and needs to be loaded quickly, and the second part is the second capacity other than the first capacity. Whether the second capacity is loaded quickly or not is not well perceived by the user when the user uses the resources provided by the customer. Therefore, if the second part of the target file cannot be loaded quickly, it will not reduce the user's experience.

[0086] Therefore, the target file is divided into two parts based on the first capacity, the first capacity is used as the first file, and the remaining part is used as the second file.

[0087] When the target back to the intermediate layer policy is the proximity principle policy and the target capacity of the target file is greater than the first capacity, the target intermediate server cluster includes a first target intermediate server cluster and a second target intermediate server cluster.

[0088] The intermediate server cluster closest to the edge server can be determined as the first target intermediate server cluster by the proximity principle; and the second target intermediate server cluster corresponding to the URL can be determined by the consistent hash algorithm.

[0089] The return middle layer module initiates a second file pull request for the first file to the first target intermediate server cluster, so that the first target intermediate server cluster pulls the first file of the target file from the source station; the edge server cluster obtains the first file of the target file through the first target intermediate server cluster.

[0090] Since the first target intermediate server cluster is the intermediate server cluster closest to the edge server cluster, the first target intermediate server cluster has the shortest path to pull the target file from the source station, reducing the time and delay of data transmission. Therefore, the speed at which the edge server cluster receives the first file also increases, thereby improving the loading speed of the first capacity of the target file.

[0091] The return middle layer module initiates a second file pull request for the second file to the second target intermediate server cluster, so that the second target intermediate server cluster pulls the second file of the target file from the source station; the edge server cluster obtains the second file of the target file through the second target intermediate server cluster.

[0092] The second part of the target file that does not require accelerated response is obtained by the second target intermediate server cluster instead of the first target intermediate server cluster, which reduces the amount of data transmitted from the first target intermediate server cluster to the second target intermediate server cluster, thereby avoiding waste of system resources and preventing excessive waste of internal bandwidth.

[0093] According to the embodiment of the present disclosure, when the size of the target file exceeds the preset first capacity, the target file is divided into two parts for processing, and different intermediate server clusters are selected for pulling. Under the premise of improving the response speed of the first capacity of the file, reasonable allocation of resources is also achieved. Since the second target intermediate server cluster is responsible for pulling the second part of the file, which is not so urgent, the transmission burden of the first target intermediate server cluster is reduced, thereby improving the overall performance and of the system. For the first capacity that users are more concerned about and need to load quickly, the intermediate server cluster closest to the edge server is selected for pulling according to the principle of proximity, which improves the loading speed of this part of the content and optimizes the user experience.

[0094] Figure 4 FIG. 1 is a schematic diagram of a strategy for determining a target back to the middle layer according to an embodiment of the present disclosure. Figure 4As shown, the edge server cluster includes a data acquisition module, a detection module, an SVM algorithm module and a return to the middle layer module. First, the full-link detection result is obtained through the detection module, and the full-link detection result includes a first detection result and a second detection result; the first detection result is obtained by detecting the middle server cluster through the edge server cluster; the second detection result is obtained by receiving the transmission of the middle server cluster. The data acquisition module collects domain name business information, inputs the domain name business information into the performance loss model, and obtains the performance loss result through the performance loss model. The SVM algorithm module receives the full-link detection result, the performance loss result and the address analysis result provided by the data analysis platform, and outputs one of the proximity principle strategy, the consistent hash algorithm strategy and the designated middle cluster strategy as the target return to the middle layer strategy. The return to the middle layer module determines the target middle server cluster corresponding to the target return to the middle layer strategy according to the target return to the middle layer strategy, and sends a second file pull request to the target middle server cluster, so that the target middle server cluster pulls the target file from the source station.

[0095] Based on the same idea, the present disclosure proposes a response method for a content distribution network, which is applied to an intermediate server cluster and can solve the problems existing in the related technologies.

[0096] Figure 5 FIG. 1 is a schematic diagram of a method for responding to a content distribution network according to an embodiment of the present disclosure. Figure 5 As shown, the method is applied to an intermediate server cluster and may specifically include the following steps: Step S51: receiving a second file pull request sent from an edge server cluster, and obtaining a target file from a source station according to the second file pull request; the second file pull request is determined by a proximity principle strategy, a consistent hashing algorithm strategy, or a specified intermediate cluster strategy.

[0097] Step S52: transmitting the target file to the edge server cluster.

[0098] The intermediate server cluster includes a cache module, a detection module and a data transmission module.

[0099] After receiving the second file pull request, the intermediate server cluster performs corresponding operations to pull the target file corresponding to the second file pull request from the source station according to the target return to intermediate layer strategy of the second file pull request. The return to intermediate layer strategy includes the proximity principle strategy, the consistent hash algorithm strategy and the designated intermediate cluster strategy, and one of the proximity principle strategy, the consistent hash algorithm strategy and the designated intermediate cluster strategy is determined as the target return to intermediate layer strategy.

[0100] After the intermediate server cluster obtains the target file, it transmits the target file to the edge server cluster, so that the user can obtain the target file through the URL.

[0101] By adopting the embodiments of the present disclosure, the content distribution process can be managed more efficiently by receiving and processing file pull requests from the edge server cluster through the intermediate server cluster. The application of the proximity principle strategy, the consistent hashing algorithm strategy and the designated intermediate cluster strategy helps to optimize resource allocation and load balancing. By transferring the target file from the source station to the intermediate server cluster, and then from the intermediate server cluster to the edge server cluster, the distance between the user and the required content can be shortened, which helps to reduce latency and improve user experience.

[0102] After pulling the target file from the source site, the intermediate server cluster will cache the target file. When the second file pull request is determined by specifying the intermediate cluster strategy and the consistent hashing algorithm strategy, the intermediate server cluster will store the pulled target file in its own storage medium; when the second file pull request is determined by the proximity principle strategy, the intermediate server cluster will store the pulled target file in another intermediate server cluster.

[0103] The following is an operation performed by the intermediate server cluster after receiving the second file pull request when the second file pull request is determined by the proximity principle strategy.

[0104] Among them, in an optional embodiment, when the second file pull request is determined by the proximity principle strategy and the target capacity of the target file is greater than the first capacity, the intermediate server cluster includes: a first target intermediate server cluster and a first target intermediate server cluster; receiving a second file pull request sent from the edge server cluster, and obtaining the target file from the source station according to the second file pull request, including the first target intermediate server cluster receiving a second file pull request for the first file, the first file is a file corresponding to the first capacity of the target file; obtaining the first file from the source station according to the second file pull request, and transmitting the first file to the second target intermediate server cluster so that the second target intermediate server cluster caches the first file; the second target intermediate server cluster receives a second file pull request for the second file, the second file is a file corresponding to the remaining capacity of the target file except the first capacity; obtaining the second file from the source station according to the second file pull request, and caching the second file.

[0105] In the case that the target capacity of the target file is greater than the first capacity, the edge server cluster will initiate a second file pull request to two target intermediate server clusters, including the first target intermediate server cluster and the second target intermediate server cluster.

[0106] The first target intermediate server cluster is determined based on the proximity principle. The first target intermediate server cluster is the intermediate server cluster closest to the edge server cluster that initiates the second file pull request.

[0107] The second target intermediate server cluster is determined by a consistent hashing algorithm. By using the consistent hashing algorithm, the intermediate server cluster corresponding to the URL sent by the user is determined as the second target intermediate server cluster.

[0108] First, the edge server cluster initiates a second file pull request for the first file to the first target intermediate server cluster. The first file is a file corresponding to the first capacity of the target file. Obtaining the first file through the first target intermediate server cluster can effectively reduce the transmission distance, so that the first capacity of the target file can be loaded at the fastest speed, improving the user experience.

[0109] The first target intermediate server cluster receives a second file pull request for the first file through the data transmission module it includes; after the data transmission module receives the second file pull request for the first file, it pulls the first file from the source station and transmits the first file to the edge server cluster so that the user obtains the first file.

[0110] After acquiring the first file, the data transmission module will also determine whether the intermediate server cluster in which it is located is determined by the consistent hashing algorithm for URL calculation. If it is determined not to be, it will determine which intermediate server cluster is determined by the consistent hashing algorithm for the URL, which is the second target intermediate server cluster in this embodiment. The data transmission module of the first target intermediate server cluster transmits the first file to the data transmission module of the second target intermediate server cluster, and transmits the first file to the cache module of the second target intermediate server cluster through the data transmission module of the second target intermediate server cluster to store the first file.

[0111] Among them, the data transmission module of the first target intermediate server cluster completes the transmission of the first file by initiating an http3 post request to the data transmission module of the second target intermediate server cluster. This is because the intermediate server clusters are all internal clusters and deployed near the backbone network, and the network conditions are good. Using http3 can increase the transmission speed and single link multiplexing, occupy less connections in the intermediate cluster, and prevent affecting normal business.

[0112] For the second file corresponding to the remaining capacity of the target file except the first capacity, since this part of the target file is not the content that the customer focuses on and needs to be loaded quickly. Therefore, the edge server cluster will send a second file pull request to the second target intermediate server cluster to pull the second file, rather than to the first target intermediate server cluster. This is because the first target intermediate server cluster is not the consistent hash intermediate server cluster corresponding to the URL determined by the consistent hashing algorithm, so the first target intermediate server cluster needs to transfer the file it obtains to the consistent hash intermediate server cluster corresponding to the URL, that is, the second target intermediate server cluster in this embodiment; the first target intermediate server cluster transfers the file it obtains to the second target intermediate server cluster, which will consume additional system transmission resources. Therefore, for the content in the target file that is not the focus and needs to be accelerated, the consistent hash intermediate server cluster is used, that is, the second target intermediate server cluster pulls from the source station.

[0113] The second target intermediate server cluster receives the second file pull request for the second file through the cache module included in itself. After the cache module receives the second file pull request for the second file, the second file is pulled from the source station and transmitted to the edge server cluster so that the user can receive the second file. For the second file, the cache module of the second target intermediate server cluster is directly used to cache it.

[0114] The first file is pulled from the source site through the first target intermediate server cluster, and the second file is pulled from the source site through the second target intermediate server cluster. The intermediate server cluster completes obtaining the target file from the source site and transmits both the first file and the second file to the edge server cluster, so that the user obtains the target file corresponding to the URL.

[0115] By adopting the embodiments of the present disclosure, when the target file is large, by dividing it into two parts, the first target intermediate server cluster determined by the proximity principle strategy will prioritize processing and transmitting the first file, which can significantly reduce transmission delays and improve user experience. According to the importance of the file and the user's attention, the resources of the intermediate server cluster are reasonably allocated. The first target intermediate server cluster focuses on quickly transmitting the first file part that the user is concerned about, while the second target intermediate server cluster processes the remaining second file part. By segmenting the target file and caching and transmitting it by different intermediate server clusters, distributed storage and access to file content is achieved, which helps to reduce the storage pressure of a single server and improve the scalability and fault tolerance of the entire system.

[0116] Figure 6 This is a schematic diagram of an intermediate server cluster obtaining a target file from a source station according to an embodiment of the present disclosure. Figure 6As shown, when the target capacity of the target file corresponding to the URL is greater than the first capacity, the intermediate server cluster acquires the target file including steps 1 to 6; when the target capacity of the target file corresponding to the URL is less than or equal to the first capacity, the intermediate server cluster acquires the target file including steps 1 to 4.

[0117] The first stage is a process of obtaining the first file of the first capacity before the target file.

[0118] Step 1: The edge server node initiates a second file pull request for the first file to the first target intermediate server cluster.

[0119] Step 2: The data transmission module of the first target intermediate server cluster receives the second file pull request and pulls the first file from the source station.

[0120] Step 3: After pulling the first file, the data transmission module of the first target intermediate server cluster transmits the first file to the edge server cluster; and uses the http3 post request to transmit the first file to the data transmission module of the second target intermediate server cluster.

[0121] Step 4: After receiving the first file, the data transmission module of the second target intermediate server cluster pages the first file to the cache module of the second target intermediate server cluster to complete the cache of the first file.

[0122] The second stage is a process of obtaining a second file corresponding to the remaining capacity of the target file except the first capacity.

[0123] Step 5: The edge server cluster initiates a second file pull request for the second file to the second target intermediate server cluster.

[0124] Step 6: The cache module of the second target intermediate server cluster receives a second file pull request for the second file, and pulls the second file from the source station; after the cache module pulls the second file, the second file is transmitted to the edge server cluster, and the second file is cached.

[0125] If the target capacity of the target file corresponding to the URL is less than or equal to the first capacity, then the target file is the first file, and only the steps of the first stage are executed to complete the acquisition of the target file by the edge server cluster; if the target capacity of the target file corresponding to the URL is greater than the first capacity, the complete steps of the first and second stages need to be executed to complete the acquisition of the target file by the edge server cluster.

[0126] In an optional embodiment, the method further includes: detecting each source station to obtain a second detection result; and transmitting the second detection result to each edge server cluster.

[0127] Each intermediate server cluster will detect the RTT time from a certain domain name to each source station. By measuring the RTT time, each intermediate cluster can evaluate the network delay between different source stations.

[0128] The obtained RTT times are summarized to obtain the second detection result. The intermediate server cluster transmits the second detection result to each edge server cluster, so that the edge server cluster can obtain the full-link detection result of the system, thereby determining the most appropriate strategy back to the intermediate layer.

[0129] By adopting the embodiments of the present disclosure, through comprehensive detection, the network status between each source station and the intermediate server cluster can be accurately grasped. After receiving this information, the edge server cluster can more accurately evaluate the network delay between different source stations and itself, thereby determining the most appropriate return to the middle layer strategy, which helps to optimize the data routing path and reduce unnecessary network delays and bandwidth consumption.

[0130] The response system of the content distribution network also includes a data analysis platform, which is used to obtain address analysis results.

[0131] Figure 7 The present invention is a step diagram of a response method of a content distribution network shown in an embodiment of the present invention. The method is applied to a data analysis platform, which includes a data analysis module and a service template module. The data analysis module is mainly used to collect user address area information at the URL granularity of the edge server cluster, and collect source station address area information at the URL granularity provided by the configuration platform; the service template module is used to adjust the service template.

[0132] according to Figure 7 As shown, the following steps may be specifically included: Step 71: parsing each historical first file pull request, and determining user region information corresponding to each historical first file pull request according to the user address corresponding to each historical first file pull request.

[0133] The data analysis platform can analyze each historical first file pull request.

[0134] The data analysis platform in the data analysis platform can parse each historical first file pull request and extract the user address corresponding to each historical first file pull request. The user address can represent the user area information of each user, such as the region name, etc., so as to determine the user area information corresponding to each historical first file pull request.

[0135] Step 72: According to the source site addresses corresponding to the respective historical first file pull requests, determine the source site region information corresponding to the respective historical first file pull requests.

[0136] The source station address of each source station can be obtained from the configuration platform. Therefore, the data analysis platform in the data analysis platform can determine the source station address corresponding to each historical first file pull request by obtaining information from the configuration platform. The source station address can represent the source station region information where each source station is located, such as the region name, etc., so that the data analysis platform can determine the source station region information corresponding to each historical first file pull request.

[0137] Step 73: Match the user region information and the source station region information respectively corresponding to each of the historical first file pull requests, and determine a target overlap rate of the target service corresponding to the first file pull request received by the edge server cluster.

[0138] After obtaining the user region information and the source station region information corresponding to each historical first file pull request, the data analysis platform can match the user region information and the source station region information of each historical first file pull request.

[0139] When the user region information of a certain historical first file pull request and the region name represented by the source station region information are consistent, it is determined that the address information of the historical first file pull request overlaps.

[0140] Each historical first file pull request is grouped according to different services, and the historical first file pull requests included in each service are determined. The services include provincial customers and national customers.

[0141] Determine which service provides the target file corresponding to the URL. Determine the various historical first file pull requests included in the target service. Determine whether the address information of each historical first file pull request overlaps, thereby determining the target overlap rate corresponding to the target service. For example, the target service includes 100 URLs, determine the user area information and source station area information corresponding to each URL, and determine whether the address information of each URL overlaps; if the address information of 98 URLs overlaps, then determine that the target overlap rate of the target service is 98%.

[0142] Step 74: obtaining an address analysis result based on a relationship between the target overlap rate and a first threshold, wherein the address analysis result at least includes that the target service is a first service, and the first service indicates that a source station and a user of the target service are located in the same area.

[0143] Get the first threshold. After determining the target overlap rate of the target service, the service template module can provide a service template by comparing the target overlap rate with the first threshold. The service template can be represented as an address analysis result, which can be used to determine the return to the middle layer strategy of the edge server cluster. The address analysis result includes a first service that represents customers within the province, and a second service that represents customers nationwide. The source station for customers within the province and all users of customers within the province are located in the same area, and the source station for customers nationwide and all users of customers nationwide are not located in the same area.

[0144] Specifically, when the target overlap rate is greater than the first threshold, the target service is determined as the first service; when the target overlap rate is less than or equal to the first threshold, the target service is determined as the second service.

[0145] Step 75: Send the address analysis result to the edge server cluster.

[0146] After the address analysis result is obtained, the address analysis result is sent to the edge server cluster, so that the edge server cluster can determine the most appropriate return strategy to the middle layer for the current URL based on the address analysis result.

[0147] By adopting the embodiment of the present disclosure, the user address and the source site address are obtained by parsing the historical first file pull request, and the user area information and the source site area information are determined accordingly. By matching the user area information and the source site area information, the target overlap rate of the target service is calculated. According to the relationship between the target overlap rate and the first threshold, the target service is determined as the first service or the second service. The system can formulate a more appropriate return to the middle layer strategy according to the service type, thereby improving the efficiency and accuracy of content distribution.

[0148] Figure 8 FIG. 1 is a schematic diagram of determining an address analysis result according to an embodiment of the present disclosure. Figure 8As shown, the data analysis module of the data analysis platform can collect the historical URLs received by the edge server cluster, and the data analysis module parses each historical URL to obtain the user area information corresponding to each historical URL; the configuration platform can provide each source station address, based on which the data analysis module can determine the source station area information corresponding to each historical URL; by matching the user area information and source station area information of each historical URL, the target overlap rate of the target service is determined; and the relationship between the target overlap rate and the first threshold is determined. The service template module adjusts the service template and sends the address analysis result corresponding to the service template to the edge server cluster.

[0149] Fig. 9 It is a schematic diagram of an overall access architecture diagram shown in an embodiment of the present disclosure.

[0150] In one case, according to Fig. 9 As shown, edge server cluster 2 receives a URL request initiated by user 2; after determining that there is no cache of the target file corresponding to the URL in the current system, edge server cluster 2 determines the target return to the middle layer strategy corresponding to the URL; when the target return to the middle layer strategy is the proximity principle strategy, it is determined whether the target capacity of the target file corresponding to the URL is greater than the first capacity; if the judgment is yes, the intermediate server cluster 3 is determined as the first target intermediate server cluster through the proximity principle, and the intermediate server cluster 2 is determined as the second target intermediate server cluster through the consistent hashing algorithm.

[0151] Then, execute the step of pulling the target file corresponding to the URL: Step 1: The edge server cluster 2 initiates a file pull request for the first file to the intermediate server cluster 3; Step: Obtain the first file of the target file from the source station through the intermediate server cluster 3; Step 3: After obtaining the first file, the intermediate server cluster 3 transmits the first file to the intermediate server cluster 2 by initiating an http3+post request, and the intermediate server cluster 2 caches the first file; Step 4: The edge server cluster 2 initiates a file pull request for the second file to the intermediate server cluster 2; Step 5: Obtain the second file from the source site through the intermediate server cluster 2; the intermediate server cluster 2 stores the second file.

[0152] The intermediate server cluster 2 completes caching of the target file corresponding to the URL by caching the first file and the second file.

[0153] When the target file corresponding to the URL is cached in the intermediate server cluster 2, if a user in Province A later initiates the same URL to the edge server cluster 1, the user can directly obtain the target file corresponding to the URL from the intermediate server cluster 2 without having to determine the middle-tier strategy again.

[0154] In another case, according to Fig. 9 As shown, edge server cluster 1 receives the user's URL, and after determining that there is no cache of the target file corresponding to the URL in the current system, edge server cluster 1 determines the return to middle layer strategy corresponding to the URL; when it is learned through the data analysis platform that the target file corresponding to the URL is provided by the first service, that is, the customer within the province, the designated intermediate cluster strategy is determined as the target return to middle layer strategy; the intermediate server cluster 1 located in the same area as user 1 and the source station, that is, Province A, is determined as the target intermediate server cluster, and the target file corresponding to the URL is pulled from the source station through intermediate server cluster 1.

[0155] The present disclosure also provides an electronic device, referring to Fig.10 , Fig.10 is a schematic diagram of an electronic device shown in an embodiment of the present disclosure. Fig.10 As shown, the electronic device 1000 includes: a memory 1010 and a processor 1020. The memory 1010 and the processor 1020 are connected via a bus communication. The memory 1010 stores a computer program, which can be run on the processor 1020 to implement the steps in the response method of the content distribution network disclosed in the embodiment of the present disclosure.

[0156] The embodiment of the present disclosure further provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps in the response method of the content distribution network disclosed in the embodiment of the present disclosure are implemented.

[0157] The embodiment of the present disclosure further provides a computer program product, including a computer program. When the computer program is executed by a processor, the steps in the response method of the content distribution network disclosed in the embodiment of the present disclosure are implemented.

[0158] The various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referenced to each other.

[0159] It should be understood by those skilled in the art that the embodiments of the present disclosure may be provided as methods, devices or computer program products. Therefore, the embodiments of the present disclosure may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the embodiments of the present disclosure may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0160] The embodiments of the present disclosure are described with reference to the flowcharts and / or block diagrams of the methods, apparatuses, electronic devices, and computer program products according to the embodiments of the present disclosure. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of the processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing terminal device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing terminal device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0161] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing terminal device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce a manufactured product including an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0162] These computer program instructions can also be loaded onto a computer or other programmable data processing terminal device so that a series of operating steps are executed on the computer or other programmable terminal device to produce a computer-implemented process, thereby providing instructions for executing on the computer or other programmable terminal device to implement the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0163] Although some embodiments of the present disclosure have been described, those skilled in the art may make additional changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiment and all changes and modifications that fall within the scope of the present disclosure.

[0164] The above is a detailed introduction to a content distribution network response method provided by the present disclosure. Specific examples are used in this article to illustrate the principles and implementation methods of the present disclosure. The description of the above embodiments is only used to help understand the method of the present disclosure and its core idea. At the same time, for those skilled in the art, according to the idea of ​​the present disclosure, there will be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as a limitation on the present disclosure.

Claims

1. A response method of a content distribution network, characterized in that: Applicable to edge server clusters, including: Get the first file pull request; When it is determined that the target file pulled by the first file pull request is not cached, a target return to the middle layer strategy of the first file pull request is determined according to the address analysis result, the performance loss result and the full link detection result, and the return to the middle layer strategy includes: the proximity principle strategy, the consistent hash algorithm strategy and the designated middle cluster strategy; Determine a target intermediate server cluster according to the target back to the intermediate layer strategy, and send a second file pull request to the target intermediate server cluster; Receive the target file pulled by the target intermediate server cluster from the source station.

2. The method according to claim 1, characterized in that According to the address analysis result, the performance loss result and the full-link detection result, a target return strategy of the first file pull request to the middle layer is determined, including: Obtain address analysis results from the data analysis platform; According to the address analysis result, determining whether the target service corresponding to the first file pull request is a first service; the first service indicates that the source station and the user of the target service are located in the same area; In the case where the target back to the middle layer strategy is a designated middle cluster strategy, determining the target middle server cluster according to the target back to the middle layer strategy includes: When the target service corresponding to the first file pull request is the first service, the intermediate server cluster located in the same area as the target service is determined as the target intermediate server cluster through the designated intermediate cluster strategy.

3. The method according to claim 1, characterized in that When the target back to the intermediate layer strategy is the proximity principle strategy and the target capacity of the target file is less than or equal to the first capacity, determining a target intermediate server cluster according to the target back to the intermediate layer strategy, and sending a second file pull request to the target intermediate server cluster, including: According to the proximity principle, the intermediate server cluster closest to the edge server cluster is determined as the target intermediate server cluster; A second file pull request for the target file is initiated to the target intermediate server cluster to receive the target file pulled by the target intermediate server cluster from the source station.

4. The method according to claim 1, characterized in that: When the target back to the intermediate layer strategy is the proximity principle strategy and the target capacity of the target file is greater than the first capacity, determining a target intermediate server cluster according to the target back to the intermediate layer strategy, and sending a second file pull request to the target intermediate server cluster, including: By using the proximity principle, the intermediate server cluster closest to the edge server cluster is determined as the first target intermediate server cluster; by using the consistent hashing algorithm, the second target intermediate server cluster corresponding to the first file pull request is determined; Determine a first capacity of the target file as a first file, and determine the remaining capacity of the target file except the first capacity as a second file; Initiate a second file pull request for the first file to the first target intermediate server cluster to obtain the first file pulled by the first target intermediate server cluster from the source station; A second file pull request for the second file is initiated to the second target intermediate server cluster to obtain the second file pulled by the second target intermediate server cluster from the source station.

5. The method according to claim 1, characterized in that The full-link detection result is determined by the following steps: Detect each intermediate server cluster to obtain a first detection result; receiving second detection results transmitted by each intermediate server cluster; A full-link detection result is obtained through the first detection result and the second detection result.

6. The method according to claim 1, characterized in that The performance loss result is determined by the following steps: Collecting domain name service information required by the performance loss model; the domain name service information includes: the average requested file size of each historical first file pull request and the number of each historical first file pull request; Analyze domain name service information based on the performance loss model to obtain the middle layer processor loss and bandwidth consumption; The mid-tier processor loss and the bandwidth consumption are determined as the performance loss result.

7. A response method of a content distribution network, characterized in that: Applicable to intermediate server clusters, including: Receiving a second file pull request sent from the edge server cluster, and acquiring a target file from the source station according to the second file pull request; the second file pull request is determined by a proximity principle strategy, a consistent hashing algorithm strategy, or a designated intermediate cluster strategy; The target file is transmitted to the edge server cluster.

8. The method according to claim 7, characterized in that In the case where the second file pull request is determined by the proximity principle policy and the target capacity of the target file is greater than the first capacity, the intermediate server cluster includes: a first target intermediate server cluster and a first target intermediate server cluster; Receiving a second file pull request sent from the edge server cluster, and obtaining a target file from the source station according to the second file pull request, including The first target intermediate server cluster receives a second file pull request for the first file, where the first file is a file corresponding to a first previous capacity of the target file; Obtain the first file from the source station according to the second file pull request, and transmit the first file to the second target intermediate server cluster so that the second target intermediate server cluster caches the first file; The second target intermediate server cluster receives a second file pull request for the second file, where the second file is a file corresponding to the remaining capacity of the target file except the first capacity; The second file is obtained from the source site according to the second file pull request, and the second file is cached.

9. The method according to claim 7, characterized in that: Also includes: Detect each source station to obtain a second detection result; The second detection result is transmitted to each of the edge server clusters.

10. A response method of a content distribution network, characterized in that: Applied to data analysis platforms, including: Parsing each historical first file pull request, and determining user region information corresponding to each historical first file pull request according to the user address corresponding to each historical first file pull request; Determine source station region information corresponding to each of the historical first file pull requests according to the source station addresses corresponding to each of the historical first file pull requests; Matching the user region information and the source station region information respectively corresponding to each of the historical first file pull requests, and determining a target overlap rate of a target service corresponding to the first file pull request received by the edge server cluster; According to the relationship between the target overlap rate and the first threshold, an address analysis result is obtained, wherein the address analysis result at least includes that the target service is a first service, and the first service indicates that a source station and a user of the target service are located in the same area; The address analysis result is sent to the edge server cluster.

Citation Information

Patent Citations

  • Distributed cluster file management method and system

    CN118426713A

  • Coordinated access to a clustered file system's shared storage using shared-lock architecture

    US20140095544A1

  • Gateway device, file server system, and file distribution method

    US20150201036A1