CN115225490A - Gateway configuration method and device and electronic equipment - Google Patents

Gateway configuration method and device and electronic equipment Download PDF

Info

Publication number
CN115225490A
CN115225490A CN202210858525.3A CN202210858525A CN115225490A CN 115225490 A CN115225490 A CN 115225490A CN 202210858525 A CN202210858525 A CN 202210858525A CN 115225490 A CN115225490 A CN 115225490A
Authority
CN
China
Prior art keywords
target node
hop count
count information
node
information
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202210858525.3A
Other languages
Chinese (zh)
Inventor
叶珍
周香鹤
姜明欣
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tianyi Cloud Technology Co Ltd
Original Assignee
Tianyi Cloud Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tianyi Cloud Technology Co Ltd filed Critical Tianyi Cloud Technology Co Ltd
Priority to CN202210858525.3A priority Critical patent/CN115225490A/en
Publication of CN115225490A publication Critical patent/CN115225490A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/0803Configuration setting
    • H04L41/0813Configuration setting characterised by the conditions triggering a change of settings
    • H04L41/0816Configuration setting characterised by the conditions triggering a change of settings the condition being an adaptation, e.g. in response to network events
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/0893Assignment of logical groups to network elements

Abstract

The method comprises the steps of firstly determining a first target node corresponding to a user request when the user request is obtained, and indicating the first target node to analyze current hop count information corresponding to the user request, further determining level information corresponding to the first target node according to the current hop count information, and loading gateway configuration corresponding to the level information in the first target node. By the method, the gateway of the first target node can load different gateway configurations according to different user requests, so that the first target node can adapt to more types of user requests, the situation that local hierarchical node loads are too high or too low is avoided when a scene with high concurrency and request peak is faced, the utilization rate of CDN gateway configuration is enhanced, and the cost of node operation and maintenance is reduced.

Description

Gateway configuration method and device and electronic equipment
Technical Field
The present application relates to the field of IT and software development, and in particular, to a gateway configuration method and apparatus, and an electronic device.
Background
A Content Delivery Network (CDN) is an intelligent virtual Network built on the basis of an existing Network, and users can obtain required Content nearby by using CDN nodes deployed in various regions.
In the process of serving the user, because of the geographic distribution, part of the nodes are close to the user and part of the nodes are far from the user, and generally, the node closest to the user is used as a first access node to directly provide service for the user; the node far away from the user is used for providing backup resources for the user under the condition that the first access node cannot provide the user access resources; and if all the CDN nodes can not provide the resources, the last CDN node directly jumps back to the source station.
At present, all CDN nodes are divided into fixed hierarchies, for example, a first access node is divided into an edge layer, and a gateway of the first access node only loads edge hierarchy configuration, where the gateway is an important component of the CDN and is responsible for processing a request of a user, and meanwhile, through gateway configuration, a customized service corresponding to the request can be provided for the user; dividing nodes for providing backup resources for users into middle layers, and only loading middle-level configuration by a gateway of the nodes; nodes that jump directly back to the source station are divided into source-back layers, and only the source-back level configuration is loaded by the gateway.
In the design of node level solidification, the type of service provided by the gateway for the user is also fixed and unchanged, so that the utilization rate of CDN gateway configuration is reduced, and the cost of node operation and maintenance is increased, for example, in a scenario with high concurrency and a request peak, the request is first transmitted to the edge layer node, the gateway configuration processes the request, and only after the edge layer node cannot obtain a result corresponding to the request, the request is transmitted to the next layer node, which results in an excessively high load on the edge layer node, and an excessively low load on the middle layer node or the back source layer node.
Disclosure of Invention
The application provides a gateway configuration method, a gateway configuration device and electronic equipment, which can enable a gateway of a first target node to load different gateway configurations according to different user requests, so that the first target node can adapt to more various user requests, further avoid the situation that local level node loads are too high or too low when a scene with high concurrency and request peak is faced, enhance the utilization rate of CDN gateway configuration, and reduce the cost of node operation and maintenance.
In a first aspect, the present application provides a gateway configuration method, including:
when a user request is obtained, determining a first target node corresponding to the user request;
indicating the first target node to analyze current hop count information corresponding to the user request, wherein the current hop count information represents position information of the first target node;
determining the level information corresponding to the first target node according to the current hop count information;
and loading the gateway configuration corresponding to the hierarchy information in the first target node.
By the method, the gateway of the first target node can load different gateway configurations according to different user requests, so that the first target node can adapt to more types of user requests, the situation that local hierarchical node loads are too high or too low is avoided when a scene with high concurrency and request peak is faced, the utilization rate of CDN gateway configuration is enhanced, and the cost of node operation and maintenance is reduced.
In one possible design, the instructing the first target node to parse current hop count information corresponding to the user request includes:
instructing the first target node to analyze historical hop count information corresponding to the user request, wherein the historical hop count information represents node position information before the user request reaches the first target node;
and increasing a preset value to the historical hop count information to obtain the current hop count information.
By the method, the current hop count information is obtained, so that a subsequent node scheduling platform determines a resource access path corresponding to the first target node according to the current hop count information.
In a possible design, the determining, according to the current hop count information, hierarchical information corresponding to the first target node includes:
determining a resource access path corresponding to the first target node according to the current hop count information;
and determining the level information corresponding to the first target node according to the resource access path.
By the method, the hierarchy information corresponding to the first target node is obtained based on the current hop count information requested by the user, and the gateway configuration is loaded according to the hierarchy information, so that the utilization rate of the CDN gateway configuration is increased, and the cost of node operation and maintenance is reduced.
In one possible design, the loading, in the first target node, a gateway configuration corresponding to the hierarchy information includes:
judging whether gateway configuration corresponding to the level information exists in a local cache module;
if yes, loading the gateway configuration in the first target node;
if not, searching the gateway configuration from a next-level cache module until the gateway configuration is searched, wherein the next-level cache module comprises the data in the local cache module.
By the method, the gateway configuration of the level corresponding to the domain name is fully issued, and the gateway configuration is cooperatively loaded based on the multi-cache module, so that the issuing and loading modes of all level node gateway configurations are unified, the operation and maintenance pressure of the nodes is reduced, and the gateway configuration is efficiently and quickly loaded.
In one possible design, after the loading the gateway configuration corresponding to the hierarchy information, the method further includes:
processing the user request according to a processing rule corresponding to the gateway configuration;
judging whether the user request is processed;
if yes, returning the processed result to the user;
if not, determining second target node information according to the current hop count information, and indicating the first target node to send the user request to the second target node information.
By the method, the second target node information is obtained based on the user request, so that the situation that the load of a certain node is too high and the loads of other nodes are too low can be avoided when the scene with high concurrency and a request peak period is faced.
In a second aspect, the present application provides an apparatus for configuring a gateway, the apparatus including:
the first determining module is used for determining a first target node corresponding to a user request when the user request is obtained;
the analysis module is used for indicating the first target node to analyze current hop count information corresponding to the user request, wherein the current hop count information represents the position information of the first target node;
a second determining module, configured to determine, according to the current hop count information, level information corresponding to the first target node;
and the loading module is used for loading the gateway configuration corresponding to the hierarchy information in the first target node.
In one possible design, the parsing module is specifically configured to:
instructing the first target node to analyze historical hop count information corresponding to the user request, wherein the historical hop count information represents node position information before the user request reaches the first target node;
and increasing a preset value to the historical hop count information to obtain the current hop count information.
In one possible design, the second determining module is specifically configured to:
determining a resource access path corresponding to the first target node according to the current hop count information;
and determining the level information corresponding to the first target node according to the resource access path.
In one possible design, the load module is specifically configured to:
judging whether gateway configuration corresponding to the level information exists in a local cache module;
if yes, loading the gateway configuration in the first target node;
if not, searching the gateway configuration from a next-level cache module until the gateway configuration is searched, wherein the next-level cache module comprises the data in the local cache module.
In one possible design, the apparatus further includes:
processing the user request according to a processing rule corresponding to the gateway configuration;
judging whether the user request is processed or not;
if so, returning the processed result to the user;
if not, determining second target node information according to the current hop count information, and indicating the first target node to send the user request to the second target node information.
In a third aspect, the present application provides an electronic device, comprising:
a memory for storing a computer program;
a processor for implementing the method steps of any one of claims 1-5 when executing the computer program stored on the memory.
In a fourth aspect, the present application provides a computer-readable storage medium having stored therein a computer program, which when executed by a processor, implements the gateway configuration method steps described above.
By the gateway configuration method provided by the application, the gateway of the first target node can load different gateway configurations according to different user requests, so that the first target node can adapt to more various user requests, the situation that local level nodes are too high or too low in load is avoided when the scene with high concurrency and request peak is faced, the utilization rate of the configuration of the CDN gateway is enhanced, and the cost of node operation and maintenance is reduced.
For each of the second to fourth aspects and possible technical effects of each aspect, reference is made to the above description of the possible technical effects of the first aspect or various possible schemes of the first aspect, and repeated description is omitted here.
Drawings
FIG. 1 is a schematic view of a node hierarchy;
fig. 2 is a flowchart of a gateway configuration method provided in the present application;
fig. 3 is a schematic node distribution diagram provided in the present application;
fig. 4 is a schematic diagram of a communication relationship between a CDN node and a node scheduling platform provided in the present application;
fig. 5 is a schematic diagram of a cache module of a gateway configuration provided in the present application;
FIG. 6 is a schematic structural diagram of a store back source module provided in the present application;
fig. 7 is a flowchart of a gateway configuration method provided in the present application;
fig. 8 is a schematic structural diagram of a gateway configuration apparatus provided in the present application;
fig. 9 is a schematic structural diagram of an electronic device provided in the present application.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more clear, the present application will be further described in detail with reference to the accompanying drawings. The particular methods of operation in the method embodiments may also be applied to apparatus embodiments or system embodiments. It should be noted that "a plurality" is understood as "at least two" in the description of the present application. "and/or" describes the association relationship of the associated objects, meaning that there may be three relationships, e.g., a and/or B, which may mean: a exists alone, A and B exist, and B exists alone. A is connected with B and can represent: a and B are directly connected and A and B are connected through C. In addition, in the description of the present application, the terms "first," "second," and the like are used for descriptive purposes only and are not intended to indicate or imply relative importance nor order to be construed.
Embodiments of the present application are described in detail below with reference to the accompanying drawings.
A Content Delivery Network (CDN) is an intelligent virtual Network built on the basis of an existing Network, and users can obtain required Content nearby by using CDN nodes deployed in various regions.
In the process of serving the user, because of the geographic distribution, part of the nodes are close to the user and part of the nodes are far from the user, and generally, the node closest to the user is used as a first access node to directly provide service for the user; the node far away from the user is used for providing backup resources for the user under the condition that the first access node cannot provide the user access resources; and if all the CDN nodes can not provide resources, the last CDN node directly jumps back to the source station. As shown in fig. 1, a node hierarchy diagram includes four types, namely an edge layer, an intermediate layer, a back source layer and an edge back source layer, where a node close to a user side corresponds to the edge layer; the node close to the source station side corresponds to the source layer; nodes of which both sides are not directly interacted correspond to the middle layer; the nodes close to both the user side and the source station side correspond to the edge loopback layer, and the resource access paths with different node numbers also have different numbers corresponding to each hierarchy, for example, for the path with the node number of 1, no intermediate layer exists, and for the path with the node number of more than 3, a plurality of intermediate layers exist.
At present, all CDN nodes divided into fixed hierarchies only load gateway configurations corresponding to the hierarchies, where a gateway is an important component of a CDN and is responsible for processing a request of a user, and meanwhile, through the gateway configurations, a customized service corresponding to the request may be provided for the user, for example, an edge layer gateway only loads edge hierarchy configurations; the middle layer gateway only loads middle layer configuration; the fallback layer gateway only loads the fallback level configuration.
When a scene with high concurrency and a request peak period is faced, the request is firstly transmitted to an edge layer node, the gateway configuration of the node can process the request, and only after the edge layer node cannot obtain a result corresponding to the request, the request is transmitted to a next layer node, so that the load of the edge layer node is too high, and the load of an intermediate layer node or a back source layer node is too low, so that the utilization rate of the gateway configuration is reduced, and the cost of node operation and maintenance is increased.
In order to solve the above problem, according to the gateway configuration method provided in the embodiment of the present application, a gateway of a first target node can load different gateway configurations according to different user requests, so that the first target node can adapt to more types of user requests, and further, when a scene with high concurrency and a high request peak is faced, the situation that a local level node load is too high or too low is avoided, the utilization rate of CDN gateway configuration is enhanced, and the cost of node operation and maintenance is reduced. The method and the device in the embodiment of the application are based on the same technical concept, and because the principles of the problems solved by the method and the device are similar, the device and the embodiment of the method can be mutually referred, and repeated parts are not repeated.
In order to make the objects, technical solutions and advantages of the present application more clear, the present application is further described in detail below with reference to the accompanying drawings.
As shown in fig. 2, a flowchart of a gateway configuration method provided in the present application specifically includes the following steps:
s21, when a user request is obtained, determining a first target node corresponding to the user request;
in the embodiment, in order to solve the problems that in the prior art, due to node hierarchical solidification, the type of service provided by a gateway for a user is fixed, so that the utilization rate of CDN gateway configuration is low, and the operation and maintenance cost of a node is high, a gateway of a first target node may load different gateway configurations according to different user requests, so that the first target node may adapt to more types of user requests, thereby improving the utilization rate of CDN gateway configuration and reducing the operation and maintenance cost of the node, where the determination of the first target node is random, and as long as the node is in an idle state, the node may be used as the first target node.
By the method, the first target node is determined, so that the situation that the load of a certain node is too high and the loads of other nodes are too low can be avoided when scenes with high concurrency and request peak periods are faced.
S22, indicating the first target node to analyze the current hop count information corresponding to the user request;
in the embodiment of the application, after the first target node is determined, the first target node is indicated to analyze historical hop count information corresponding to a user request, wherein the historical hop count information represents node position information before the user request reaches the first target node, and the historical hop count information is increased by a preset value, for example, 1, so as to obtain current hop count information.
For example, if the historical hop count information is 0, assigning the historical hop count information to be 1, that is, adding 1 to obtain the current hop count information to be 1; or if the historical hop count information is 2, the current hop count information is 3 after self-adding 1.
By the method, the current hop count information is obtained, so that a subsequent node scheduling platform determines a resource access path corresponding to the first target node according to the current hop count information.
S23, determining the hierarchy information corresponding to the first target node according to the current hop count information;
in the embodiment, after obtaining the current hop count information, the first target node sends the current hop count information to the node scheduling platform by the gateway, where the node scheduling platform stores characteristics of all CDN nodes, such as node utilization, and after receiving the current hop count information, the node scheduling platform may determine a resource access path corresponding to the first target node according to the current hop count information, where the resource access path is an optimal path from the first target node to the source station.
Specifically, there are many paths from the first target node to the source station, and after comparing the characteristics of all CDN nodes, the location relationships between the user and all nodes, and the location relationships between the source station and all nodes, the node scheduling platform may determine a resource access path corresponding to the first target path, so that the level information corresponding to the first target node may be determined according to the resource access path.
For example, as shown in fig. 3, a schematic node distribution diagram provided in the present application, and as can be seen from fig. 3, there are many paths from a user end to a source station, such as path 1: user side, node 1, node 2, node 3, source station, or path 2: when a first target node is a node 2, the node 2 analyzes current hop count information corresponding to a user request to be 1, a gateway of the node 2 sends the current hop count information to a node scheduling platform, and after receiving the current hop count information 1, the node scheduling platform determines that a resource access path 1 corresponding to the node 2 is: a user side, a node 2, a node 5 and a source station, and at this time, the level of the node 2 can be determined to be an edge layer.
The first target node is node 2, the node 2 resolves the current hop count information corresponding to the user request to be 2, the gateway of the node sends the current hop count information to the node scheduling platform, and after receiving the current hop count information 2, the node scheduling platform determines that the resource access path 2 corresponding to the node 2 is: the user side, the node 1, the node 2 and the source station, and at this time, the level of the node 2 can be determined to be an insulating layer.
After determining the level information corresponding to the first target node, the scheduling platform returns the level information to the first target node, as shown in fig. 4, which is a schematic diagram of a communication relationship between a CDN node and a node scheduling platform provided by the present application, the CDN node first requests the level information from the node scheduling platform, and the node scheduling platform returns the level information to the CDN node after receiving the request, thereby completing the communication.
By the method, the hierarchy information corresponding to the first target node is obtained based on the current hop count information requested by the user, and the gateway configuration is loaded according to the hierarchy information, so that the utilization rate of the CDN gateway configuration is increased, and the cost of node operation and maintenance is reduced.
And S24, loading gateway configuration corresponding to the hierarchy information in the first target node.
In this embodiment of the present application, each gateway configuration is distinguished by a domain name requested by a user and hierarchical information, and a gateway generally manages the gateway configuration in a multi-module storage manner, as shown in fig. 5, which is a schematic view of a cache module of a gateway configuration provided by the present application, where a local cache module is characterized by fast reading and writing and high efficiency in processing a request, but a storage space is limited, resulting in limited stored gateway configurations, and generally only caches a hotspot gateway configuration, that is, a gateway configuration whose number of times of loading exceeds a predetermined number of times within a period of time, for example, 3 times, so that the local cache module can help a hotspot gateway to efficiently load its corresponding gateway configuration; the shared cache module is characterized in that the storage space is larger than that of the local cache module, and the loaded gateway configuration is usually stored for a period of time, so that the shared cache module comprises the gateway configuration in the local cache module; the disk module has the largest storage space among the three cache modules, the stored gateway configuration exists in a file form, the disk module of each node fixedly issues the whole amount of the four gateway configurations, but the read and write operations of the disk module are relatively slow, so the disk module is used as backup storage.
After determining the hierarchy information corresponding to the first target node, the gateway loading the gateway configuration corresponding to the hierarchy information may specifically be that, first, the gateway preferentially queries a local cache module, and determines whether the gateway configuration corresponding to the hierarchy information exists in the local cache module; if not, the shared cache module is continuously inquired, if the inquiry is still failed, the disk module is continuously inquired, and after the inquiry is successful, the gateway configuration in the local cache module or the shared cache module is updated.
By the method, the gateway configuration of the level corresponding to the full-scale domain name is provided, and the gateway configuration is cooperatively loaded based on the multi-cache module, so that the issuing and loading modes of all level node gateway configurations are unified, the operation and maintenance pressure of the nodes is reduced, and the gateway configuration is efficiently and quickly loaded.
Further, after the gateway configuration corresponding to the first target node hierarchy information is loaded, the first target node processes the user request according to a processing rule corresponding to the gateway configuration.
In the embodiment of the application, firstly, the gateway sends a resource request to the store-back-source module, after receiving the request, the store-back-source module queries local resources according to keywords of a user request, such as a face picture, and judges whether the user request is processed, if so, the processed result is returned to the user; if not, determining second target node information according to the current hop count information, and indicating the first target node to send the user request to the second target node information, specifically:
after receiving the current hop count information, the node scheduling platform may determine a resource access path corresponding to the first target node according to the current hop count information, so as to determine second target node information according to the resource access path, and send the second target node information to the store-back-source module, as shown in fig. 6, for the structural schematic diagram of the store-back-source module provided by the present application, after the store-back-source module receives the second target node information, the first target node may establish a communication connection with the second target node information, and send a user request to the second target node information through the communication connection.
By the gateway configuration method, the gateway configuration of the hierarchy corresponding to the full-scale domain name is provided, the issuing and loading modes of all hierarchy node gateway configurations are unified based on multi-module collaborative loading gateway configuration, the operation and maintenance pressure of the nodes is reduced, and meanwhile, different gateway configurations can be loaded by the gateway according to different user requests, so that the first target node can adapt to more types of user requests, the situation that the local hierarchy node is over-loaded or over-loaded is avoided when the scene with high concurrency and request peak is faced, the utilization rate of CDN gateway configuration is enhanced, and the cost of node operation and maintenance is reduced.
In order to more clearly understand the above method, with reference to fig. 7, an execution sequence of the entire gateway configuration method is understood, as shown in fig. 7, which is a flowchart of a gateway configuration method provided in the present application, specifically:
when a user request reaches a first target node, the first target node firstly analyzes historical hop count information of a user request header field, meanwhile, the historical hop count information is updated to obtain current hop count information and is sent to a node scheduling platform, and node level information and second target node information are requested from the node scheduling platform;
after receiving the current hop count information, the node scheduling platform determines a resource access path from a first target node to the source station according to the current hop count information, determines level information and second target position information corresponding to the first target node according to the resource access path, and returns the level information and the second target position information to the first target node;
after receiving the level information, the first target node inquires the gateway level configuration from a local cache module according to the domain name requested by the user, and if the configuration object is hit, the gateway loads the gateway level configuration corresponding to the user request; if the configuration object is not hit, inquiring gateway level configuration from a next level cache module;
after the first target node loads the gateway level configuration corresponding to the user request, the user request is processed according to the processing rule of the gateway level configuration, namely, the local resource is inquired according to the user request, and if the resource is hit, the result is responded to the user side; and if the resources are not hit, initiating a source returning request to the second target node according to the received second target node information.
Based on the same inventive concept, an embodiment of the present application further provides a gateway configuration apparatus, as shown in fig. 8, which is a schematic structural diagram of the gateway configuration apparatus in the present application, and the apparatus includes:
the first determining module 81 is configured to determine, when a user request is obtained, a first target node corresponding to the user request;
an analyzing module 82, configured to instruct the first target node to analyze current hop count information corresponding to the user request, where the current hop count information represents location information of the first target node;
a second determining module 83, configured to determine, according to the current hop count information, hierarchical information corresponding to the first target node;
a loading module 84, configured to load, in the first target node, the gateway configuration corresponding to the hierarchy information.
In one possible design, the parsing module 82 is specifically configured to:
instructing the first target node to analyze historical hop count information corresponding to the user request, wherein the historical hop count information represents node position information before the user request reaches the first target node;
and increasing a preset value to the historical hop count information to obtain the current hop count information.
In a possible design, the second determining module 83 is specifically configured to:
determining a resource access path corresponding to the first target node according to the current hop count information;
and determining the hierarchical information corresponding to the first target node according to the resource access path.
In one possible design, the loading module 84 is specifically configured to:
judging whether gateway configuration corresponding to the hierarchy information exists in a local cache module;
if yes, loading the gateway configuration in the first target node;
if not, searching the gateway configuration from a next-level cache module until the gateway configuration is searched, wherein the next-level cache module comprises the data in the local cache module.
In one possible design, the apparatus further includes:
processing the user request according to a processing rule corresponding to the gateway configuration;
judging whether the user request is processed;
if so, returning the processed result to the user;
if not, determining second target node information according to the current hop count information, and indicating the first target node to send the user request to the second target node information.
By the gateway configuration device, the gateway of the first target node can load different gateway configurations according to different user requests, so that the first target node can adapt to more various user requests, the situation that local level nodes are excessively loaded or excessively loaded is avoided when a scene with high concurrency and request peak is faced, the utilization rate of CDN gateway configuration is increased, and the cost of node operation and maintenance is reduced.
Based on the same inventive concept, an embodiment of the present application further provides an electronic device, where the electronic device may implement the function of the gateway configuration apparatus, and with reference to fig. 9, the electronic device includes:
at least one processor 91 and a memory 92 connected to the at least one processor 91, in this embodiment, a specific connection medium between the processor 91 and the memory 92 is not limited, and fig. 9 illustrates a connection between the processor 91 and the memory 92 through a bus 90. The bus 90 is shown in fig. 9 by a thick line, and the connection between other components is merely illustrative and not intended to be limiting. The bus 90 may be divided into an address bus, a data bus, a control bus, etc., and is shown with only one thick line in fig. 9 for ease of illustration, but does not represent only one bus or type of bus. Alternatively, the processor 91 may also be referred to as a controller, without limitation to name a few.
In the embodiment of the present application, the memory 92 stores instructions executable by the at least one processor 91, and the at least one processor 91 can execute the gateway configuration method discussed above by executing the instructions stored in the memory 92. The processor 91 may implement the functions of the respective modules in the apparatus shown in fig. 8.
The processor 91 is a control center of the apparatus, and may connect various parts of the entire control device by using various interfaces and lines, and perform various functions of the apparatus and process data by operating or executing instructions stored in the memory 92 and calling up data stored in the memory 92, thereby performing overall monitoring of the apparatus.
In one possible design, processor 91 may include one or more processing units, and processor 91 may integrate an application processor, which primarily handles operating systems, user interfaces, application programs, and the like, and a modem processor, which primarily handles wireless communications. It will be appreciated that the modem processor described above may not be integrated into the processor 91. In some embodiments, the processor 91 and the memory 92 may be implemented on the same chip, or in some embodiments, they may be implemented separately on separate chips.
The processor 91 may be a general-purpose processor, such as a Central Processing Unit (CPU), digital signal processor, application specific integrated circuit, field programmable gate array or other programmable logic device, discrete gate or transistor logic, discrete hardware components, or the like, that may implement or perform the methods, steps, and logic blocks disclosed in embodiments of the present application. The general purpose processor may be a microprocessor or any conventional processor or the like. The steps of the gateway configuration method disclosed in the embodiments of the present application may be directly implemented by a hardware processor, or implemented by a combination of hardware and software modules in the processor.
Memory 92, which is a non-volatile computer-readable storage medium, may be used to store non-volatile software programs, non-volatile computer-executable programs, and modules. The Memory 92 may include at least one type of storage medium, and may include, for example, a flash Memory, a hard disk, a multimedia card, a card-type Memory, a Random Access Memory (RAM), a Static Random Access Memory (SRAM), a Programmable Read Only Memory (PROM), a Read Only Memory (ROM), a charge Erasable Programmable Read Only Memory (EEPROM), a magnetic Memory, a magnetic disk, an optical disk, and the like. The memory 92 is any other medium that can be used to carry or store desired program code in the form of instructions or data structures and that can be accessed by a computer, but is not limited to such. The memory 92 in the embodiments of the present application may also be circuitry or any other device capable of performing a storage function for storing program instructions and/or data.
The processor 91 is programmed to solidify the codes corresponding to the gateway configuration method described in the foregoing embodiment into the chip, so that the chip can execute the steps of the gateway configuration method of the embodiment shown in fig. 2 when running. How the processor 91 is designed and programmed is well known to those skilled in the art and will not be described in detail here.
Based on the same inventive concept, the present application also provides a storage medium storing computer instructions, which when executed on a computer, cause the computer to perform the gateway configuration method discussed above.
In some possible embodiments, the aspects of the gateway configuration method provided in the present application may also be implemented in the form of a program product, which includes program code for causing the control apparatus to perform the steps in the gateway configuration method according to various exemplary embodiments of the present application described above in this specification, when the program product is run on an apparatus.
As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and so forth) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
It will be apparent to those skilled in the art that various changes and modifications may be made in the present application without departing from the spirit and scope of the application. Thus, if such modifications and variations of the present application fall within the scope of the claims of the present application and their equivalents, the present application is intended to include such modifications and variations as well.

Claims (10)

1. A method for configuring a gateway, the method comprising:
when a user request is obtained, determining a first target node corresponding to the user request;
indicating the first target node to analyze current hop count information corresponding to the user request, wherein the current hop count information represents position information of the first target node;
determining the level information corresponding to the first target node according to the current hop count information;
and loading the gateway configuration corresponding to the hierarchy information in the first target node.
2. The method of claim 1, wherein said instructing the first target node to parse current hop count information corresponding to the user request comprises:
instructing the first target node to analyze historical hop count information corresponding to the user request, wherein the historical hop count information represents node position information before the user request reaches the first target node;
and increasing a preset value to the historical hop count information to obtain the current hop count information.
3. The method of claim 1, wherein the determining the hierarchy information corresponding to the first target node according to the current hop count information comprises:
determining a resource access path corresponding to the first target node according to the current hop count information;
and determining the level information corresponding to the first target node according to the resource access path.
4. The method as claimed in claim 1, wherein said loading, in the first target node, the gateway configuration corresponding to the hierarchy information comprises:
judging whether gateway configuration corresponding to the level information exists in a local cache module;
if yes, loading the gateway configuration in the first target node;
if not, searching the gateway configuration from a next-level cache module until the gateway configuration is searched, wherein the next-level cache module comprises the data in the local cache module.
5. The method of claim 1, wherein after the loading the gateway configuration corresponding to the hierarchy information, further comprising:
processing the user request according to a processing rule corresponding to the gateway configuration;
judging whether the user request is processed;
if so, returning the processed result to the user;
if not, determining second target node information according to the current hop count information, and indicating the first target node to send the user request to the second target node information.
6. An apparatus for gateway configuration, the apparatus comprising:
the first determining module is used for determining a first target node corresponding to a user request when the user request is obtained;
the analysis module is used for indicating the first target node to analyze current hop count information corresponding to the user request, wherein the current hop count information represents the position information of the first target node;
the second determining module is used for determining the hierarchy information corresponding to the first target node according to the current hop count information;
and the loading module is used for loading the gateway configuration corresponding to the hierarchy information in the first target node.
7. The apparatus of claim 6, wherein the parsing module is specifically configured to:
instructing the first target node to analyze historical hop count information corresponding to the user request, wherein the historical hop count information represents node position information before the user request reaches the first target node;
and increasing a preset value to the historical hop count information to obtain the current hop count information.
8. The apparatus of claim 6, wherein the second determining module is specifically configured to:
determining a resource access path corresponding to the first target node according to the current hop count information;
and determining the hierarchical information corresponding to the first target node according to the resource access path.
9. An electronic device, comprising:
a memory for storing a computer program;
a processor for implementing the method steps of any one of claims 1-5 when executing the computer program stored on the memory.
10. A computer-readable storage medium, characterized in that a computer program is stored in the computer-readable storage medium, which computer program, when being executed by a processor, carries out the method steps of any one of claims 1-5.
CN202210858525.3A 2022-07-20 2022-07-20 Gateway configuration method and device and electronic equipment Pending CN115225490A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210858525.3A CN115225490A (en) 2022-07-20 2022-07-20 Gateway configuration method and device and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210858525.3A CN115225490A (en) 2022-07-20 2022-07-20 Gateway configuration method and device and electronic equipment

Publications (1)

Publication Number Publication Date
CN115225490A true CN115225490A (en) 2022-10-21

Family

ID=83614329

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210858525.3A Pending CN115225490A (en) 2022-07-20 2022-07-20 Gateway configuration method and device and electronic equipment

Country Status (1)

Country Link
CN (1) CN115225490A (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110830564A (en) * 2019-10-30 2020-02-21 北京金山云网络技术有限公司 CDN scheduling method, device, system and computer readable storage medium
CN114466031A (en) * 2021-12-27 2022-05-10 天翼云科技有限公司 CDN system node configuration method, device, equipment and storage medium
CN114466000A (en) * 2021-12-22 2022-05-10 天翼云科技有限公司 CDN gateway source returning method and device
CN114500460A (en) * 2021-12-27 2022-05-13 天翼云科技有限公司 CDN network and automatic scheduling method for node return upper layer request thereof
CN114531379A (en) * 2021-12-30 2022-05-24 爱普(福建)科技有限公司 Remote operation and maintenance method and system for edge gateway
CN114553727A (en) * 2022-02-18 2022-05-27 网宿科技股份有限公司 Data processing method and device based on content distribution network

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110830564A (en) * 2019-10-30 2020-02-21 北京金山云网络技术有限公司 CDN scheduling method, device, system and computer readable storage medium
CN114466000A (en) * 2021-12-22 2022-05-10 天翼云科技有限公司 CDN gateway source returning method and device
CN114466031A (en) * 2021-12-27 2022-05-10 天翼云科技有限公司 CDN system node configuration method, device, equipment and storage medium
CN114500460A (en) * 2021-12-27 2022-05-13 天翼云科技有限公司 CDN network and automatic scheduling method for node return upper layer request thereof
CN114531379A (en) * 2021-12-30 2022-05-24 爱普(福建)科技有限公司 Remote operation and maintenance method and system for edge gateway
CN114553727A (en) * 2022-02-18 2022-05-27 网宿科技股份有限公司 Data processing method and device based on content distribution network

Similar Documents

Publication Publication Date Title
CN108173698B (en) Network service management method, device, server and storage medium
CN111522636B (en) Application container adjusting method, application container adjusting system, computer readable medium and terminal device
CN104954468A (en) Resource allocation method and resource allocation device
CN106713028B (en) Service degradation method and device and distributed task scheduling system
CN102821113A (en) Cache method and system
CN111666131A (en) Load balancing distribution method and device, computer equipment and storage medium
CN110035306A (en) Dispositions method and device, the dispatching method and device of file
CN112256433B (en) Partition migration method and device based on Kafka cluster
CN111562889B (en) Data processing method, device, system and storage medium
CN112988378A (en) Service processing method and device
CN114595043A (en) IO (input/output) scheduling method and device
CN112269661A (en) Partition migration method and device based on Kafka cluster
CN109327506A (en) A kind of resource allocation methods, device and readable storage medium storing program for executing
CN108399175B (en) Data storage and query method and device
CN111556123A (en) Self-adaptive network rapid configuration and load balancing system based on edge calculation
CN115225490A (en) Gateway configuration method and device and electronic equipment
CN110581873B (en) Cross-cluster redirection method and monitoring server
CN116226071A (en) Data statistics method, device, equipment and storage medium
CN114466031B (en) CDN system node configuration method, device, equipment and storage medium
CN112860720B (en) Storage capacity updating method and device
CN114490458A (en) Data transmission method, chip, server and storage medium
CN103838682A (en) File directory reading method and equipment
CN114040378A (en) Application arranging method and device, computer equipment and storage medium
CN115033551A (en) Database migration method and device, electronic equipment and storage medium
CN105072047A (en) Message transmitting and processing method

Legal Events

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