Cost query method and related device for content distribution network CDN
By introducing a directory generation and fee query mechanism in the CDN system, the problem of the inability to allocate CDN fees according to business usage in the existing technology is solved, and the fine control and planning of CDN costs are realized.
Patent Information
- Application Number
- CN202111547716.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-12-16
- Publication Date
- 2025-02-28
- Estimated Expiration
- 2041-12-16
AI Technical Summary
The prior art cannot determine the cost of each business department on CDN based on the actual use of each business, resulting in difficulty in cost statistics and control.
The directory generation server generates identification information based on the client's resource request information, and generates a directory based on the resource request information and identification information. The client can send a resource acquisition request to the CDN service provider based on the address information to generate a query log. The service provider querys the log and directory through the fee query server to determine the CDN fee for each service.
It realizes that CDN costs are allocated to each business department according to usage, so that business providers can perform cost control and business planning.
Smart Images

Figure CN114238743B_ABST
Abstract
Description
Technical Field
[0001] The present application belongs to the field of data processing, and specifically relates to a cost query method and related devices for CDN. Background Art
[0002] Content Delivery Network (CDN) is an intelligent virtual network built on the existing network. It relies on edge servers deployed in various places and uses the load balancing, content distribution, scheduling and other functional modules of the central platform to enable users to obtain the required content nearby, reduce network congestion, and improve user access response speed and hit rate. The main function of CDN is to cache content in different locations and direct user requests to the most appropriate cache server to obtain content through load balancing technology. Summary of the invention
[0003] The embodiment of the present application provides a cost query method and related devices for CDN, so as to query CDN costs according to service types, so as to facilitate cost control and service planning for service providers.
[0004] In a first aspect, an embodiment of the present application provides a cost query method for a CDN, which is applied to a directory generation server of a cost query system, wherein the cost query system includes the directory generation server, a cost query server, a client device, and a first electronic device, and the method includes:
[0005] Acquire resource request information, where the resource request information includes a service type of the service resource requested by the client device;
[0006] generating identification information according to the business type;
[0007] generating a directory according to the resource request information and the identification information, wherein the directory includes address information of the service resource, and the address information includes the identification information;
[0008] The address information is sent to the client device, the address information is used to indicate a resource acquisition request of the client device for the first electronic device, the resource acquisition request is used to indicate a query log of the first electronic device, the query log includes the identification information, the directory and the query log are used to jointly indicate the fees in the fee query server, and the first electronic device is an electronic device of a CDN service provider.
[0009] In a second aspect, an embodiment of the present application provides a cost query method for a CDN, which is applied to a cost query server of a cost query system, wherein the cost query system includes a directory generation server, the cost query server, a client device, a directory acquisition server, a first electronic device, and a second electronic device, wherein the method includes:
[0010] Acquire fee query information from the second electronic device, the fee query information including a target service type, the second electronic device being an electronic device of a service provider;
[0011] Determine a target directory from the directory acquisition server according to the target business type, the target directory is generated by the directory generation server according to the resource request information and the target identification information, the target identification information is generated according to the target business type, the target directory includes target address information, and the target address information includes the target identification information;
[0012] Determine the target identification information according to the target service type;
[0013] Acquire at least one target query log from the first electronic device according to the fee query information and the target identification information, the first electronic device is an electronic device of a CDN service provider, the target query log is generated according to a resource acquisition request of the client device, the resource acquisition request includes the target address information, and the target query log includes the target identification information;
[0014] Determine a target fee corresponding to the target service type according to the target directory and the at least one target query log;
[0015] The target cost is sent to the second electronic device.
[0016] In a third aspect, an embodiment of the present application provides a fee query method, which is applied to a fee query system, wherein the fee query system includes a catalog generation server, a fee query server, a catalog acquisition server, a client device, a first electronic device, and a second electronic device, and the method includes:
[0017] The directory generation server obtains resource request information from the client device, wherein the resource request information includes a service type of the service resource requested by the client device;
[0018] The directory generation server generates identification information according to the service type;
[0019] The directory generation server generates a directory according to the resource request information and the identification information, wherein the directory includes the address information of the service resource, and the address information includes the identification information;
[0020] The directory generation server sends the address information to the client device;
[0021] The client device sends a resource acquisition request to the first electronic device according to the address information, where the first electronic device is an electronic device of the CDN service provider;
[0022] The first electronic device sends the service resource to the client device according to the resource acquisition request, and generates a query log, wherein the query log includes the identification information;
[0023] The second electronic device sends fee inquiry information to the fee inquiry server, wherein the inquiry information includes a target service type, and the second electronic device is an electronic device of a service provider;
[0024] The fee query server determines a target directory from the directory acquisition server according to the target service type;
[0025] The fee query server determines the target identification information according to the service type;
[0026] The fee query server acquires at least one target query log from the first electronic device according to the fee query information and the target identification information;
[0027] The fee query server determines the target fee corresponding to the target service type according to the target directory and the at least one target query log;
[0028] The fee inquiry server sends the target fee to the second electronic device.
[0029] In a fourth aspect, an embodiment of the present application provides a fee query device for CDN, which is applied to a directory generation server of a fee query system, wherein the fee query system includes the directory generation server, the fee query server, a client device and a first electronic device, and the device includes: an acquisition unit, used to acquire resource request information, wherein the resource request information includes a business type of a business resource requested by the client device; a first generation unit, used to generate identification information according to the business type; a second generation unit, used to generate a directory according to the resource request information and the identification information, wherein the directory includes address information of the business resource, and the address information includes the identification information; a sending unit, used to send the address information to the client device, wherein the address information is used to indicate a resource acquisition request of the client device for the first electronic device, wherein the resource acquisition request is used to indicate a query log of the first electronic device, wherein the query log includes the identification information, and wherein the directory and the query log are used to jointly indicate the fee in the fee query server, and the first electronic device is an electronic device of a CDN service provider.
[0030] In a fifth aspect, an embodiment of the present application provides a cost query device for CDN, which is applied to a cost query server of a cost query system, wherein the cost query system includes a directory generation server, the cost query server, a client device, a directory acquisition server, a first electronic device, and a second electronic device, wherein the device includes: a first acquisition unit, for acquiring cost query information from the second electronic device, wherein the cost query information includes a target service type, and the second electronic device is an electronic device of a service provider; a second acquisition unit, for determining a target directory from the directory acquisition server according to the target service type, wherein the target directory is generated by the directory generation server according to resource request information and target identification information, and wherein the target identification information is generated according to the target service type, and the target The directory includes target address information, and the target address information includes the target identification information; a first determination unit is used to determine the target identification information according to the target business type; a third acquisition unit is used to acquire at least one target query log from the first electronic device according to the fee query information and the target identification information, the first electronic device is an electronic device of the CDN service provider, and the target query log is generated according to a resource acquisition request of the client device, the resource acquisition request includes the target address information, and the target query log includes the target identification information; a second determination unit is used to determine the target fee corresponding to the target business type according to the target directory and the at least one target query log; a sending unit is used to send the target fee to the second electronic device.
[0031] In a sixth aspect, an embodiment of the present application provides a fee query device for CDN, which is applied to a fee query system, wherein the fee query system includes a directory generation server, a fee query server, a directory acquisition server, a client device, a first electronic device, and a second electronic device, wherein the device includes: a first acquisition unit, used by the directory generation server to acquire resource request information from the client device, wherein the resource request information includes a business type of a business resource requested by the client device; a first generation unit, used by the directory generation server to generate identification information according to the business type; a second generation unit, used by the directory generation server to generate a directory according to the resource request information and the identification information, wherein the directory includes address information of the business resource, and the address information includes the identification information; a first sending unit, used by the directory generation server to send the address information to the client device; a second sending unit, used by the client device to send a resource acquisition request to the first electronic device according to the address information, wherein the first electronic device is an electronic device of the CDN service provider. equipment; a third sending unit, used for the first electronic device to send the business resource to the client device according to the resource acquisition request, and generate a query log, wherein the query log includes the identification information; a fourth sending unit, used for the second electronic device to send fee query information to the fee query server, wherein the query information includes the target business type, and the second electronic device is the electronic device of the business provider; a first determination unit, used for the fee query server to determine the target directory from the directory acquisition server according to the target business type; a second determination unit, used for the fee query server to determine the target identification information according to the business type; a second acquisition unit, used for the fee query server to acquire at least one target query log from the first electronic device according to the fee query information and the target identification information; a third determination unit, used for the fee query server to determine the target fee corresponding to the target business type according to the target directory and the at least one target query log; a fifth sending unit, used for the fee query server to send the target fee to the second electronic device.
[0032] In the seventh aspect, an embodiment of the present application provides an electronic device, comprising a processor, a memory, a communication interface, and one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the processor, and the program includes instructions for executing the steps in the first aspect, the second aspect, or the third aspect of the embodiment of the present application.
[0033] In an eighth aspect, an embodiment of the present application provides a computer storage medium, characterized in that it stores a computer program for electronic data exchange, wherein the computer program enables a computer to execute part or all of the steps described in the first aspect, the second aspect, or the third aspect of the present embodiment.
[0034] In a ninth aspect, an embodiment of the present application provides a computer program product, wherein the computer program product includes a non-transitory computer-readable storage medium storing a computer program, and the computer program is operable to cause a computer to execute some or all of the steps described in the first aspect, the second aspect, or the third aspect of the embodiment of the present application. The computer program product may be a software installation package.
[0035] It can be seen that in the embodiment of the present application, the directory generation server generates identification information based on the resource request information of the client, and then generates a directory based on the resource request information and the identification information, and then sends the address information in the directory to the client, so that the client can send a resource acquisition request to the first electronic device based on the address information, so that the first electronic device generates log information based on the resource acquisition request, so that when the service provider inquires about the CDN fee through the fee query server, it can determine the CDN fee for each service based on the log information and the directory, so that the CDN fee can be allocated to each business department according to usage, which is convenient for the service provider to perform cost control and business planning. BRIEF DESCRIPTION OF THE DRAWINGS
[0036] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0037] Figure 1a It is a schematic diagram of the architecture of a fee inquiry system provided in an embodiment of the present application;
[0038] Figure 1b It is a structural diagram of a server provided in an embodiment of the present application;
[0039] Figure 1c It is a schematic diagram of a framework of a fee inquiry system provided in an embodiment of the present application;
[0040] Figure 1d It is a deployment architecture diagram of a fee query system provided in an embodiment of the present application;
[0041] Figure 2a It is a flow chart of a cost query method for CDN provided in an embodiment of the present application;
[0042] Figure 2b It is a configuration acquisition timing diagram provided in an embodiment of the present application;
[0043] Figure 2c It is a directory mapping timing diagram provided by an embodiment of the present application;
[0044] Figure 3 It is a flowchart of another cost query method for CDN provided in an embodiment of the present application;
[0045] Figure 4 It is a flowchart of another cost query method for CDN provided in an embodiment of the present application;
[0046] Figure 5 This is a block diagram of the functional units of a cost query device for CDN provided by an embodiment of the present application;
[0047] Figure 6 This is a block diagram of the functional units of another cost query device for CDN provided in an embodiment of the present application;
[0048] Figure 7 This is a block diagram of the functional units of another cost query device for CDN provided in an embodiment of the present application;
[0049] Figure 8 This is a block diagram of the functional units of another cost query device for CDN provided in an embodiment of the present application;
[0050] Fig. 9 This is a block diagram of the functional units of another cost query device for CDN provided in an embodiment of the present application;
[0051] Fig.10 This is a block diagram of the functional units of another cost query device for CDN provided in an embodiment of the present application. DETAILED DESCRIPTION
[0052] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0053] The terms "first", "second", etc. in the specification and claims of this application and the above-mentioned drawings are used to distinguish different objects, rather than to describe a specific order. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not limited to the listed steps or units, but optionally includes steps or units that are not listed, or optionally includes other steps or units inherent to these processes, methods, products or devices.
[0054] Reference to "embodiments" herein means that a particular feature, structure, or characteristic described in conjunction with the embodiments may be included in at least one embodiment of the present application. The appearance of the phrase in various locations in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment that is mutually exclusive with other embodiments. It is explicitly and implicitly understood by those skilled in the art that the embodiments described herein may be combined with other embodiments.
[0055] Currently, when businesses provide services to users through CDN, they need to pay fees to CDN service providers according to the rules. However, it is currently impossible to determine the expenditure of each business department on CDN based on the actual usage of each business, which is not conducive to statistics and cost control.
[0056] In view of the above problems, an embodiment of the present application provides a cost query method and related devices for CDN. The embodiment of the present application is described in detail below with reference to the accompanying drawings.
[0057] See also Figure 1a , Figure 1a Schematic diagram of the architecture of a fee inquiry system provided by an embodiment of the present application. Figure 1a The fee inquiry system 10 includes a client device 101, a directory generation server 102, a directory acquisition server 103, a fee inquiry server 104, a first electronic device 105, and a second electronic device 106. The client device 101 is used to send resource request information and display the acquired service resources. The directory generation server 102 is used to generate a new directory according to the resource request information from the client device, so that the client device 101 can initiate a request to the CDN service provider, that is, the first electronic device 105, according to the address information in the generated directory. The first electronic device 105 will return the corresponding service resources to the client device 101 according to the resource acquisition request of the client device 101. When the service provider needs to query the CDN fee, the fee query information can be sent to the fee inquiry server 104 through the second electronic device 106, and the fee inquiry server 104 determines the fee according to the directory in the directory acquisition server 103 and the log information in the first electronic device 105.
[0058] The above-mentioned catalog generation server 102, catalog acquisition server 103, and fee inquiry server can be located in the same server cluster. The structure of these servers can be as follows: Figure 1b As shown, Figure 1b It is a structural diagram of a server provided in an embodiment of the present application. The server 110 includes a processor 120 memory 130, a communication interface 140 and one or more programs 131, wherein the one or more programs 131 are stored in the above-mentioned memory 130 and are configured to be executed by the above-mentioned application processor 120, and the one or more programs 131 include instructions for executing any step in the following method embodiment. In a specific implementation, the processor 120 is used to execute any step performed by an electronic device in the following method embodiment, and when performing data transmission such as sending, the communication interface 140 can be selectively called to complete the corresponding operation. Among them, the structure of the client device 101, the first electronic device 105 and the second electronic device 106 can also be the same as that of the server 110.
[0059] See also Figure 1c , Figure 1c It is a framework diagram of a fee query system provided by an embodiment of the present application. As shown in the figure, the fee query system includes an access layer, a service layer and an infrastructure layer. The access layer includes an operation platform and a directory generation server, and the directory generation server can also be referred to as a cost accounting software development kit (Software Development Kit, SDK). The service layer includes a directory acquisition server and a fee query server, and the directory acquisition server can also be referred to as a CDN cost accounting server. The fee query server can also be referred to as a CDN cost synchronization server, which is used to provide the ability to count CDN costs in various dimensions according to different businesses and different attributes, and expose a query interface to the outside for queries by relevant business parties. The basic equipment layer includes a database, a CDN server and a message queue server, and the CDN server is used to provide CDN services.
[0060] The directory generation server and directory acquisition server may include multiple servers, each of which can be deployed at the location of the CDN server to achieve global multi-active, ensuring high availability of services and privacy security. The fee query server can be deployed at a preset address, reading slave node data from databases in various computer rooms and using the database sharding function to ensure the availability of the interface. Figure 1d As shown, Figure 1d It is a deployment architecture diagram of a fee inquiry system provided in an embodiment of the present application. Figure 1dThe system includes three directory generation servers deployed at different locations. The directory generation servers at address A and address B share the directory acquisition server and database at address A, while address C includes a separate directory acquisition server and database. The directory generation servers at address A and address B will send the generated addresses to directory acquisition server A, and directory acquisition server A will store the acquired directory in database 1A. The directory generation server at address C will send the generated directory to directory acquisition server C, and store it in database C through directory acquisition server C. The fee query server is located at a specific address, which can be any one of address A, address B or address C, or a new address. For example, the fee query server in this example is located at address A. Through the sharding function of the database, the fee query server obtains directory information from database shard 1A and database shard C, and then stores the processed and acquired data in data 2A.
[0061] See also Figure 2a , Figure 2a This is a flow chart of a cost query method for CDN provided by an embodiment of the present application. As shown in the figure, the cost query method for CDN is applied to a cost query system, the cost query system includes a directory generation server, a cost query server, a directory acquisition server, a client device, a first electronic device and a second electronic device, and the method includes the following steps:
[0062] Step 201: The directory generation server obtains resource request information from the client device.
[0063] The resource request information includes the service type of the service resource requested by the client device. In a specific implementation, the client can send the resource request information to the resource distribution server of the CDN service provider, and the resource distribution server performs resource information detection according to the resource request information to obtain the attribute information of the resource information, such as the service type, the original Uniform Resource Locator (URL), the version and other information. The resource distribution server sends the attribute information to the directory generation server.
[0064] In a possible example, before the directory generation server obtains the resource request information from the client device, the method further includes: the directory generation server obtains the attribute configuration information from the directory acquisition server; and caches the attribute configuration information.
[0065] After the service provider accesses the directory generation server, the directory generation server will first query the attribute-related configuration and cache the obtained service attribute configuration. In particular, the directory generation server can obtain attribute-related configuration information from the directory acquisition server, and when the directory acquisition server is started, it can also pull the attribute configuration configured in advance by the service personnel and cache it locally. Figure 2b As shown, Figure 2b This is a configuration acquisition timing diagram provided by an embodiment of the present application. The fee inquiry system may also include a configuration center, where business personnel configure business attribute information in advance and store it in the configuration center, so that the directory acquisition server can pull the business attribute configuration information of the configuration center when it is started and load it into the local cache, so that the directory generation server can obtain the business attribute configuration from the directory acquisition server and cache it.
[0066] It can be seen that in this example, the directory generation server can obtain the service attribute configuration information in advance, so that when generating a directory according to the service type, the efficiency and accuracy of directory generation are improved.
[0067] Step 202, the directory generation server generates identification information according to the service type;
[0068] Step 203: The directory generation server generates a directory according to the resource request information and the identification information, wherein the directory includes address information of the service resource.
[0069] The address information includes the identification information. That is, after obtaining the resource request information, the directory generation service will generate a corresponding unique identifier according to the business type, and then generate a directory according to the identifier. The directories generated by the same resource request are the same, and the directory includes the address information, that is, the URL. Therefore, the address information also includes the identification information corresponding to the business type, that is, the identification information and the address information can be spliced to obtain a new URL with the business type attribute.
[0070] In a possible instance, the directory generation server generates identification information according to the business type, including: determining target configuration information from the attribute configuration information according to the business type; generating the identification information according to the target configuration information; the directory generation server generates a directory according to the resource request information and the identification information, including: obtaining an original directory according to the resource request information; generating the directory according to the original directory and the identification information.
[0071] The original directory includes the original address information of the service resource corresponding to the resource request information. The target configuration information includes service type information, so the address information included in the newly generated directory can be obtained by splicing the original address information and the identification information.
[0072] It can be seen that in this example, the directory is generated based on the identification information, which enables the specific service type to be located when performing CDN fee inquiries.
[0073] In a possible instance, after the directory generation server generates a directory according to the resource request information and the identification information, the method further includes: the directory generation server determines whether the directory has been cached; if not, the directory generation server sends the directory to the directory acquisition server and caches the directory.
[0074] The directories generated corresponding to the same resource request information may be the same, for example Figure 2c As shown, Figure 2c This is a sequence diagram of directory mapping provided by an embodiment of the present application. As shown in the figure, after the directory is generated, it can be determined whether the directory has been cached locally. If it has been cached, it can be said that the directory has been reported to the directory acquisition server. If the directory is not cached locally, it means that the directory has not been reported to the directory acquisition server. Therefore, the directory needs to be reported and written to the local cache after reporting. The directory acquisition server will also consume the directory information from the message queue server.
[0075] It can be seen that in this example, whether to report the directory to the directory acquisition server is determined based on whether there is a directory in the local cache, which can reduce the occupation of system resources.
[0076] In a possible instance, the fee inquiry system also includes a message queue server, and the directory generation server sends the directory to the directory acquisition server, including: sending a registration request to the message queue server; after successful registration, sending the directory to the message queue server, so that the directory acquisition server obtains the directory from the message queue server.
[0077] Among them, for example Figure 2b As shown in the figure, after the business party accesses the directory generation server, it will also obtain the message queue (MQ) and register the MQ producer. In this way, after the directory generation server generates the directory and caches the directory locally, it can encapsulate the directory into an MQ message and send it to the directory acquisition server. As an MQ consumer, the directory acquisition server can read the MQ message of the directory generation server, and then write the directory information into the database after performing operations such as parameter verification and structure conversion.
[0078] It can be seen that in this example, sending and obtaining messages through message queues can improve the flexibility and stability of the system.
[0079] Step 204, the directory generation server sends the address information to the client device;
[0080] Step 205: the client device sends a resource acquisition request to the first electronic device according to the address information;
[0081] Step 206: The first electronic device sends the service resource to the client device according to the resource acquisition request, and generates a query log.
[0082] The first electronic device is an electronic device of the CDN service provider.
[0083] In a possible instance, the fee inquiry system also includes multiple CDN servers, and before the first electronic device sends the target resource to the client device according to the resource acquisition request, the method also includes: the client device sends the resource acquisition request to a target CDN server among the multiple CDN servers; the target CDN server determines whether to cache the business resource according to the resource acquisition request; if so, the target CDN server sends the business resource to the client device; if not, the target CDN server determines the return-to-source information according to the resource acquisition request; the target CDN server deletes the information associated with the business type in the return-to-source information to obtain the target return-to-source information; the target CDN server sends the return-to-source information to an upper-level CDN service server, and the upper-level CDN server is a CDN server among the multiple CDN servers; the target CDN server obtains the business resource from the upper-level CDN server; the target CDN server sends the business resource to the client device.
[0084] Among them, the CDN server is used to provide CDN services. Each CDN server can be located in different places. When the client device requests resources through the CDN, it can send resource request information to the CDN server at the same address as the client device. If the corresponding business resources are cached in the target CDN server, the business resources will be returned to the client device. If the corresponding business resources are not cached locally, the target CDN server's parent CDN server will be requested for resources, that is, back to the source. The target CDN server can be a server at a primary node, and the parent CDN server can be a server at a secondary node or a source server. When the CDN returns to the source, the directory encapsulated by the SDK will be removed, that is, the directory at the time of returning to the source does not include information related to business attributes, so that transparent operations can be achieved for the business party.
[0085] It can be seen that in this example, the CDN will remove the extra directory when returning to the source. When the client device accesses the resource, the CDN will remove the spliced extra directory when returning to the source and obtain the actual path of the resource, which can be done without the business party being aware of it.
[0086] Step 207: The second electronic device sends fee inquiry information to the fee inquiry server.
[0087] The query information includes the target service type, and the second electronic device is an electronic device of the service provider. The query information may also include a query dimension customized by the client device, which may include CDN cost statistics based on time period, CDN traffic or broadband usage statistics based on time period or based on domain name, etc. In other words, all resources can be divided into services, and the ability to query CDN traffic or costs based on domain names can be provided. For the service parties that access the cost accounting SDK, that is, the directory generation server, it also supports each service party to customize the query dimension to query CDN traffic and costs.
[0088] Step 208, the fee query server determines a target directory from the directory acquisition server according to the target service type;
[0089] Step 209, the fee query server determines the target identification information according to the service type;
[0090] Step 210: the fee query server obtains at least one target query log from the first electronic device according to the fee query information and the target identification information;
[0091] Step 211, the fee query server determines the target fee corresponding to the target service type according to the target directory and the at least one target query log;
[0092] Step 212: the fee query server sends the target fee to the second electronic device.
[0093] Among them, for each resource request of the client device, the first electronic device will record the relevant log, and the log may also carry corresponding identification information, so that the fee query server can obtain the directory stored in the server according to the log and directory provided by the first electronic device for fee query, and can provide CDN data query capability by pulling the CDN fee of the daily active directory for visual display.
[0094] It can be seen that in this example, the directory generation server generates identification information based on the resource request information of the client, and then generates a directory based on the resource request information and the identification information, and then sends the address information in the directory to the client, so that the client can send a resource acquisition request to the first electronic device based on the address information, so that the first electronic device generates log information based on the resource acquisition request, so that when the service provider inquires about the CDN fee through the fee query server, it can determine the CDN fee for each service based on the log information and the directory, so that the CDN fee can be allocated to each business department according to usage, which is convenient for the service provider to carry out cost control and business planning.
[0095] See also Figure 3 , Figure 3 1 is a flow chart of another cost query method for CDN provided by an embodiment of the present application. As shown in the figure, the cost query method for CDN is applied to a directory generation server of a cost query system. The cost query system includes the directory generation server, the cost query server, a client device and a first electronic device. The method includes the following steps:
[0096] S301, obtaining resource request information, where the resource request information includes a service type of a service resource requested by the client device;
[0097] S302, generating identification information according to the service type;
[0098] S303, generating a directory according to the resource request information and the identification information, the directory including the address information of the business resource, the address information including the identification information;
[0099] S304, sending the address information to the client device, the address information is used to indicate the resource acquisition request of the client device for the first electronic device, the resource acquisition request is used to indicate the query log of the first electronic device, the query log includes the identification information, the directory and the query log are used to jointly indicate the fees in the fee query server, and the first electronic device is an electronic device of the CDN service provider.
[0100] It can be seen that in this example, the directory generation server generates identification information based on the resource request information of the client, and then generates a directory based on the resource request information and the identification information, and then sends the address information in the directory to the client, so that the client can send a resource acquisition request to the first electronic device based on the address information, so that the first electronic device generates log information based on the resource acquisition request, so that when the service provider inquires about the CDN fee through the fee query server, it can determine the CDN fee for each service based on the log information and the directory, so that the CDN fee can be allocated to each business department according to usage, which is convenient for the service provider to carry out cost control and business planning.
[0101] In a possible instance, the fee inquiry system also includes a directory acquisition server. Before acquiring resource request information, the method also includes: acquiring attribute configuration information from the directory acquisition server; caching the attribute configuration information; generating identification information according to the business type, including: determining target configuration information from the attribute configuration information according to the business type; generating the identification information according to the target configuration information; generating a directory according to the resource request information and the identification information, including: acquiring an original directory according to the resource request information; generating the directory according to the original directory and the identification information.
[0102] It can be seen that in this example, the directory generation server will cache the configuration information in advance, so that after obtaining the resource request information, it can quickly generate identification information based on the configuration information, and generate a new directory based on the identification information and the original directory corresponding to the resource. This can improve the efficiency of directory generation, and when the subsequent client device uses the address information in the directory to obtain resources, the log information generated by the first electronic device can include attribute information related to the business type, which is convenient for subsequent fee inquiries based on the business type.
[0103] In a possible example, after generating the directory according to the original directory and the identification information, the method further includes: determining whether the directory has been cached; if not, sending the directory to the directory acquisition server and caching the directory.
[0104] It can be seen that if the newly generated directory has been cached, the directory will no longer be sent to the directory acquisition server, which can save system resources.
[0105] In a possible instance, the fee inquiry system also includes a message queue server, and sending the target directory to the directory acquisition server includes: sending a registration request to the message queue server; after successful registration, sending the directory to the message queue server, so that the directory acquisition server obtains the directory from the message queue server.
[0106] It can be seen that in this example, the generated directory is encapsulated into an MQ message, and the directory acquisition server consumes and stores the MQ message, which can improve the flexibility and stability of directory acquisition.
[0107] See also Figure 4 , Figure 4 This is a flow chart of another cost query method for CDN provided by an embodiment of the present application. As shown in the figure, the cost query method for CDN is applied to a cost query server of a cost query system, the cost query system includes a directory generation server, the cost query server, a client device, a directory acquisition server, a first electronic device and a second electronic device, and the method includes the following steps:
[0108] S401, acquiring fee query information from the second electronic device, the fee query information including a target service type, the second electronic device being an electronic device of a service provider;
[0109] S402, determining a target directory from the directory acquisition server according to the target business type, the target directory is generated by the directory generation server according to resource request information and target identification information, the target identification information is generated according to the target business type, the target directory includes target address information, and the target address information includes the target identification information;
[0110] S403, determining the target identification information according to the target service type;
[0111] S404, acquiring at least one target query log from the first electronic device according to the fee query information and the target identification information, wherein the first electronic device is an electronic device of a CDN service provider, the target query log is generated according to a resource acquisition request of the client device, the resource acquisition request includes the target address information, and the target query log includes the target identification information;
[0112] S405, determining a target fee corresponding to the target service type according to the target directory and the at least one target query log;
[0113] S406: Send the target fee to the second electronic device.
[0114] It can be seen that in this example, after obtaining the query information of the second electronic device, the cost query server will obtain directory information from the directory acquisition server and log information from the first electronic device. In this way, the cost query server can calculate the CDN fee based on the business type, so that the CDN fee can be allocated to each business department according to usage, which is convenient for the service provider to carry out cost control and business planning.
[0115] For the above embodiments, please refer to Figure 5 , Figure 51 is a functional unit composition block diagram of a cost query device for CDN provided in an embodiment of the present application, wherein the cost query device 50 for CDN is applied to a cost query system, wherein the cost query system includes a directory generation server, a cost query server, a directory acquisition server, a client device, a first electronic device, and a second electronic device, wherein the device 50 includes: a first acquisition unit 501, used for the directory generation server to acquire resource request information from the client device, wherein the resource request information includes a business type of a business resource requested by the client device; a first generation unit 502, used for the directory generation server to generate identification information according to the business type; a second generation unit 503, used for the directory generation server to generate a directory according to the resource request information and the identification information, wherein the directory includes address information of the business resource, and the address information includes the identification information; a first sending unit 504, used for the directory generation server to send the address information to the client device; a second sending unit 505, used for the client device to send a resource acquisition request to the first electronic device according to the address information, wherein the first electronic device is the CDN an electronic device of a service provider; a third sending unit 506, used for the first electronic device to send the business resource to the client device according to the resource acquisition request and generate a query log, wherein the query log includes the identification information; a fourth sending unit 507, used for the second electronic device to send fee query information to the fee query server, wherein the query information includes the target business type, and the second electronic device is the electronic device of the business provider; a first determining unit 508, used for the fee query server to determine the target directory from the directory acquisition server according to the target business type; a second determining unit 509, used for the fee query server to determine the target identification information according to the business type; a second obtaining unit 510, used for the fee query server to obtain at least one target query log from the first electronic device according to the fee query information and the target identification information; a third determining unit 511, used for the fee query server to determine the target fee corresponding to the target business type according to the target directory and the at least one target query log; a fifth sending unit 512, used for the fee query server to send the target fee to the second electronic device.
[0116] In a possible instance, the fee query system further includes multiple CDN servers, and before the first electronic device sends the target resource to the client device according to the resource acquisition request, the device 50 is also used for: the client device sends the resource acquisition request to a target CDN server among the multiple CDN servers; the target CDN server determines whether to cache the business resource according to the resource acquisition request; if so, the target CDN server sends the business resource to the client device; if not, the target CDN server determines the back-to-source information according to the resource acquisition request; the target CDN server deletes the information associated with the business type in the back-to-source information to obtain the target back-to-source information; the target CDN server sends the back-to-source information to an upper-level CDN service server, and the upper-level CDN server is a CDN server among the multiple CDN servers; the target CDN server obtains the business resource from the upper-level CDN server; the target CDN server sends the business resource to the client device.
[0117] In the case of integrated units, such as Figure 6 As shown, Figure 6 This is a block diagram of the functional units of another cost query device for CDN provided in an embodiment of the present application. Figure 6 In the present invention, the cost query device 600 for CDN includes: a processing module 612 and a communication module 611. The processing module 612 is used to control and manage the actions of the operation log generation device, for example, to execute the steps of the first acquisition unit 501, the first generation unit 502, the second generation unit 503, the first sending unit 504, the second sending unit 505, the third sending unit 506, the fourth sending unit 507, the first determination unit 508, the second determination unit 509, the second acquisition unit 510, the third determination unit 511 and the fifth sending unit 512, and / or to execute other processes of the technology described herein. The communication module 611 is used for the interaction between the cost query device for CDN and other devices. Figure 6 As shown, the cost query device for CDN may further include a storage module 613, and the storage module 613 is used to store program codes and data of the cost query device for CDN.
[0118] Among them, the processing module 612 can be a processor or a controller, for example, a central processing unit (CPU), a general processor, a digital signal processor (DSP), an ASIC, an FPGA or other programmable logic device, a transistor logic device, a hardware component or any combination thereof. It can implement or execute various exemplary logic blocks, modules and circuits described in conjunction with the disclosure of this application. The processor can also be a combination that implements a computing function, for example, a combination of one or more microprocessors, a combination of a DSP and a microprocessor, and the like. The communication module 611 can be a transceiver, an RF circuit or a communication interface, and the like. The storage module 613 can be a memory.
[0119] All relevant contents of each scenario involved in the above method embodiment can be referred to the functional description of the corresponding functional module, and will not be repeated here. Figure 2a The cost query method for CDN is shown.
[0120] For the above embodiments, please refer to Figure 7 , Figure 7 : This is a functional unit composition block diagram of another cost query device for CDN provided in an embodiment of the present application. The cost query device 70 for CDN is applied to a directory generation server of a cost query system. The cost query system includes the directory generation server, the cost query server, a client device and a first electronic device. The device 70 includes: an acquisition unit 701, used to acquire resource request information, the resource request information includes the business type of the business resource requested by the client device; a first generation unit 702, used to generate identification information according to the business type; a second generation unit 703, used to generate a directory according to the resource request information and the identification information, the directory includes address information of the business resource, and the address information includes the identification information; a sending unit 704, used to send the address information to the client device, the address information is used to indicate the resource acquisition request of the client device for the first electronic device, the resource acquisition request is used to indicate the query log of the first electronic device, the query log includes the identification information, the directory and the query log are used to jointly indicate the cost in the cost query server, and the first electronic device is an electronic device of the CDN service provider.
[0121] In a possible instance, the fee inquiry system further includes a directory acquisition server, and before acquiring resource request information, the device 70 is further used to: acquire attribute configuration information from the directory acquisition server; cache the attribute configuration information; the generating identification information according to the business type includes: determining target configuration information from the attribute configuration information according to the business type; generating the identification information according to the target configuration information; the generating a directory according to the resource request information and the identification information includes: acquiring an original directory according to the resource request information; generating the directory according to the original directory and the identification information.
[0122] In a possible example, after generating the directory according to the original directory and the identification information, the device 70 is further used to: determine whether the directory has been cached; if not, send the directory to the directory acquisition server and cache the directory.
[0123] In a possible instance, the fee inquiry system also includes a message queue server, and in terms of sending the target directory to the directory acquisition server, the device 70 is also used to: send a registration request to the message queue server; after successful registration, send the directory to the message queue server, so that the directory acquisition server obtains the directory from the message queue server.
[0124] In the case of integrated units, such as Figure 8 As shown, Figure 8 This is a block diagram of the functional units of another cost query device for CDN provided in an embodiment of the present application. Figure 8 In the embodiment, the cost query device 800 for CDN includes: a processing module 812 and a communication module 811. The processing module 812 is used to control and manage the actions of the operation log generating device, for example, to execute the steps of the acquisition unit 701, the first generating unit 702, the second generating unit 703 and the sending unit 704, and / or to execute other processes of the technology described herein. The communication module 811 is used for the interaction between the cost query device for CDN and other devices. Figure 8 As shown, the cost query device for CDN may further include a storage module 813, and the storage module 813 is used to store program codes and data of the cost query device for CDN.
[0125] Among them, the processing module 812 can be a processor or a controller, for example, a central processing unit (CPU), a general processor, a digital signal processor (DSP), an ASIC, an FPGA or other programmable logic device, a transistor logic device, a hardware component or any combination thereof. It can implement or execute various exemplary logic blocks, modules and circuits described in conjunction with the disclosure of this application. The processor can also be a combination that implements a computing function, such as a combination of one or more microprocessors, a combination of a DSP and a microprocessor, and the like. The communication module 811 can be a transceiver, an RF circuit or a communication interface, and the like. The storage module 813 can be a memory.
[0126] All relevant contents of each scenario involved in the above method embodiment can be referred to the functional description of the corresponding functional module, and will not be repeated here. Figure 3 The cost query method for CDN is shown.
[0127] See also Fig. 9 , Fig. 9This is a functional unit composition block diagram of another cost query device for CDN provided in an embodiment of the present application. As shown in the figure, the cost query device for CDN is applied to the cost query server of the cost query system, the cost query system includes a directory generation server, the cost query server, a client device, a directory acquisition server, a first electronic device and a second electronic device, the device 90 includes: a first acquisition unit 901, used to obtain cost query information from the second electronic device, the cost query information includes a target service type, the second electronic device is an electronic device of a service provider; a second acquisition unit 902, used to determine a target directory from the directory acquisition server according to the target service type, the target directory is generated by the directory generation server according to resource request information and target identification information, the target identification information is generated according to the target service type, the target directory includes a target location The target address information includes the target identification information; a first determining unit 903 is used to determine the target identification information according to the target business type; a third obtaining unit 904 is used to obtain at least one target query log from the first electronic device according to the fee query information and the target identification information, the first electronic device is an electronic device of the CDN service provider, the target query log is generated according to the resource acquisition request of the client device, the resource acquisition request includes the target address information, and the target query log includes the target identification information; a second determining unit 905 is used to determine the target fee corresponding to the target business type according to the target directory and the at least one target query log; a sending unit 906 is used to send the target fee to the second electronic device.
[0128] In the case of integrated units, such as Fig.10 As shown, Fig.10 This is a block diagram of the functional units of another cost query device for CDN provided in an embodiment of the present application. Fig.10 In the embodiment, the cost query device 100 for CDN includes: a processing module 112 and a communication module 111. The processing module 112 is used to control and manage the actions of the operation log generating device, for example, to execute the steps of the first acquisition unit 901, the second acquisition unit 902, the first determination unit 903, the third acquisition unit 904, the second determination unit 905 and the sending unit 906, and / or to execute other processes of the technology described herein. The communication module 111 is used for the interaction between the cost query device for CDN and other devices. Fig.10 As shown, the cost query device for CDN may further include a storage module 113, and the storage module 113 is used to store program codes and data of the cost query device for CDN.
[0129] Among them, the processing module 112 can be a processor or a controller, for example, a central processing unit (CPU), a general processor, a digital signal processor (DSP), an ASIC, an FPGA or other programmable logic device, a transistor logic device, a hardware component or any combination thereof. It can implement or execute various exemplary logic blocks, modules and circuits described in conjunction with the disclosure of this application. The processor can also be a combination that implements a computing function, such as a combination of one or more microprocessors, a combination of a DSP and a microprocessor, and the like. The communication module 111 can be a transceiver, an RF circuit or a communication interface, and the like. The storage module 113 can be a memory.
[0130] All relevant contents of each scenario involved in the above method embodiment can be referred to the functional description of the corresponding functional module, and will not be repeated here. Figure 4 The cost query method for CDN is shown.
[0131] The above embodiments can be implemented in whole or in part by software, hardware, firmware or any other combination. When implemented using software, the above embodiments can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions or computer programs. When the computer instructions or computer programs are loaded or executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions can be transmitted from one website site, computer, server or data center to another website site, computer, server or data center by wired or wireless means. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that contains one or more available media sets. The available medium can be a magnetic medium (e.g., a floppy disk, a hard disk, a tape), an optical medium (e.g., a DVD), or a semiconductor medium. The semiconductor medium can be a solid-state hard disk.
[0132] An embodiment of the present application also provides a computer storage medium, wherein the computer storage medium stores a computer program for electronic data exchange, wherein the computer program enables a computer to execute part or all of the steps of any method described in the above method embodiments, and the above computer includes an electronic device.
[0133] The present application also provides a computer program product, which includes a non-transitory computer-readable storage medium storing a computer program, and the computer program is operable to cause a computer to execute some or all of the steps of any method described in the method embodiment. The computer program product may be a software installation package, and the computer includes an electronic device.
[0134] It should be understood that in the various embodiments of the present application, the size of the serial numbers of the above-mentioned processes does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.
[0135] In the several embodiments provided in the present application, it should be understood that the disclosed methods, devices and systems can be implemented in other ways. For example, the device embodiments described above are merely schematic; for example, the division of the units is only a logical function division, and there may be other division methods in actual implementation; for example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0136] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0137] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may be physically included separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of hardware plus software functional units.
[0138] The above-mentioned integrated unit implemented in the form of a software functional unit can be stored in a computer-readable storage medium. The above-mentioned software functional unit is stored in a storage medium, including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform some steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: a USB flash drive, a mobile hard disk, a magnetic disk, an optical disk, a volatile memory or a non-volatile memory. Among them, the non-volatile memory can be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM) or a flash memory. The volatile memory can be a random access memory (RAM), which is used as an external cache. By way of example but not limitation, many forms of random access memory (RAM) are available, such as static RAM (SRAM), dynamic random access memory (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDR SDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM) and direct RAM bus RAM (DR RAM). Various media that can store program code are available.
[0139] Although the present invention is disclosed as above, the present invention is not limited thereto. Any person skilled in the art can easily think of changes or substitutions without departing from the spirit and scope of the present invention, and can make various changes and modifications, including the combination of the above-mentioned different functions and implementation steps, including software and hardware implementation methods, all of which are within the scope of protection of the present invention.
Claims
1. A cost query method for a content delivery network CDN, characterized in that: A catalog generation server applied to a fee inquiry system, the fee inquiry system comprising the catalog generation server, a fee inquiry server, a catalog acquisition server, a client device and a first electronic device, the method comprising: Acquire attribute configuration information from the directory acquisition server; cache the attribute configuration information; Acquire resource request information, where the resource request information includes a service type of the service resource requested by the client device; Determining target configuration information from the attribute configuration information according to the service type; generating identification information according to the target configuration information; Acquire an original directory according to the resource request information; generate a directory according to the original directory and the identification information, the directory including the address information of the business resource, and the address information including the identification information; The address information is sent to the client device, the address information is used to indicate a resource acquisition request of the client device for the first electronic device, the resource acquisition request is used to indicate a query log of the first electronic device, the query log includes the identification information, the directory and the query log are used to jointly indicate the fees in the fee query server, and the first electronic device is an electronic device of a CDN service provider.
2. The method according to claim 1, characterized in that After generating the directory according to the original directory and the identification information, the method further includes: determining whether the directory is already cached; If not, the directory is sent to the directory acquisition server and cached.
3. The method according to claim 2, characterized in that The fee inquiry system further includes a message queue server, and the sending of the directory to the directory acquisition server includes: Sending a registration request to the message queue server; After successful registration, the directory is sent to the message queue server, so that the directory acquisition server acquires the directory from the message queue server.
4. A cost query method for CDN, characterized in that: A fee query server applied to a fee query system, the fee query system comprising a catalog generation server, the fee query server, a client device, a catalog acquisition server, a first electronic device and a second electronic device, the method comprising: Acquire fee query information from the second electronic device, the fee query information including a target service type, the second electronic device being an electronic device of a service provider; Determine a target directory from the directory acquisition server according to the target business type, the target directory is generated by the directory generation server according to the original directory and target identification information, the original directory is acquired according to the resource request information, the target identification information is generated according to the target configuration information, the target configuration information is determined from the attribute configuration information according to the target business type, the attribute configuration information comes from the directory acquisition server, the target directory includes target address information, and the target address information includes the target identification information; Determine the target identification information according to the target service type; Acquire at least one target query log from the first electronic device according to the fee query information and the target identification information, the first electronic device is an electronic device of a CDN service provider, the target query log is generated according to a resource acquisition request of the client device, the resource acquisition request includes the target address information, and the target query log includes the target identification information; Determine a target fee corresponding to the target service type according to the target directory and the at least one target query log; The target cost is sent to the second electronic device.
5. A cost query method for CDN, characterized in that: Applied to a fee inquiry system, the fee inquiry system includes a catalog generation server, a fee inquiry server, a catalog acquisition server, a client device, a first electronic device and a second electronic device, and the method includes: The directory generation server obtains the attribute configuration information from the directory acquisition server; caches the attribute configuration information; The directory generation server obtains resource request information from the client device, wherein the resource request information includes a service type of the service resource requested by the client device; The directory generation server determines target configuration information from the attribute configuration information according to the service type; generates identification information according to the target configuration information; The directory generation server obtains an original directory according to the resource request information; generates a directory according to the original directory and the identification information, wherein the directory includes the address information of the business resource, and the address information includes the identification information; The directory generation server sends the address information to the client device; The client device sends a resource acquisition request to the first electronic device according to the address information, where the first electronic device is an electronic device of a CDN service provider; The first electronic device sends the service resource to the client device according to the resource acquisition request, and generates a query log, wherein the query log includes the identification information; The second electronic device sends fee inquiry information to the fee inquiry server, wherein the inquiry information includes a target service type, and the second electronic device is an electronic device of a service provider; The fee query server determines a target directory from the directory acquisition server according to the target service type; The fee query server determines the target identification information according to the service type; The fee query server acquires at least one target query log from the first electronic device according to the fee query information and the target identification information; The fee query server determines the target fee corresponding to the target service type according to the target directory and the at least one target query log; The fee inquiry server sends the target fee to the second electronic device.
6. The method according to claim 5, characterized in that The fee query system further includes a plurality of CDN servers. Before the first electronic device sends the target resource to the client device according to the resource acquisition request, the method further includes: The client device sends the resource acquisition request to a target CDN server among the multiple CDN servers; The target CDN server determines whether to cache the service resource according to the resource acquisition request; If yes, the target CDN server sends the service resource to the client device; If not, the target CDN server determines the back-to-source information according to the resource acquisition request; The target CDN server deletes the information associated with the service type in the back-to-source information to obtain target back-to-source information; The target CDN server sends the back-to-source information to an upper-level CDN server, where the upper-level CDN server is a CDN server among the multiple CDN servers; The target CDN server obtains the service resource from the upper-level CDN server; The target CDN server sends the service resource to the client device.
7. A cost query device for CDN, characterized in that: A directory generation server applied to a fee inquiry system, the fee inquiry system comprising the directory generation server, a fee inquiry server, a directory acquisition server, a client device and a first electronic device, the device comprising: an acquisition unit, configured to acquire attribute configuration information from the directory acquisition server; cache the attribute configuration information; acquire resource request information, the resource request information including a service type of a service resource requested by the client device; A first generating unit, configured to determine target configuration information from the attribute configuration information according to the service type; and generate identification information according to the target configuration information; A second generating unit is configured to obtain an original directory according to the resource request information; generate a directory according to the original directory and the identification information, wherein the directory includes the address information of the service resource, and the address information includes the identification information; A sending unit is used to send the address information to the client device, the address information is used to indicate the resource acquisition request of the client device for the first electronic device, the resource acquisition request is used to indicate the query log of the first electronic device, the query log includes the identification information, the directory and the query log are used to jointly indicate the fees in the fee query server, and the first electronic device is an electronic device of the CDN service provider.
8. A cost query device for CDN, characterized in that: A fee query server applied to a fee query system, the fee query system comprising a catalog generation server, the fee query server, a client device, a catalog acquisition server, a first electronic device and a second electronic device, the device comprising: A first acquisition unit is used to acquire fee query information from the second electronic device, wherein the fee query information includes a target service type, and the second electronic device is an electronic device of a service provider; a second acquisition unit, configured to determine a target directory from the directory acquisition server according to the target business type, the target directory being generated by the directory generation server according to an original directory and target identification information, the original directory being acquired according to resource request information, the target identification information being generated according to target configuration information, the target configuration information being determined from attribute configuration information according to the target business type, the attribute configuration information being from the directory acquisition server, the target directory including target address information, and the target address information including the target identification information; A first determining unit, configured to determine the target identification information according to the target service type; a third acquisition unit, configured to acquire at least one target query log from the first electronic device according to the fee query information and the target identification information, wherein the first electronic device is an electronic device of a CDN service provider, the target query log is generated according to a resource acquisition request of the client device, the resource acquisition request includes the target address information, and the target query log includes the target identification information; A second determining unit, configured to determine a target fee corresponding to the target service type according to the target directory and the at least one target query log; A sending unit is used to send the target fee to the second electronic device.
9. A cost query device for CDN, characterized in that: Applied to a fee inquiry system, the fee inquiry system includes a catalog generation server, a fee inquiry server, a catalog acquisition server, a client device, a first electronic device and a second electronic device, and the device includes: A first acquisition unit is used for the directory generation server to acquire attribute configuration information from the directory acquisition server; cache the attribute configuration information; the directory generation server acquires resource request information from the client device, the resource request information includes the service type of the service resource requested by the client device; A first generating unit, configured for the directory generating server to determine target configuration information from the attribute configuration information according to the service type; and to generate identification information according to the target configuration information; A second generating unit is used for the directory generating server to obtain an original directory according to the resource request information; generate a directory according to the original directory and the identification information, the directory including the address information of the business resource, and the address information including the identification information; A first sending unit, configured for the directory generation server to send the address information to the client device; A second sending unit, configured for the client device to send a resource acquisition request to the first electronic device according to the address information, where the first electronic device is an electronic device of a CDN service provider; A third sending unit, configured for the first electronic device to send the service resource to the client device according to the resource acquisition request, and to generate a query log, wherein the query log includes the identification information; A fourth sending unit, configured for the second electronic device to send fee inquiry information to the fee inquiry server, wherein the inquiry information includes a target service type, and the second electronic device is an electronic device of a service provider; A first determining unit, configured for the fee query server to determine a target directory from the directory acquisition server according to the target service type; A second determining unit, configured for the fee query server to determine target identification information according to the service type; A second acquisition unit, configured for the fee inquiry server to acquire at least one target inquiry log from the first electronic device according to the fee inquiry information and the target identification information; A third determining unit, configured for the fee query server to determine a target fee corresponding to the target service type according to the target directory and the at least one target query log; A fifth sending unit is used for the fee query server to send the target fee to the second electronic device.
10. An electronic device, characterized in that: The method comprises a processor, a memory, and one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the processor, and the programs include instructions for executing the steps in the method according to any one of claims 1 to 3 or claim 4 or any one of claims 5 to 6.
11. A computer-readable storage medium, characterized in that: A computer program for electronic data exchange is stored, wherein the computer program enables a computer to execute the method according to any one of claims 1 to 3 or claim 4 or any one of claims 5 to 6.
Citation Information
Patent Citations
Method, device and system for supporting file transfer between domain systems
CN102082812A
Internet content delivery method, device and system
CN109218362A