CN113271260A - Load balancing processing method, device, equipment and storage medium - Google Patents

Load balancing processing method, device, equipment and storage medium Download PDF

Info

Publication number
CN113271260A
CN113271260A CN202110514177.3A CN202110514177A CN113271260A CN 113271260 A CN113271260 A CN 113271260A CN 202110514177 A CN202110514177 A CN 202110514177A CN 113271260 A CN113271260 A CN 113271260A
Authority
CN
China
Prior art keywords
target
access request
application access
forwarding
load
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
CN202110514177.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.)
Kangjian Information Technology Shenzhen Co Ltd
Original Assignee
Kangjian Information Technology Shenzhen 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 Kangjian Information Technology Shenzhen Co Ltd filed Critical Kangjian Information Technology Shenzhen Co Ltd
Priority to CN202110514177.3A priority Critical patent/CN113271260A/en
Publication of CN113271260A publication Critical patent/CN113271260A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/10Flow control; Congestion control
    • H04L47/12Avoiding congestion; Recovering from congestion
    • H04L47/125Avoiding congestion; Recovering from congestion by balancing the load, e.g. traffic engineering
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • G06F2009/4557Distribution of virtual machine instances; Migration and load balancing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • G06F2009/45595Network integration; Enabling network access in virtual machine instances

Abstract

The invention relates to the technical field of cloud services, is applied to the field of intelligent medical treatment, and discloses a load balancing processing method, device, equipment and storage medium, which are used for shortening a load balancing network link. The load balancing processing method comprises the following steps: forwarding the application access request to a content exchange virtual machine through a preset application switch; extracting a convergence domain name address and a redirection address from the application access request through a content exchange virtual machine; matching and analyzing the strategy binding rule corresponding to the content exchange virtual machine according to the convergence domain name address and the redirection address to obtain a target load forwarding strategy; and forwarding the application access request to a target virtual host according to a target load forwarding strategy, forwarding the application access request to a target reverse proxy through the target virtual host, and performing load balancing processing on the application access request through the target reverse proxy. In addition, the invention also relates to a block chain technology, and the strategy binding rule can be stored in the block chain node.

Description

Load balancing processing method, device, equipment and storage medium
Technical Field
The invention relates to the field of service data distribution of cloud services, in particular to a load balancing processing method, device, equipment and storage medium.
Background
With the rise of the orchestration management tool k8s cloud native, more and more companies join their camps. However, in k8s, there are often applications or clusters that are not enough to fit into the container, and need to be migrated gradually, and the applications or clusters switch between the original vm solution and the new k8 s.
vm and k8s switching problems can be realized by common load balancing equipment, k8s can realize load balancing based on reverse proxy load balancer ingress, and the original vm realizes load balancing based on reverse proxy network server nginx. In this case, the general company is responsible for load balancing of k8s by accessing ingress after nginx load balancing. Although the solution is simple, the network performance loss is large due to the lengthening of the load balancing network link.
Disclosure of Invention
The invention provides a load balancing processing method, a device, equipment and a storage medium, which are used for shortening a load balancing network link and reducing network performance loss.
In order to achieve the above object, a first aspect of the present invention provides a load balancing processing method, including: receiving an application access request, and forwarding the application access request to a content exchange virtual machine through a preset application switch; extracting, by the content exchange virtual machine, a converged domain name address and a redirection address from the application access request; matching and analyzing a policy binding rule corresponding to the content exchange virtual machine according to the convergence domain name address and the redirection address to obtain a target load forwarding policy, wherein the policy binding rule corresponding to the content exchange virtual machine comprises a plurality of load forwarding policies and a plurality of pattern matching data sets, and each load forwarding policy corresponds to each pattern matching data set one by one; and forwarding the application access request to a target virtual host according to the target load forwarding strategy, forwarding the application access request to a target reverse proxy through the target virtual host, and performing load balancing processing on the application access request through the target reverse proxy.
Optionally, in a first implementation manner of the first aspect of the present invention, the receiving an application access request, and forwarding the application access request to a content switching virtual machine through a preset application switch includes: receiving an application access request, intercepting the application access request through a preset application switch, and acquiring terminal address information; judging whether the application access request is abnormal or not according to the terminal address information; if the application access request is abnormal, generating and recording request abnormal information, and sending the request abnormal information to a terminal; if the application access request is not abnormal, the application access request is forwarded to a content exchange virtual machine through the preset application switch according to a preset binding relationship, and the preset binding relationship is used for indicating the association mapping between the content exchange virtual machine and the preset application switch.
Optionally, in a second implementation manner of the first aspect of the present invention, the extracting, by the content exchange virtual machine, a converged domain name address and a redirection address from the application access request includes: setting a uniform resource positioning object for the application access request according to a preset construction function through the content exchange virtual machine, and calling a domain name acquisition function based on the uniform resource positioning object to obtain a convergence domain name address; and extracting a redirection address from the application access request according to a preset regular matching rule, wherein the preset regular matching rule is used for indicating character matching and segmentation processing of the application access request.
Optionally, in a third implementation manner of the first aspect of the present invention, the performing matching analysis on the policy binding rule corresponding to the content exchange virtual machine according to the convergence domain name address and the redirection address to obtain a target load forwarding policy, where the policy binding rule corresponding to the content exchange virtual machine includes a plurality of load forwarding policies and a plurality of pattern matching data sets, and each load forwarding policy corresponds to each pattern matching data set one by one, and the method includes: matching and analyzing the strategy binding rules corresponding to the content exchange virtual machine based on the convergence domain name address to obtain a plurality of load forwarding strategies and a plurality of pattern matching data sets which are associated and bound with the convergence domain name address, wherein each load forwarding strategy has a corresponding priority value and a corresponding unique identifier, and each load forwarding strategy corresponds to each pattern matching data set one by one; sequentially accessing each load forwarding strategy according to the priority value corresponding to each load forwarding strategy from low to high, and judging whether the redirection address exists in the mode matching data set corresponding to each load forwarding strategy or not; and if the redirection address exists in the pattern matching data set corresponding to each load forwarding strategy, determining a target pattern matching data set, and determining a target load forwarding strategy according to the target pattern matching data set.
Optionally, in a fourth implementation manner of the first aspect of the present invention, the forwarding the application access request to a target vm according to the target load forwarding policy, forwarding the application access request to a target reverse proxy through the target vm, and performing load balancing processing on the application access request through the target reverse proxy includes: acquiring a strategy identifier corresponding to the target load forwarding strategy, inquiring preset configuration information according to the strategy identifier to obtain a target virtual host, and forwarding the application access request to the target virtual host; when the application access request reaches the target virtual host, the application access request is transmitted to a target reverse proxy through the target virtual host, and the target virtual host and the target reverse proxy are in one-to-one correspondence; when the application access request reaches the target reverse proxy, the application access request is distributed and sent to a target host through the target reverse proxy, and the target host belongs to a preset distributed cluster.
Optionally, in a fifth implementation manner of the first aspect of the present invention, before the receiving an application access request and forwarding the application access request to a content switching virtual machine through a preset application switch, the load balancing processing method further includes: acquiring the convergence domain name address and the service type, adding at least one pattern matching data set according to the convergence domain name address and the service type, and performing data initialization on the at least one pattern matching data set; setting at least one load forwarding strategy according to the convergence domain name address and the service type, and associating and binding each load forwarding strategy and each mode matching data set; and performing associated mapping processing on each load forwarding strategy, the content exchange virtual machine and the target virtual host, and distributing a corresponding priority value to each load forwarding strategy according to a preset priority distribution rule.
Optionally, in a sixth implementation manner of the first aspect of the present invention, after the forwarding the application access request to the target vm according to the target load forwarding policy, forwarding the application access request to the target reverse proxy through the target vm, and performing load balancing processing on the application access request through the target reverse proxy, the load balancing processing method further includes: acquiring a load balancing access log, and performing data mining and analysis on the load balancing access log according to a preset machine learning algorithm to obtain a target access data volume, wherein the target access data volume is used for indicating the number of application access requests and the distribution number of target reverse agents within a preset time length; and sending the target access data volume to a terminal so that the terminal generates and displays a thermodynamic diagram according to the target access data volume.
A second aspect of the present invention provides a load balancing processing apparatus, including: the system comprises a receiving module, a content switching virtual machine and a content switching module, wherein the receiving module is used for receiving an application access request and forwarding the application access request to the content switching virtual machine through a preset application switch; an extraction module, configured to extract a converged domain name address and a redirection address from the application access request through the content exchange virtual machine; the analysis module is used for performing matching analysis on the policy binding rules corresponding to the content exchange virtual machine according to the convergence domain name address and the redirection address to obtain a target load forwarding policy, wherein the policy binding rules corresponding to the content exchange virtual machine comprise a plurality of load forwarding policies and a plurality of pattern matching data sets, and each load forwarding policy corresponds to each pattern matching data set one by one; and the processing module is used for forwarding the application access request to a target virtual host according to the target load forwarding strategy, forwarding the application access request to a target reverse proxy through the target virtual host, and performing load balancing processing on the application access request through the target reverse proxy.
Optionally, in a first implementation manner of the second aspect of the present invention, the receiving module is specifically configured to: receiving an application access request, intercepting the application access request through a preset application switch, and acquiring terminal address information; judging whether the application access request is abnormal or not according to the terminal address information; if the application access request is abnormal, generating and recording request abnormal information, and sending the request abnormal information to a terminal; if the application access request is not abnormal, the application access request is forwarded to a content exchange virtual machine through the preset application switch according to a preset binding relationship, and the preset binding relationship is used for indicating the association mapping between the content exchange virtual machine and the preset application switch.
Optionally, in a second implementation manner of the second aspect of the present invention, the extraction module is specifically configured to: setting a uniform resource positioning object for the application access request according to a preset construction function through the content exchange virtual machine, and calling a domain name acquisition function based on the uniform resource positioning object to obtain a convergence domain name address; and extracting a redirection address from the application access request according to a preset regular matching rule, wherein the preset regular matching rule is used for indicating character matching and segmentation processing of the application access request.
Optionally, in a third implementation manner of the second aspect of the present invention, the analysis module is specifically configured to: matching and analyzing the strategy binding rules corresponding to the content exchange virtual machine based on the convergence domain name address to obtain a plurality of load forwarding strategies and a plurality of pattern matching data sets which are associated and bound with the convergence domain name address, wherein each load forwarding strategy has a corresponding priority value and a corresponding unique identifier, and each load forwarding strategy corresponds to each pattern matching data set one by one; sequentially accessing each load forwarding strategy according to the priority value corresponding to each load forwarding strategy from low to high, and judging whether the redirection address exists in the mode matching data set corresponding to each load forwarding strategy or not; and if the redirection address exists in the pattern matching data set corresponding to each load forwarding strategy, determining a target pattern matching data set, and determining a target load forwarding strategy according to the target pattern matching data set.
Optionally, in a fourth implementation manner of the second aspect of the present invention, the processing module is specifically configured to: acquiring a strategy identifier corresponding to the target load forwarding strategy, inquiring preset configuration information according to the strategy identifier to obtain a target virtual host, and forwarding the application access request to the target virtual host; when the application access request reaches the target virtual host, the application access request is transmitted to a target reverse proxy through the target virtual host, and the target virtual host and the target reverse proxy are in one-to-one correspondence; when the application access request reaches the target reverse proxy, the application access request is distributed and sent to a target host through the target reverse proxy, and the target host belongs to a preset distributed cluster.
Optionally, in a fifth implementation manner of the second aspect of the present invention, the load balancing processing apparatus further includes: the initialization module is used for acquiring the convergence domain name address and the service type, adding at least one pattern matching data set according to the convergence domain name address and the service type, and performing data initialization on the at least one pattern matching data set; a binding module, configured to set at least one load forwarding policy according to the converged domain name address and the service type, and associate and bind each load forwarding policy with each pattern matching data set; and the distribution module is used for performing associated mapping processing on each load forwarding strategy, the content exchange virtual machine and the target virtual host, and distributing a corresponding priority value to each load forwarding strategy according to a preset priority distribution rule.
Optionally, in a sixth implementation manner of the second aspect of the present invention, the load balancing processing apparatus further includes: the mining module is used for acquiring the load balancing access logs, and performing data mining and analysis on the load balancing access logs according to a preset machine learning algorithm to obtain a target access data volume, wherein the target access data volume is used for indicating the number of application access requests and the distribution number of target reverse agents within a preset time length; and the display module is used for sending the target access data volume to a terminal so that the terminal can generate and display a thermodynamic diagram according to the target access data volume.
A third aspect of the present invention provides a load balancing processing apparatus, including: a memory and at least one processor, the memory having instructions stored therein; the at least one processor calls the instruction in the memory to enable the load balancing processing equipment to execute the load balancing processing method.
A fourth aspect of the present invention provides a computer-readable storage medium having stored therein instructions, which, when run on a computer, cause the computer to execute the load balancing processing method described above.
In the technical scheme provided by the invention, an application access request is received and forwarded to a content exchange virtual machine through a preset application switch; extracting, by the content exchange virtual machine, a converged domain name address and a redirection address from the application access request; matching and analyzing a policy binding rule corresponding to the content exchange virtual machine according to the convergence domain name address and the redirection address to obtain a target load forwarding policy, wherein the policy binding rule corresponding to the content exchange virtual machine comprises a plurality of load forwarding policies and a plurality of pattern matching data sets, and each load forwarding policy corresponds to each pattern matching data set one by one; and forwarding the application access request to a target virtual host according to the target load forwarding strategy, forwarding the application access request to a target reverse proxy through the target virtual host, and performing load balancing processing on the application access request through the target reverse proxy. In the embodiment of the invention, the content is forwarded to the content exchange virtual machine through a preset application switch; matching and analyzing a strategy binding rule corresponding to the content exchange virtual machine according to the convergence domain name address and the redirection address to obtain a target load forwarding strategy; and forwarding the application access request to a target virtual host according to a target load forwarding strategy, forwarding the application access request to a target reverse proxy through the target virtual host, and performing load balancing processing on the application access request through the target reverse proxy. And the virtualization technology is smoothly switched and applied according to the service requirements, so that the load balancing network link is shortened, and the network performance loss is reduced.
Drawings
Fig. 1 is a schematic diagram of an embodiment of a load balancing processing method according to an embodiment of the present invention;
fig. 2 is a schematic diagram of another embodiment of a load balancing processing method according to an embodiment of the present invention;
fig. 3 is a schematic diagram of an embodiment of a load balancing processing apparatus according to an embodiment of the present invention;
fig. 4 is a schematic diagram of another embodiment of the load balancing processing apparatus according to the embodiment of the present invention;
fig. 5 is a schematic diagram of an embodiment of a load balancing processing device in the embodiment of the present invention.
Detailed Description
The embodiment of the invention provides a load balancing processing method, a device, equipment and a storage medium, which are used for smoothly switching application virtualization technology according to business requirements, shortening a load balancing network link and reducing network performance loss.
The terms "first," "second," "third," "fourth," and the like in the description and in the claims, as well as in the drawings, if any, are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It will be appreciated that the data so used may be interchanged under appropriate circumstances such that the embodiments described herein may be practiced otherwise than as specifically illustrated or described herein. Furthermore, the terms "comprises," "comprising," or "having," and any variations thereof, are intended to cover non-exclusive inclusions, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
For convenience of understanding, a specific flow of the embodiment of the present invention is described below, and referring to fig. 1, an embodiment of the load balancing processing method in the embodiment of the present invention includes:
101. and receiving an application access request, and forwarding the application access request to the content switching virtual machine through a preset application switch.
The application access request is used to indicate a service operation uniform resource locator sent by one or more terminals, for example, the application access request may be used to request an online medical service, a medical and electronic commerce service, and may also be used to request a health education service, which is not limited herein. The preset application switch is used for intercepting and verifying the application access request, and the preset application switch may be a hardware load balancing switch netscaler or other load balancing switches, which is not limited herein. The content exchange virtual machine is used for carrying out load balancing processing on the application access request. Specifically, the server receives an application access request and acquires terminal address information; the server judges whether a preset network protocol address information table has terminal address information or not; if the preset network protocol address information table has terminal address information, the server forwards the terminal address information to a content exchange virtual machine through a preset application switch, and the content exchange virtual machine is used for indicating to perform domain name resolution and load balancing processing on the application access request. For example, when the application access request sent by the terminal is http:// srv. pajk-ent.com/timer, and the http:// srv. pajk-ent.com/timer reaches a hardware load balancing switch (i.e., a preset application switch) netscaler in the server, the server performs verification and/or forwarding processing on the application access request through the netscaler.
It is to be understood that the execution subject of the present invention may be a load balancing processing apparatus, and may also be a terminal or a server, which is not limited herein. The embodiment of the present invention is described by taking a server as an execution subject.
102. The converged domain name address and the redirection address are extracted from the application access request by the content exchange virtual machine.
The application side inquiry request may be a get request mode or a post request sending mode, and is not limited herein. The application access request includes a converged domain name address, a redirection address, and parameter information. For example, when the application access request is in a get request mode, the application access request is http:// srv. Specifically, the server acquires the application access request through a preset full path acquisition function, where the preset full path acquisition function may be a request. Then, the server resolves the application access request according to the hypertext transfer protocol by a content exchange virtual machine (for example, cs _1b) to obtain a convergence domain name address and a redirection address, wherein the convergence domain name address is srv.
103. And matching and analyzing the strategy binding rules corresponding to the content exchange virtual machine according to the convergence domain name address and the redirection address to obtain a target load forwarding strategy, wherein the strategy binding rules corresponding to the content exchange virtual machine comprise a plurality of load forwarding strategies and a plurality of pattern matching data sets, and each load forwarding strategy corresponds to each pattern matching data set one by one.
Wherein, the content exchange virtual machine is used for realizing seven-layer load balancing. Specifically, the server sets a plurality of policy identifiers and a plurality of pattern identifiers according to a convergent domain name address and according to a preset policy generation rule and a preset pattern generation rule, the server performs matching analysis on policy binding rules corresponding to the content exchange virtual machine according to the policy identifiers and the pattern identifiers to obtain a plurality of load forwarding policies and a plurality of pattern matching data sets, and each load forwarding policy location corresponds to each pattern matching data set patset one by one, for example, the server establishes a vm patset for a location where a certain domain name needs to access a virtual machine service type vm, and establishes a k8s patset for a location where a container service type k8s needs to be accessed; the server accesses each load forwarding policy in a traversal manner from low to high according to the priority corresponding to each load forwarding policy, and when a pattern matching data set corresponding to each load forwarding policy contains a redirection address, the server determines that the load forwarding policy corresponding to the pattern matching data set is a target policy (i.e., a target load forwarding policy) to obtain a target policy identifier, where the target policy identifier may be a name of each load forwarding policy. Further, the server stores the policy binding rule in a blockchain database, which is not limited herein.
104. And forwarding the application access request to a target virtual host according to a target load forwarding strategy, forwarding the application access request to a target reverse proxy through the target virtual host, and performing load balancing processing on the application access request through the target reverse proxy.
The target virtual host belongs to a netscaler, and includes a virtual host of a virtual machine service type vm and a virtual host of a container service type k8s (i.e., kubernets), and the target virtual host can be used to serve operators. Specifically, the server performs load forwarding processing on the application access request according to a target load forwarding policy and a target pattern matching data set patset (that is, the server determines a target virtual host from a plurality of virtual hosts), and when the target virtual host receives the application access request, the server forwards the application access request to a target reverse proxy (e.g., ingress or nginx) through the target virtual host, where the target virtual host and the target reverse proxy are in one-to-one correspondence, for example, a target reverse proxy corresponding to a vm-type target virtual host is vm/nginx, and a target reverse proxy corresponding to a k8 s-type target virtual host is k8 s/ingress; then, the server performs load balancing processing on the application access request through the target reverse proxy.
In the embodiment of the invention, the content is forwarded to the content exchange virtual machine through a preset application switch; matching and analyzing a strategy binding rule corresponding to the content exchange virtual machine according to the convergence domain name address and the redirection address to obtain a target load forwarding strategy; and forwarding the application access request to a target virtual host according to a target load forwarding strategy, forwarding the application access request to a target reverse proxy through the target virtual host, and performing load balancing processing on the application access request through the target reverse proxy. And the virtualization technology is smoothly switched and applied according to the service requirements, so that the load balancing network link is shortened, and the network performance loss is reduced. This scheme can be applied to in the wisdom medical field to promote the construction in wisdom city.
Referring to fig. 2, another embodiment of the load balancing method according to the embodiment of the present invention includes:
201. acquiring a convergence domain name address and a service type, adding at least one pattern matching data set according to the convergence domain name address and the service type, and performing data initialization on the at least one pattern matching data set.
Specifically, the server sets a set name corresponding to at least one pattern matching data set patset according to the convergence domain name address and the service type, wherein the set name is used for indicating that the prefix, the convergence domain name address and the suffix are combined in a' splicing mode. The prefix may be p or policy, and is not specifically limited herein, and the suffix is a service type. Optionally, a converged domain name address may correspond to two sets of patset data, for example, the server performs add policy patset p _ testk8s _ dev _ pajkdc _ com _ vm to create a first set of pattern matching data named testk8s _ dev _ pajkdc _ com _ vm for storing domain name location under the domain name that needs to be forwarded to vm/nginx; or the server executes add policy patset p _ testk8s _ dev _ pajkdc _ com _ k8s for creating a second set of pattern matching data named testk8s _ dev _ pajkdc _ com _ k8s for storing the domain name location at the domain name that needs to be forwarded to k8 s/ingress. Then, the server initializes at least one pattern matching data set (e.g., a patset data set), that is, the server assigns a corresponding redirection address (redirection address is character string data) to the patset data set. When there is an add-drop-and-delete operation for an application, or vm and k8s migrate, it is sufficient for the server to maintain both patset data sets.
202. And setting at least one load forwarding strategy according to the convergence domain name address and the service type, and associating and binding each load forwarding strategy and each pattern matching data set.
Specifically, the server sets a policy name corresponding to each load forwarding policy according to the convergence domain name address and the service type, wherein the policy name is used for indicating that a prefix, the convergence domain name address and a suffix are spliced and combined according to a _'; then, the server sets at least one load forwarding strategy according to the strategy name corresponding to each load forwarding strategy, and associates and binds each load forwarding strategy and each pattern matching data set. The prefix may be a null value or other values, which is not specifically limited herein, and the suffix is a service type. One converged domain name address may set three load forwarding policies:
add cs policy srv_pajk-ent_com_VM-rule
"HTTP.REQ.HOSTNAME.EQ(\"srv.pajk-ent.com\")&&
HTTP.REQ.URL.PATH.GET(1).set_text_mode(IGNORECASE).EQUALS_ANY(\"p_srv_pajk-ent_com_VM\");
the instruction is used to create a first load forwarding policy srv _ pajk-ent _ com _ VM that handles only the p _ srv _ pajk-ent _ com _ VM domain name, and that first location belongs to the signature created VM patset of data (i.e., p _ srv _ pajk-ent _ com _ VM).
add cs policy srv_pajk-ent_com_k8s-rule
"HTTP.REQ.HOSTNAME.EQ(\"srv.pajk-ent.com\")&&
HTTP.REQ.URL.PATH.GET(1).set_text_mode(IGNORECASE).EQUALS_ANY(\"p_srv_pajk-ent_com_k8s\");
The instructions are used to create a second load forwarding policy srv _ pajk-ent _ com _ k8s that handles only the srv _ pajk-ent _ com _ k8s domain name, and the first location of which belongs to the signature built k8s patset of data (i.e., p _ srv _ pajk-ent _ com _ k8 s).
add cs policy srv_pajk-ent_com_Default-rule
"HTTP.REQ.HOSTNAME.EQ(\"srv.pajk-ent.com\")&&
HTTP.REQ.URL.STARTSWITH(\"/\")";
The instructions are for creating a third load forwarding policy srv _ pajk-ent _ com _ Default for handling srv.
203. And performing associated mapping processing on each load forwarding strategy, the content exchange virtual machine and the target virtual host, and distributing a corresponding priority value to each load forwarding strategy according to a preset priority distribution rule.
The server sets a priority for each load forwarding policy to implement a policy matching sequence by binding the priority specified when each load forwarding policy is bound. For example, the server sets vm to match first, k8s times match, and default last. The specific binding process is as follows:
bind cs vserver cs_lb–policyName srv_pajk-ent_com_vm-targetLBVserver vm_lb-priority 1;
the server executes the instruction to bind the first load forwarding policy srv _ pajk-ent _ com _ vm to the content exchange virtual machine cs _ lb, and the server transfers the traffic reaching the cs _ lb to the target virtual host vm _ lb and gives the highest priority value 1.
bind cs vserver cs_lb-policyName srv_pajk-ent_com_k8s-targetLBVserver k8s_lb-priority 2;
The server executes the instruction to bind the second load forwarding policy srv _ pajk-ent _ com _ k8s to the content exchange virtual machine cs _ lb, the server diverts traffic arriving at cs _ lb to the target virtual host k8s _ lb and assigns a next highest priority value of 2.
bind cs vserver cs_lb-policyName testk8s_dev_pajkdc_com_default-targetLBVserver vm_lb-priority 3;
The server executes the instruction to bind the third load forwarding policy testk8s _ dev _ pajkdc _ com _ default to the content switching virtual machine cs _ lb, and the server transfers the traffic arriving at the cs _ lb to the target virtual host vm _ lb and gives the lowest priority value of 3.
It should be noted that the cs _ lb may be a content exchange virtual machine corresponding to a certain operator, and is used to abstract three groups of virtual hosts into one combination. When the flow reaches cs _ lb, the server performs logic operation according to a preset operation rule through the cs _ lb, the preset operation rule is that a load forwarding strategy with low priority is matched first, and when the matching is successful, the server transfers the application access request to the matched load forwarding strategy targetLBVserver. The server binds the patset data set to the corresponding load forwarding policy so that the patset data set (i.e., the pattern matching data set) is validated. The server establishes three pattern matching data sets and three load forwarding strategies, namely, a vm set and a vm strategy, a k8s set and a k8s strategy, and a default set, wherein the default set adopts a default strategy for a character string "/"), associates the three pattern matching data sets and the three load forwarding strategies one by one, and finally, binds the one-to-one associated load forwarding strategies and the one-to-one associated pattern matching data sets to the same content exchange virtual machine.
204. And receiving an application access request, and forwarding the application access request to the content switching virtual machine through a preset application switch.
Further, the server identifies that the connection mode with the terminal is a hypertext transfer protocol proxy mode or a load balancing mode through a request header field XFF (namely, X-Forwarded-For); if the connection mode with the terminal is a hypertext transfer protocol proxy mode, the server calls a preset address to obtain a function request. If the connection mode with the terminal is a load balancing mode, the server acquires the request header field through the firewall and extracts the terminal address information from the request header field. Optionally, the server receives the application access request, intercepts the application access request through a preset application switch, and acquires the terminal address information; the server judges whether the application access request is abnormal or not according to the terminal address information, specifically, the server judges whether the terminal address information exists in a preset network protocol address information table or not, if the terminal address information does not exist in the preset network protocol address information table, the server determines that the application access request is abnormal, and if the terminal address information exists in the preset network protocol address information table, the server determines that the application access request is normal; if the application access request is abnormal, the server generates and records request abnormal information and sends the request abnormal information to the terminal, and further the terminal displays the request abnormal information and prompts that the access authority of the target user terminal is limited; if the application access request is not abnormal, the server forwards the application access request to the content exchange virtual machine through a preset application switch according to a preset binding relationship, wherein the preset binding relationship is used for indicating association mapping between the content exchange virtual machine and the preset application switch.
205. The converged domain name address and the redirection address are extracted from the application access request by the content exchange virtual machine.
Further, the server may further obtain the converged domain name address through a preset hostname obtaining function getRemoteHost (). Then the server obtains a rule to be checked corresponding to the convergence domain name address; the server checks the convergence domain name address according to the rule to be checked; and if the convergence domain name address does not pass the check, the server generates and records check failure information. Optionally, the server sets a uniform resource location object to the application access request according to a preset constructor through the content exchange virtual machine, and calls a domain name obtaining function based on the uniform resource location object to obtain a convergence domain name address; and the server extracts the redirection address from the application access request according to a preset regular matching rule, wherein the preset regular matching rule is used for indicating character matching and segmentation processing of the application access request.
For example, the application access request A is http:// srv. pajk-ent.com/timeline, the application access request B is http:// srv. pajk-ent.com/timeline/hellowrod.html, the application access request C is http:// srv. pajk-ent.com/timeline/hellowrod.htmlparam ═ 1, and the server performs character matching and segmentation processing on the application access request A, the application access request B and the application access request C respectively according to a preset regular matching rule to obtain the redirection addresses which are the timelines. Further, the server can also perform character case unified processing on the converged domain name address and the redirection address.
206. And matching and analyzing the strategy binding rules corresponding to the content exchange virtual machine according to the convergence domain name address and the redirection address to obtain a target load forwarding strategy, wherein the strategy binding rules corresponding to the content exchange virtual machine comprise a plurality of load forwarding strategies and a plurality of pattern matching data sets, and each load forwarding strategy corresponds to each pattern matching data set one by one.
That is, the server preferentially selects the load forwarding policy with low priority for policy matching, and further, the server may also sequentially access each domain name policy from low to high according to the priority value corresponding to each load forwarding policy. The pattern matching data set patset corresponding to each load forwarding policy is a character string data set, may be used to store any unrepeated character string, and is mainly used to store a redirection address location of a converged domain name address, where the location is a first character string of a slash/character partition in a uniform resource locator url, and a converged domain name address corresponds to multiple application programs. For example, when the terminal access form is srv.
Optionally, the server performs matching analysis on the policy binding rule corresponding to the content exchange virtual machine based on the converged domain name address to obtain a plurality of load forwarding policies and a plurality of pattern matching data sets associated and bound with the converged domain name address, where each load forwarding policy has a corresponding priority value and a corresponding unique identifier, and each load forwarding policy corresponds to each pattern matching data set one by one; the server sequentially accesses each load forwarding strategy according to the priority value corresponding to each load forwarding strategy from low to high, and judges whether a redirection address exists in a pattern matching data set corresponding to each load forwarding strategy or not; if the redirection address exists in the pattern matching data set corresponding to each load forwarding strategy, the server determines a target pattern matching data set and determines a target load forwarding strategy according to the target pattern matching data set.
It should be noted that the content exchange virtual machine may bind a plurality of load forwarding policies, and the execution order of each load forwarding policy is executed through a preset priority order, the server matches each load forwarding policy one by one according to the priority value, when the server matches the target policy through the converged domain name address and the redirection address, the server determines the target policy identifier, stops matching, and executes step 207 according to the target policy identifier. When the server is not matched with the target strategy through the convergence domain name address and the redirection address, the server determines to stop matching, the server generates prompt information, the server sends the prompt information to the terminal, and the prompt information is used for indicating that the application access request is not matched with the service server. And the target pattern matching data set are respectively bound with the convergence domain name, so that the load balance based on the domain name level is realized.
207. And forwarding the application access request to a target virtual host according to a target load forwarding strategy, forwarding the application access request to a target reverse proxy through the target virtual host, and performing load balancing processing on the application access request through the target reverse proxy.
Further, the server forwards the application access request to a target host corresponding to at least one preset distributed cluster through a target reverse proxy, and returns a response result of the target host to the terminal connected with the application access request. For example, for an application access request http:// Srv.pajk-ent.com/timeline, the server forwards the application access request onto the running instance pod of k8 s; the server forwards the application requests http:// Srv. pajk-ent.com/cc and http:// Srv. pajk-ent.com to the vm's machine instance.
Optionally, the server obtains a policy identifier corresponding to the target load forwarding policy, queries preset configuration information according to the policy identifier to obtain a target virtual host, and forwards the application access request to the target virtual host; when the application access request reaches the target virtual host, the server transparently transmits the application access request to the target reverse proxy through the target virtual host, and the target virtual host and the target reverse proxy are in one-to-one correspondence; when the application access request reaches the target reverse proxy, the server distributes the application access request through the target reverse proxy and sends the application access request to the target host, and the target host belongs to the preset distributed cluster.
Further, the server acquires the load balancing access logs, and performs data mining and analysis on the load balancing access logs according to a preset machine learning algorithm to obtain a target access data volume, wherein the target access data volume is used for indicating the number of application access requests and the distribution number of target reverse agents within a preset time length; and the server sends the target access data volume to the terminal so that the terminal generates and displays the thermodynamic diagram according to the target access data volume. The preset machine learning algorithm may include a decision tree algorithm, a bayesian classification algorithm, and may also include other machine learning algorithms, which is not limited herein.
In the embodiment of the invention, the content is forwarded to the content exchange virtual machine through a preset application switch; matching and analyzing a strategy binding rule corresponding to the content exchange virtual machine according to the convergence domain name address and the redirection address to obtain a target load forwarding strategy; and forwarding the application access request to a target virtual host according to a target load forwarding strategy, forwarding the application access request to a target reverse proxy through the target virtual host, and performing load balancing processing on the application access request through the target reverse proxy. And the virtualization technology is smoothly switched and applied according to the service requirements, so that the load balancing network link is shortened, and the network performance loss is reduced. This scheme can be applied to in the wisdom medical field to promote the construction in wisdom city.
With reference to fig. 3, the load balancing processing method in the embodiment of the present invention is described above, and a load balancing processing apparatus in the embodiment of the present invention is described below, where an embodiment of the load balancing processing apparatus in the embodiment of the present invention includes:
a receiving module 301, configured to receive an application access request, and forward the application access request to a content exchange virtual machine through a preset application switch;
an extracting module 302, configured to extract a converged domain name address and a redirection address from the application access request through the content exchange virtual machine;
the analysis module 303 is configured to perform matching analysis on the policy binding rule corresponding to the content exchange virtual machine according to the converged domain name address and the redirection address to obtain a target load forwarding policy, where the policy binding rule corresponding to the content exchange virtual machine includes a plurality of load forwarding policies and a plurality of pattern matching data sets, and each load forwarding policy corresponds to each pattern matching data set one to one;
the processing module 304 is configured to forward the application access request to the target virtual host according to the target load forwarding policy, forward the application access request to the target reverse proxy through the target virtual host, and perform load balancing processing on the application access request through the target reverse proxy.
Further, the policy binding rule is stored in the blockchain database, which is not limited herein.
In the embodiment of the invention, the content is forwarded to the content exchange virtual machine through a preset application switch; matching and analyzing a strategy binding rule corresponding to the content exchange virtual machine according to the convergence domain name address and the redirection address to obtain a target load forwarding strategy; and forwarding the application access request to a target virtual host according to a target load forwarding strategy, forwarding the application access request to a target reverse proxy through the target virtual host, and performing load balancing processing on the application access request through the target reverse proxy. And the virtualization technology is smoothly switched and applied according to the service requirements, so that the load balancing network link is shortened, and the network performance loss is reduced.
Referring to fig. 4, another embodiment of the load balancing processing apparatus according to the embodiment of the present invention includes:
a receiving module 301, configured to receive an application access request, and forward the application access request to a content exchange virtual machine through a preset application switch;
an extracting module 302, configured to extract a converged domain name address and a redirection address from the application access request through the content exchange virtual machine;
the analysis module 303 is configured to perform matching analysis on the policy binding rule corresponding to the content exchange virtual machine according to the converged domain name address and the redirection address to obtain a target load forwarding policy, where the policy binding rule corresponding to the content exchange virtual machine includes a plurality of load forwarding policies and a plurality of pattern matching data sets, and each load forwarding policy corresponds to each pattern matching data set one to one;
the processing module 304 is configured to forward the application access request to the target virtual host according to the target load forwarding policy, forward the application access request to the target reverse proxy through the target virtual host, and perform load balancing processing on the application access request through the target reverse proxy.
Optionally, the receiving module 301 may be further specifically configured to:
receiving an application access request, intercepting the application access request through a preset application switch, and acquiring terminal address information;
judging whether the application access request is abnormal or not according to the terminal address information;
if the application access request is abnormal, generating and recording request abnormal information, and sending the request abnormal information to the terminal;
and if the application access request is not abnormal, forwarding the application access request to the content exchange virtual machine through a preset application switch according to a preset binding relationship, wherein the preset binding relationship is used for indicating the association mapping between the content exchange virtual machine and the preset application switch.
Optionally, the extracting module 302 may be further specifically configured to:
setting a uniform resource positioning object to the application access request according to a preset constructor through a content exchange virtual machine, and calling a domain name acquisition function based on the uniform resource positioning object to obtain a convergence domain name address;
and extracting the redirection address from the application access request according to a preset regular matching rule, wherein the preset regular matching rule is used for indicating character matching and segmentation processing of the application access request.
Optionally, the analysis module 303 may be further specifically configured to:
matching and analyzing strategy binding rules corresponding to the content exchange virtual machine based on the convergence domain name address to obtain a plurality of load forwarding strategies and a plurality of pattern matching data sets which are associated and bound with the convergence domain name address, wherein each load forwarding strategy has a corresponding priority value and a corresponding unique identifier, and each load forwarding strategy corresponds to each pattern matching data set one by one;
sequentially accessing each load forwarding strategy according to the priority value corresponding to each load forwarding strategy from low to high, and judging whether a redirection address exists in a pattern matching data set corresponding to each load forwarding strategy or not;
and if the redirection address exists in the pattern matching data set corresponding to each load forwarding strategy, determining a target pattern matching data set, and determining a target load forwarding strategy according to the target pattern matching data set.
Optionally, the processing module 304 may be further specifically configured to:
acquiring a strategy identifier corresponding to a target load forwarding strategy, inquiring preset configuration information according to the strategy identifier to obtain a target virtual host, and forwarding an application access request to the target virtual host;
when the application access request reaches the target virtual host, the application access request is transmitted to the target reverse proxy through the target virtual host, and the target virtual host and the target reverse proxy are in one-to-one correspondence;
when the application access request reaches the target reverse proxy, the application access request is distributed and sent to the target host through the target reverse proxy, and the target host belongs to the preset distributed cluster.
Optionally, the load balancing processing apparatus further includes:
an initialization module 305, configured to obtain a converged domain name address and a service type, add at least one pattern matching data set according to the converged domain name address and the service type, and perform data initialization on the at least one pattern matching data set;
a binding module 306, configured to set at least one load forwarding policy according to the converged domain name address and the service type, and associate and bind each load forwarding policy with each pattern matching data set;
the allocating module 307 is configured to perform association mapping processing on each load forwarding policy, the content exchange virtual machine, and the target virtual host, and allocate a corresponding priority value to each load forwarding policy according to a preset priority allocation rule.
Optionally, the load balancing processing apparatus further includes:
the mining module 308 is configured to obtain a load balancing access log, perform data mining and analysis on the load balancing access log according to a preset machine learning algorithm, and obtain a target access data volume, where the target access data volume is used to indicate the number of application access requests and the distribution number of target reverse proxies within a preset time length;
the display module 309 is configured to send the target access data volume to the terminal, so that the terminal generates and displays a thermodynamic diagram according to the target access data volume.
In the embodiment of the invention, the content is forwarded to the content exchange virtual machine through a preset application switch; matching and analyzing a strategy binding rule corresponding to the content exchange virtual machine according to the convergence domain name address and the redirection address to obtain a target load forwarding strategy; and forwarding the application access request to a target virtual host according to a target load forwarding strategy, forwarding the application access request to a target reverse proxy through the target virtual host, and performing load balancing processing on the application access request through the target reverse proxy. And the virtualization technology is smoothly switched and applied according to the service requirements, so that the load balancing network link is shortened, and the network performance loss is reduced.
Fig. 3 and fig. 4 describe the load balancing processing apparatus in the embodiment of the present invention in detail from the perspective of modularization, and the load balancing processing apparatus in the embodiment of the present invention is described in detail from the perspective of hardware processing.
Fig. 5 is a schematic structural diagram of a load balancing processing apparatus according to an embodiment of the present invention, where the load balancing processing apparatus 500 may generate relatively large differences due to different configurations or performances, and may include one or more processors (CPUs) 510 (e.g., one or more processors) and a memory 520, and one or more storage media 530 (e.g., one or more mass storage devices) storing applications 533 or data 532. Memory 520 and storage media 530 may be, among other things, transient or persistent storage. The program stored in the storage medium 530 may include one or more modules (not shown), each of which may include a series of instructions operating on the load balancing processing apparatus 500. Further, the processor 510 may be configured to communicate with the storage medium 530, and execute a series of instruction operations in the storage medium 530 on the load balancing processing apparatus 500.
The load balancing processing apparatus 500 may also include one or more power supplies 540, one or more wired or wireless network interfaces 550, one or more input-output interfaces 560, and/or one or more operating systems 531, such as Windows Server, Mac OS X, Unix, Linux, FreeBSD, and the like. Those skilled in the art will appreciate that the load balancing processing device configuration shown in fig. 5 does not constitute a limitation of the load balancing processing device, and may include more or fewer components than those shown, or some components may be combined, or a different arrangement of components.
The present invention also provides a computer-readable storage medium, which may be a non-volatile computer-readable storage medium, and may also be a volatile computer-readable storage medium, having stored therein instructions, which, when run on a computer, cause the computer to perform the steps of the load balancing processing method.
The present invention further provides a load balancing processing device, where the load balancing processing device includes a memory and a processor, where the memory stores instructions, and the instructions, when executed by the processor, cause the processor to execute the steps of the load balancing processing method in the foregoing embodiments.
Further, the computer-readable storage medium may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required for at least one function, and the like; the storage data area may store data created according to the use of the blockchain node, and the like.
The block chain is a novel application mode of computer technologies such as distributed data storage, point-to-point transmission, a consensus mechanism, an encryption algorithm and the like. A block chain (Blockchain), which is essentially a decentralized database, is a series of data blocks associated by using a cryptographic method, and each data block contains information of a batch of network transactions, so as to verify the validity (anti-counterfeiting) of the information and generate a next block. The blockchain may include a blockchain underlying platform, a platform product service layer, an application service layer, and the like.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a read-only memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
The above-mentioned embodiments are only used for illustrating the technical solutions of the present invention, and not for limiting the same; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present invention.

Claims (10)

1. A load balancing processing method is characterized by comprising the following steps:
receiving an application access request, and forwarding the application access request to a content exchange virtual machine through a preset application switch;
extracting, by the content exchange virtual machine, a converged domain name address and a redirection address from the application access request;
matching and analyzing a policy binding rule corresponding to the content exchange virtual machine according to the convergence domain name address and the redirection address to obtain a target load forwarding policy, wherein the policy binding rule corresponding to the content exchange virtual machine comprises a plurality of load forwarding policies and a plurality of pattern matching data sets, and each load forwarding policy corresponds to each pattern matching data set one by one;
and forwarding the application access request to a target virtual host according to the target load forwarding strategy, forwarding the application access request to a target reverse proxy through the target virtual host, and performing load balancing processing on the application access request through the target reverse proxy.
2. The load balancing processing method according to claim 1, wherein the receiving an application access request and forwarding the application access request to the content switching virtual machine through a preset application switch includes:
receiving an application access request, intercepting the application access request through a preset application switch, and acquiring terminal address information;
judging whether the application access request is abnormal or not according to the terminal address information;
if the application access request is abnormal, generating and recording request abnormal information, and sending the request abnormal information to a terminal;
if the application access request is not abnormal, the application access request is forwarded to a content exchange virtual machine through the preset application switch according to a preset binding relationship, and the preset binding relationship is used for indicating the association mapping between the content exchange virtual machine and the preset application switch.
3. The load balancing process of claim 1, wherein the extracting, by the content exchange virtual machine, the converged domain name address and the redirection address from the application access request comprises:
setting a uniform resource positioning object for the application access request according to a preset construction function through the content exchange virtual machine, and calling a domain name acquisition function based on the uniform resource positioning object to obtain a convergence domain name address;
and extracting a redirection address from the application access request according to a preset regular matching rule, wherein the preset regular matching rule is used for indicating character matching and segmentation processing of the application access request.
4. The load balancing processing method according to claim 1, wherein the matching analysis is performed on the policy binding rule corresponding to the content exchange virtual machine according to the convergence domain name address and the redirection address to obtain a target load forwarding policy, the policy binding rule corresponding to the content exchange virtual machine includes a plurality of load forwarding policies and a plurality of pattern matching data sets, and each load forwarding policy corresponds to each pattern matching data set one to one, and the method includes:
matching and analyzing the strategy binding rules corresponding to the content exchange virtual machine based on the convergence domain name address to obtain a plurality of load forwarding strategies and a plurality of pattern matching data sets which are associated and bound with the convergence domain name address, wherein each load forwarding strategy has a corresponding priority value and a corresponding unique identifier, and each load forwarding strategy corresponds to each pattern matching data set one by one;
sequentially accessing each load forwarding strategy according to the priority value corresponding to each load forwarding strategy from low to high, and judging whether the redirection address exists in the mode matching data set corresponding to each load forwarding strategy or not;
and if the redirection address exists in the pattern matching data set corresponding to each load forwarding strategy, determining a target pattern matching data set, and determining a target load forwarding strategy according to the target pattern matching data set.
5. The method according to claim 1, wherein the forwarding the application access request to a target vm according to the target load forwarding policy, forwarding the application access request to a target reverse proxy through the target vm, and load balancing the application access request through the target reverse proxy includes:
acquiring a strategy identifier corresponding to the target load forwarding strategy, inquiring preset configuration information according to the strategy identifier to obtain a target virtual host, and forwarding the application access request to the target virtual host;
when the application access request reaches the target virtual host, the application access request is transmitted to a target reverse proxy through the target virtual host, and the target virtual host and the target reverse proxy are in one-to-one correspondence;
when the application access request reaches the target reverse proxy, the application access request is distributed and sent to a target host through the target reverse proxy, and the target host belongs to a preset distributed cluster.
6. The load balancing processing method according to any one of claims 1 to 5, wherein before the receiving an application access request and forwarding the application access request to a content switching virtual machine through a preset application switch, the load balancing processing method further comprises:
acquiring the convergence domain name address and the service type, adding at least one pattern matching data set according to the convergence domain name address and the service type, and performing data initialization on the at least one pattern matching data set;
setting at least one load forwarding strategy according to the convergence domain name address and the service type, and associating and binding each load forwarding strategy and each mode matching data set;
and performing associated mapping processing on each load forwarding strategy, the content exchange virtual machine and the target virtual host, and distributing a corresponding priority value to each load forwarding strategy according to a preset priority distribution rule.
7. The load balancing processing method according to any one of claims 1 to 5, wherein after the forwarding the application access request to the target virtual host according to the target load forwarding policy, forwarding the application access request to the target reverse proxy through the target virtual host, and performing load balancing processing on the application access request through the target reverse proxy, the load balancing processing method further comprises:
acquiring a load balancing access log, and performing data mining and analysis on the load balancing access log according to a preset machine learning algorithm to obtain a target access data volume, wherein the target access data volume is used for indicating the number of application access requests and the distribution number of target reverse agents within a preset time length;
and sending the target access data volume to a terminal so that the terminal generates and displays a thermodynamic diagram according to the target access data volume.
8. A load balancing processing apparatus, characterized in that the load balancing processing apparatus comprises:
the system comprises a receiving module, a content switching virtual machine and a content switching module, wherein the receiving module is used for receiving an application access request and forwarding the application access request to the content switching virtual machine through a preset application switch;
an extraction module, configured to extract a converged domain name address and a redirection address from the application access request through the content exchange virtual machine;
the analysis module is used for performing matching analysis on the policy binding rules corresponding to the content exchange virtual machine according to the convergence domain name address and the redirection address to obtain a target load forwarding policy, wherein the policy binding rules corresponding to the content exchange virtual machine comprise a plurality of load forwarding policies and a plurality of pattern matching data sets, and each load forwarding policy corresponds to each pattern matching data set one by one;
and the processing module is used for forwarding the application access request to a target virtual host according to the target load forwarding strategy, forwarding the application access request to a target reverse proxy through the target virtual host, and performing load balancing processing on the application access request through the target reverse proxy.
9. A load balancing processing apparatus, characterized in that the load balancing processing apparatus comprises: a memory and at least one processor, the memory having instructions stored therein;
the at least one processor invokes the instructions in the memory to cause the load balancing processing device to perform the load balancing processing method according to any one of claims 1 to 7.
10. A computer-readable storage medium having instructions stored thereon, wherein the instructions, when executed by a processor, implement a load balancing process as claimed in any one of claims 1 to 7.
CN202110514177.3A 2021-05-12 2021-05-12 Load balancing processing method, device, equipment and storage medium Pending CN113271260A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110514177.3A CN113271260A (en) 2021-05-12 2021-05-12 Load balancing processing method, device, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110514177.3A CN113271260A (en) 2021-05-12 2021-05-12 Load balancing processing method, device, equipment and storage medium

Publications (1)

Publication Number Publication Date
CN113271260A true CN113271260A (en) 2021-08-17

Family

ID=77230437

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110514177.3A Pending CN113271260A (en) 2021-05-12 2021-05-12 Load balancing processing method, device, equipment and storage medium

Country Status (1)

Country Link
CN (1) CN113271260A (en)

Similar Documents

Publication Publication Date Title
CN108449282B (en) Load balancing method and device
CN108650182B (en) Network communication method, system, device, equipment and storage medium
Hunt et al. Network dispatcher: A connection router for scalable internet services
Damani et al. ONE-IP: Techniques for hosting a service on a cluster of machines
Cardellini et al. The state of the art in locally distributed web-server systems
US6324177B1 (en) Method and apparatus for managing connections based on a client IP address
US7062571B1 (en) Efficient IP load-balancing traffic distribution using ternary CAMs
US20030014524A1 (en) Balancing shared servers in virtual environments
US6766371B1 (en) Virtual network environment
US20040205250A1 (en) Bi-directional affinity
US20020152307A1 (en) Methods, systems and computer program products for distribution of requests based on application layer information
US6792463B1 (en) System, method and program product for providing invisibility to a proxy-server
US20140280775A1 (en) Network Stack and Related Techniques
US20070250836A1 (en) Method for expanding data flow
EP2321937B1 (en) Load balancing for services
KR20180108708A (en) Message Generation Method and Load Balancer Based on Server Clusters
US7380002B2 (en) Bi-directional affinity within a load-balancing multi-node network interface
US10992575B2 (en) Assignment of internet protocol addresses to services
CA2543753A1 (en) Method and system for accessing and managing virtual machines
CN110012118B (en) Method and controller for providing Network Address Translation (NAT) service
CN104079668B (en) A kind of DNS load balancing adjusting method and system
US20160165006A1 (en) Combining disparate applications into a single workload group
CN113301144B (en) Concurrent access processing method and device for Nginx server, server and storage medium
Moreno‐Vozmediano et al. Elastic management of web server clusters on distributed virtual infrastructures
US7711780B1 (en) Method for distributed end-to-end dynamic horizontal scalability

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