CN105959413A - Network proxy method and system - Google Patents
Network proxy method and system Download PDFInfo
- Publication number
- CN105959413A CN105959413A CN201610510314.5A CN201610510314A CN105959413A CN 105959413 A CN105959413 A CN 105959413A CN 201610510314 A CN201610510314 A CN 201610510314A CN 105959413 A CN105959413 A CN 105959413A
- Authority
- CN
- China
- Prior art keywords
- server
- access request
- region
- proxy
- agency
- 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.)
- Granted
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/10—Protocols in which an application is distributed across nodes in the network
- H04L67/1001—Protocols in which an application is distributed across nodes in the network for accessing one among a plurality of replicated servers
- H04L67/1004—Server selection for load balancing
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/10—Protocols in which an application is distributed across nodes in the network
- H04L67/1001—Protocols in which an application is distributed across nodes in the network for accessing one among a plurality of replicated servers
- H04L67/1004—Server selection for load balancing
- H04L67/1012—Server selection for load balancing based on compliance of requirements or conditions with available server resources
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/50—Network services
- H04L67/56—Provisioning of proxy services
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/50—Network services
- H04L67/56—Provisioning of proxy services
- H04L67/566—Grouping or aggregating service requests, e.g. for unified processing
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Computer And Data Communications (AREA)
Abstract
The invention provides a network proxy method. The network proxy method comprises the following steps: carrying out domain name resolution on an access request to resolve the access request to a first proxy server in a plurality of proxy servers, wherein the plurality of proxy servers are deployed in different regions; and carrying out proxy on the access request to a server cluster in a preferred region by the first proxy server based on the own configuration information of the first proxy server.
Description
Technical field
The present invention relates to Internet technology, particularly relate to network agent method and agency plant.
Background technology
Network agent function is the common internet function performed by proxy server, i.e. agency network is used
Family is gone to obtain the network information.Figuratively, proxy server is the terminal of the network information.In ordinary circumstance
Under, we use client, and such as web browser directly goes to connect other Internet websites and obtains network
During information, must send access request and be answered, then the other side returns information transmission again.Agency service
Device is the station server between browser and Web server, and after having had it, browser is not
Directly go to fetch webpage to Web server but send request to proxy server.Access request can first be sent
To proxy server, proxy server fetch browser required for information and send your browse to
Device.And, major part proxy server all has the function of buffering, and just as a big Cache, it has
The biggest memory space, it is constantly stored into newly obtaining data on the memorizer of its machine, if browser
The data asked have existed on the memorizer of its machine and have been up-to-date, then it the most again from
Web server fetches data, and the data on memorizer directly send to the browser of user, thus can
Significantly improve surfing and efficiency.
Summary of the invention
The brief overview of one or more aspect given below is to provide the basic comprehension in terms of these.This is general
State the extensive overview of the not all aspect contemplated, and be both not intended to identify the key of all aspects
Or the most non-scope attempting to define in terms of any or all of decisive key element.Its unique purpose is intended to simplify
Form provides some concepts of one or more aspect and thinks the sequence of more detailed description given later.
According to an aspect of the present invention, it is provided that a kind of Proxy Method for network, including:
Access request is performed domain name mapping, this access request is resolved first to multiple proxy servers
Proxy server, the plurality of proxy server is deployed in different regions;And
By this first agent's server configuration information based on self by this access request agency to first-selected region
Interior server cluster.
In one example, this execution domain name mapping includes: launch position based on this access request is by this visit
Ask request analysis to this first agent's server, the launch position of this access request falls and services this first agent
In the first region residing for device.
In one example, based on this configuration information, the server cluster in this first-selection region is this first ground
Server cluster in territory.
In one example, the server cluster in this access request agency to first-selected region is wrapped by further
Include: based on load balancing by the server cluster in this access request agency to this first-selection region
Server.
In one example, the server cluster in this access request agency to first-selected region is wrapped by further
Include: if this server response abnormality acted on behalf of, be then again based on load balancing by this access request
Act on behalf of other servers in the server cluster to this first-selection region until this access request obtains normally
Response.
In one example, the server cluster in this access request agency to first-selected region is wrapped by further
Include: if the equal response abnormality of Servers-all in the server cluster in this first-selection region, then by this first generation
Reason server configuration information based on self is by the server cluster in this access request agency to another region.
In one example, this Proxy Method also includes: by the clothes in this access request agency to another region
After business device cluster and this access request obtain normal response, revise this configuration information with by this another region
It is configured to first-selected region.
In one example, this load balancing includes following at least one: repeating query equilibrium, weight repeating query are equal
The equilibrium of weighing apparatus, Stochastic Equilibrium, response speed, the equilibrium of minimum connection number, disposal ability equilibrium, DNS response are all
Weighing apparatus.
In one example, this access request includes head portion and main part, and this Proxy Method also includes:
Resolved the main part of this access request to obtain ID by this first agent's server, bear for this
Carry the mark of balance policy.
In one example, this first agent's server is based on the locally stored request lattice about this access request
Formula performs parsing to the main part of this access request.
According to a further aspect in the invention, it is provided that a kind of agency plant for network, including:
Domain name resolution server, for performing domain name mapping to access request;
Multiple proxy servers, the plurality of proxy server is deployed in different regions;
Multiple server clusters, the plurality of server cluster is deployed in different regions,
Wherein this access request is resolved first to the plurality of proxy server by this domain name resolution server
Proxy server, this access request is acted on behalf of by this first agent's server for configuration information based on self
Server cluster to first-selected region.
In one example, this domain name resolution server launch position based on this access request please by this access
Solving and analyse to this first agent's server, the launch position of this access request falls in this first agent's server institute
In first region at place.
In one example, based on this configuration information, the server cluster in this first-selection region is this first ground
Server cluster in territory.
In one example, this first agent's server is further used for this access being asked based on load balancing
Seek the server in the server cluster acted on behalf of to this first-selection region.
In one example, if this server that this first agent's server is further used for being acted on behalf of responds different
Often, then load balancing it is again based on by the server cluster in this access request agency to this first-selection region
In other servers until this access request obtains normal response.
In one example, if this first agent's server is further used for the server cluster in this first-selection region
In the equal response abnormality of Servers-all, then configuration information based on self by this access request act on behalf of to another
Server cluster in region.
In one example, this first agent's server is further used for acting on behalf of to another ground this access request
After server cluster in territory and this access request obtain normal response, revise self configuration information with
This another region is configured to first-selected region.
In one example, this load balancing includes following at least one: repeating query equilibrium, weight repeating query are equal
The equilibrium of weighing apparatus, Stochastic Equilibrium, response speed, the equilibrium of minimum connection number, disposal ability equilibrium, DNS response are all
Weighing apparatus.
In one example, this access request includes head portion and main part, and this first agent's server is also
Including parsing module, for resolving the main part of this access request to obtain ID, for this
The mark of load balancing.
In one example, this first agent's server includes data base, and in this data base, storage has multiple request
The request form of type, this parsing module search this data base come with the request form asked according to this user right
The main part of this access request performs parsing.
In the present invention, by adding the concept of region, can be individually to some region Proxy load, also
Can configure multiple region, multiple regions carry out load agent, multiple regions switch over, it is provided that generation
The motility of reason.
Additionally, compare nginx can only obtain load strategy related content from request header information, the present invention is led to
Cross analysis request body acquisition of information load strategy content, thus strengthen load strategy, solve general load
The problem that strategy execution mode is single, thus support that Proxy load equalizes multiformity, such as can support wechat
With various ways such as webservice.
Accompanying drawing explanation
After reading the detailed description that embodiment of the disclosure in conjunction with the following drawings, it is possible to be more fully understood that this
The features described above of invention and advantage.In the accompanying drawings, each assembly is not necessarily drawn to scale, and has class
As the assembly of correlation properties or feature be likely to be of same or like reference.
Fig. 1 shows the block diagram of agency plant according to an aspect of the present invention;
Fig. 2 shows the flow chart of Proxy Method according to an aspect of the present invention;
Fig. 3 shows the block diagram of agency plant according to a further aspect in the invention;And
Fig. 4 shows the flow chart of Proxy Method according to a further aspect in the invention.
Detailed description of the invention
Below in conjunction with the drawings and specific embodiments, the present invention is described in detail.Note, below in conjunction with accompanying drawing and
The aspects that specific embodiment describes is only exemplary, and is understood not to protection scope of the present invention
Carry out any restriction.
Fig. 1 shows the block diagram of agency plant 100 according to an aspect of the present invention.As it is shown in figure 1,
Agency plant 100 can include domain name resolution server 101, proxy server 121,122 and server
Cluster 131,132.
User initiates an access request via client.Here client can be web browser, APP
Software such as wechat etc..First the access request initiated via client is entered via domain name resolution server 101
Row domain name mapping.Domain name resolution server 101 is responsible for resolving to proxy server 121,122 access request
In one.
According to an aspect of the present invention, agent functionality is performed by " region ".Proxy server 121,
122 are deployed in different geographical, and server cluster 131,132 is also deployed in different regions.Shown in Fig. 1
Example in, proxy server 121 and server cluster 131 are deployed in identical region 1;Agency
Server 122 and server cluster 132 are deployed in identical region 2.
In the example shown in Fig. 1, illustrate only two regions, region 1, region 2, the most only illustrate
The proxy server of the two region and server cluster, but, it will be understood by those skilled in the art that
Can exist and plural region, and each region are disposed corresponding proxy server and server set
Group, such as, deposit the proxy server 12n being deployed in the n of region and server cluster 13n (wherein n > 2) (not
Illustrate).
In one embodiment, domain name resolution server 101 can initiation address based on access request determine by
Which proxy server is this access request resolve to.Such as, domain name resolution server 101 can be asked accessing
Solving and analyse to first agent's server, wherein the initiation address of this access request falls at this first agent's server
Residing region.
As example, this first agent's server can be proxy server 121, i.e. domain name resolution server
Access request is resolved the proxy server 121 to region 1 by 101.
Proxy server 121 such as receives this access request by monitoring 80 ports.Proxy server 121
Can determine the server cluster in first-selected for access request agency region by configuration information based on self.Configuration letter
Can store first-selected region in breath, so-called first-selected region refers to that proxy server 121 is preferential by access request
Act on behalf of the server cluster to this first-selection region.Configuration information can also store its that sort by priority
The sorted lists of his region.
As example, the preferred region in the configuration information of next proxy server of normal condition is this agency
The region that server self is residing.Such as proxy server 121, its first-selected region is region 1,
For proxy server 122, first-selected region is region 2.Certainly, the first-selected region in configuration information
Can change, the such as server cluster in first-selected region occur the machine of delaying cannot normal response time, permissible
The first-selected region of change, this is described in detail below.
In the example shown in Fig. 1, proxy server 121 can be based on own configuration information by access request generation
Manage the server cluster 131 to region 1.
Containing multiple servers in server cluster 131, such as server A, B, C, D, the most only show
Go out 4 servers, however it will be appreciated that and can there is more server.
Proxy server 121 can be based on load balancing by the clothes in access request agency to first-selected region
The server in server cluster 131 in business device cluster i.e. region 1.
Conventional load balancing includes following several types:
Repeating query equilibrium (Round Robin): the request of automatic network each time is distributed in inside in turn
Server, then restarts from 1 to N.All services that this kind of equalization algorithm is suitable in server group
Device has identical software and hardware configuration and the situation of average service request relative equilibrium.
Weight repeating query equilibrium (Weighted Round Robin): according to the different disposal ability of server,
To the weights that each server-assignment is different so that it is the service request of corresponding weight value number can be accepted.Such as:
The weights of server A are designed to 1, and the weights of B are 3, and the weights of C are 6, then server A, B,
The service receiving 10%, 30%, 60% respectively is asked by C.This kind of equalization algorithm can ensure that high performance
Server obtains more utilization rate, it is to avoid the server load of low performance is overweight.
Stochastic Equilibrium (Random): multiple services that the request carrying out automatic network is randomly assigned in inside
Device.
Weight Stochastic Equilibrium (Weighted Random): this kind of equalization algorithm is similar to weight Round-Robin Algorithm,
It it is but a process randomly choosed when processing request and sharing.
Response speed equilibrium (Response Time): load-balancing device sends one to internal each server
Individual probe requests thereby (such as Ping), then according to server each in inside to the fastest response of probe requests thereby time
Between determine which station server come customer in response end service request.This kind of equalization algorithm can preferably reflect
The current operating conditions of server, but this fastest response time only refer only to load-balancing device and server
Between the fastest response time rather than fastest response time between client and server.
Minimum connection number equilibrium (Least Connection): the service of request each time of client is at server
Residence time there may be bigger difference, along with longer working time, if use simple repeating query or
Stochastic Equilibrium algorithm, the connection process on each station server may produce and differ greatly from, not reach
To real load balancing.The each station server needing load in inside is had by minimum connection number equalization algorithm
One data record, the connection quantity that record this server current is processing, please when there being new service to connect
When asking, by current request is distributed to connect the server that number is minimum, equilibrium is made to more conform to practical situation,
Load more equalizes.The request service processed when this kind of equalization algorithm is suitable for long, such as FTP.
Disposal ability equalizes: this kind of equalization algorithm will service request assignment to inside processes load (according to
Server CPU model, CPU quantity, memory size and current connect the conversions such as number and form) the lightest clothes
Business device, it is contemplated that the disposal ability of internal server and current network operation conditions, so this kind all
Account method the most accurate, be especially suitable for applying to the situation of layer 7 (application layer) load balancing
Under.
DNS response equilibrium (Flash DNS): on internet, either HTTP, FTP or its
Its service request, client is typically all and finds the definite IP address of server by domain name mapping.
Under this equalization algorithm, office receives the territory of same client at the load-balancing device of diverse geographic location
Name analysis is asked, and within the same time, this domain name mapping is become the IP address of respective corresponding server (i.e.
With this load-balancing device in the IP address of the server in geographical position, same position) and return to client,
Then request service is continued in the domain name mapping IP address to receive at first by client, and ignores other IP
Address response.In the case of kind of a balance policy is suitably applied in GSLB, to local load balancing
It is nonsensical.
Access request can be acted on behalf of to server cluster by such as proxy server 121 based on load balancing
Server A in 131, if server A response abnormality, then can be again based on load balancing will access
Other servers to this server cluster 131 are acted on behalf of in request, if response is the most abnormal, the most again act on behalf of
Next server to this server cluster 131, repeats this operation until access request obtains normal response.
In extreme circumstances, if the Servers-all in the server cluster in first-selected region all can not normally ring
Should, then proxy server 121 can be based on configuration information by the server in access request agency to another region
Cluster, such as configuration information medium priority are only second to the server cluster in next region of first-selected region.Make
For example, such as, access request can be acted on behalf of the server cluster to region 2 by proxy server 121
132。
If server cluster 2 can provide normal response, then proxy server 121 can revise configuration information with
Change first-selection region into region 2.More preferably, when the server cluster 131 in region 1 recovers normal, generation
The first-selected region of reason server 121 can change back region 1 again.
Access request generally comprises head portion and main part.As discussed previously, access request is likely
Sent, now, as the information of the head portion of access request is by network platforms such as wechat platforms
, it is impossible to as the sign of some normal load strategies.
In the present invention, proxy server can include data base and parsing module (not shown).Data
Storehouse can prestore the request form of multiple request type.Parsing module can be by searching data base with root
The main part of access request is resolved by the request form asked according to this user, to obtain ID,
Thus can be as the mark of load balancing.
Fig. 2 shows the flow chart of Proxy Method 200 according to an aspect of the present invention.As in figure 2 it is shown,
Proxy Method 200 can comprise the following steps that
In step 201: access request is performed domain name mapping, access request is resolved to multiple agency services
First agent's server in device, the plurality of proxy server is deployed in different regions.
This parsing can be that launch position based on access request is carried out, the initiation of such as this access request
Position falls in the first region residing for first agent's server.
In step 202: by first agent's server configuration information based on self by access request agency to first
Server cluster in selection of land territory.
Can store first-selected region in configuration information, so-called first-selected region refers to that proxy server please by access
Ask preferential agency to the server cluster of this first-selection region.Configuration information can also store and according to priority arranged
The sorted lists of other regions of sequence.As example, the configuration information of next proxy server of normal condition
In preferred region be the residing region of this proxy server self.
Further, first agent's server can be based on load balancing by the most first-selected for access request agency ground
A server in server cluster in territory.As it was previously stated, the load balancing often having can include repeating query
Equilibrium, weight repeating query equilibrium, Stochastic Equilibrium, response speed equilibrium, the equilibrium of minimum connection number, disposal ability
Equilibrium, DNS response equilibrium etc..
If the server response abnormality acted on behalf of, then it is again based on load balancing and access request is acted on behalf of
Other servers in server cluster to first-selected region are until access request obtains normal response.
If the equal response abnormality of Servers-all in the server cluster in this first-selection region, then by first agent
Server configuration information based on self is by the server cluster in access request agency to another region, such as
Configuration information is positioned at the server cluster of the next region of first-selected region according to prioritization.
Normally rung in server cluster and the access request that access request is acted on behalf of to another region
After should, revise this configuration information this another region to be configured to first-selected region.Preferably, can be at this
Server cluster in first region can with normal response time, selection of land territory headed by the first region is changeed back.
In one example, the main part of access request can be resolved to obtain user by first agent's server
ID, for the mark of load balancing.Such as, first agent's server can be based on locally stored pass
Request form in access request performs parsing to the main part of access request.
Fig. 3 shows the block diagram of agency plant 300 according to a further aspect in the invention.
As it is shown on figure 3, agency plant 300 can include domain name resolution server 301, proxy server 321,
322 and server cluster 331,332.Shown in Fig. 3 two proxy server 321,322 and
Two server clusters 331,332 are only examples, in practice, can exist a proxy server and
One server cluster, it is also possible to there is the proxy server more than two and the server set more than two
Group.
According to an aspect of the present invention, each server cluster can include two server groups, one of them clothes
Business device group is for providing the formal publisher server group of the service of access, and another group is pre-for server updating
Cloth server group.These two groups of server groups are duplicate, and the role differing only in both is different, i.e.
The role of each server group is carried out between " formal publisher server group " and " pre-publisher server group "
Switching.When a server group is " formal publisher server group ", another group is then " pre-issuing service
Device group ", and originally ought switch to for the server group of " formal publisher server group " role and " issue clothes in advance
Business device group " time, original server group for " pre-publisher server group " role switches to simultaneously " formally to be sent out
Cloth server group ".
As a example by example in Fig. 3, server cluster 331 includes two server groups 3311,3312.
Server group 3311 and server group 3312 are originally used for two server groups mapped each other, and i.e. both are completely
Identical.But be used for providing a user with access response by server group 3311, another server group 3312 is not
For providing a user with access response, but for server updating.Now, server group 3311
Being referred to as formal publisher server group, now server group 3312 can be described as pre-publisher server group.
In one example, in server group 3312 is the time undertaking pre-publisher server group role,
If needing server is made any upgrading, the most not to the server group undertaking formal publisher server group role
3311 do any operation, but only upgrade server group 3312, and server updating here is permissible
It is the renewal of server content, or the amendment of server configures.
After the server group 3312 undertaking pre-publisher server group role is upgraded, server group 3312
Can be formal publisher server group, correspondingly, server group 3311 from the role switching of pre-publisher server group
Then the role switching from formal publisher server group is pre-publisher server group, and both realize role exchange.
In another example, in server group 3312 is the time undertaking pre-publisher server group role,
If needing server is made any upgrading, first server group 3312 can be switched to formal server group,
Server group 3311 is switched to pre-publisher server group simultaneously;Then, server group 3311 is risen
Level.
After upgrading server group 3311, server group 3312 switches to pre-issue to take again
Business device group, the server group 3311 after upgrading switches to formal server group.
It should be noted that the above-mentioned passive switching switched between server group.But it is all right in the present invention
In the case of formal server group is all abnormal, pre-publisher server group is switched to formal server group,
And formally server group switches to pre-publisher server group.The follow-up pre-issue clothes that can also regularly detect exception
Whether business device group recovers normal, after treating that pre-publisher server group is recovered normally, recovers to issue clothes in advance normally
Business device switches to formal server group, and formal server group switches back into pre-publisher server group again.
User initiates an access request via client.Here client can be web browser, APP
Software such as wechat etc..First the access request initiated via client is entered via domain name resolution server 301
Row domain name mapping.Domain name resolution server 301 is responsible for resolving to proxy server 321,322 access request
In one, such as proxy server 321.Proxy server 321 can will be visited by configuration information based on self
Ask request agency the formal publisher server group to a server cluster, such as server cluster 331.
From the foregoing, it will be observed that proxy server always by access request agency to server cluster formally issues clothes
Business device group.Always pass through upgrading due to formal publisher server group and be provided that the server of normal access response
Group, therefore, access request can obtain normal response.Although additionally, formal publisher server group is in service
Switch between two server groups of device cluster, but this switching is sightless for a user, therefore,
The upgrading of server can be with seamless switching, it is not necessary to restart server.
In the case of there is multiple proxy server and multiple server cluster, can come by " region "
Perform agent functionality.Such as, proxy server 321,322 is deployed in different geographical, server cluster 331,
332 are also deployed in different regions.In examples as shown in figure 3, proxy server 321 and server
Cluster 331 is deployed in identical region 1;Proxy server 322 and server cluster 332 are deployed in phase
Same region 2.
In one embodiment, domain name resolution server 301 can initiation address based on access request determine by
Which proxy server is this access request resolve to.Such as, domain name resolution server 101 can be asked accessing
Solving and analyse to first agent's server, wherein the initiation address of this access request falls at this first agent's server
Residing region.
Proxy server 321 such as receives this access request by monitoring 80 ports.In one example,
Proxy server 321 can determine the service in first-selected for access request agency region by configuration information based on self
Device cluster.Can store first-selected region in configuration information, so-called first-selected region refers to proxy server 321
Access request is preferentially acted on behalf of the server cluster to this first-selection region.Configuration information can also store by
The sorted lists of other regions of prioritization.
As example, the preferred region in the configuration information of next proxy server of normal condition is this agency
The region that server self is residing.Such as proxy server 321, its first-selected region is region 1,
For proxy server 322, first-selected region is region 2.
In examples as shown in figure 3, proxy server 321 can be based on own configuration information by access request generation
Manage the server cluster 331 to region 1.
Proxy server 321 can be based on load balancing by the clothes in access request agency to first-selected region
The formal publisher server group such as server group in server cluster 331 in business device cluster i.e. region 1
Server in 3311.
Conventional load balancing can include repeating query equilibrium, weight repeating query equilibrium, Stochastic Equilibrium, response speed
Degree equilibrium, the equilibrium of minimum connection number, disposal ability equilibrium, DNS response equilibrium etc..
Access request can be acted on behalf of to server cluster by such as proxy server 321 based on load balancing
Server A in formal publisher server group 3311 in 331, if server A response abnormality, then can be again
Secondary based on load balancing by access request agency to other servers in this server group 3311, if
Response is the most abnormal, the most again acts on behalf of next server to this server group 3311, repeats this operation
Until access request obtains normal response.
In extreme circumstances, if all clothes in the formal publisher server group 3311 of server cluster 331
Business device all can not normal response, then proxy server 321 can based on configuration information by access request agency under
In one region, such as configuration information medium priority is only second to the server cluster in next region of first-selected region
In formal publisher server group.As example, access request can be acted on behalf of extremely by such as proxy server 321
Formal publisher server group in server cluster 332 in region 2.If now in server cluster 332
Formal publisher server group be server group 3321, then by access request act on behalf of to server group 3321,
Otherwise act on behalf of to server group 3322.
In more extreme cases, if the formal publisher server group of the server cluster in all regions is the loudest
Should be abnormal, then access request can be acted on behalf of the server set to first-selected region by proxy server 321 again
The pre-publisher server group of group, such as the pre-publisher server group 3312 in the server cluster 331 of region 1.
If the pre-publisher server group 3312 in the server cluster 331 of this region 1 also cannot normal response,
Then can be by access request agency to next region, such as configuration information medium priority is only second to first-selected region
Pre-publisher server group in server cluster in next region, the server cluster 332 of such as region 2
In pre-publisher server group 3322 till access request obtains normal response.
In the case of the formal publisher server group of Servers-all cluster all delays machine, follow-up when can be spaced
Between whether detect formal publisher server group normal, if formally recovered, it is possible to switch back into and formally issue clothes
Business device group.
As discussed previously, access request generally comprises head portion and main part.Access request is likely
Being sent by wechat platform, webservice etc., now, the information of the head portion of access request is
The same, it is impossible to as the sign of some normal load strategies.
In the present invention, proxy server can include data base and parsing module (not shown).Data
Storehouse can prestore the request form of multiple request type.Parsing module can be by searching data base with root
The main part of access request is resolved by the request form asked according to this user, to obtain ID,
Thus can be as the mark of load balancing.
Fig. 4 shows the flow chart of Proxy Method 400 according to an aspect of the present invention.As shown in Figure 4,
Proxy Method 400 can comprise the following steps that
In step 401: access request is performed domain name mapping, access request is resolved to first agent's service
Device.
In one example, described access request is resolved to multiple agency's clothes by launch position based on access request
This first agent's server in business device, these multiple proxy servers are deployed in different regions, each region
Inside it is deployed with corresponding server cluster.The launch position of this access request falls at described first agent's server
In the first residing region
In step 402: by this first agent's server configuration information based on self, access request is acted on behalf of extremely
Formal publisher server group in first server cluster, this first server cluster includes for providing access
The formal publisher server group serviced and the pre-publisher server group being used for server updating, this pre-issuing service
Device group switches to formal publisher server group to service for providing to access after upgrading, and formally issues
Server group correspondingly switches to pre-publisher server group for server updating.
In the example of one server cluster of each region configuration, this first server cluster can be this
Server cluster in first-selected region in the configuration information of one proxy server.
Further, first agent's server can based on load balancing by access request agency to this first
The server in formal publisher server group in server cluster.Conventional load balancing can include wheel
Follow equilibrium, weight repeating query equilibrium, Stochastic Equilibrium, response speed equilibrium, the equilibrium of minimum connection number, process energy
Power equilibrium, DNS response equilibrium etc..
If the equal response abnormality of Servers-all in the formal publisher server group of first server cluster, then may be used
By first agent's server configuration information based on self by the service in access request agency to next region
Formal publisher server group in device cluster is until access request obtains normal response.
In extreme situations, if the formal publisher server group of the server cluster in all regions all responds
Abnormal, then by first agent's server configuration information based on self, access request can be acted on behalf of to first service
Pre-publisher server group in device cluster.
In more extreme cases, if the Servers-all in the pre-publisher server group of first server cluster
All response abnormality, then can act on behalf of supreme by access request by first agent's server configuration information based on self
State the pre-publisher server group in the server cluster in next region, repeat this operation until access request obtains
To normal response.
In the case of the formal publisher server group of Servers-all cluster all delays machine, follow-up when can be spaced
Between whether detect formal publisher server group normal, if formally recovered, it is possible to switch back into and formally issue clothes
Business device group.
In one example, the main part of access request can be resolved to obtain user by first agent's server
ID, for the mark of load balancing.Such as, first agent's server can be based on locally stored pass
Request form in access request performs parsing to the main part of access request.
Although illustrate for making explanation simplify said method and be described as a series of actions, it should be understood that also
Understanding, these methods are not limited by the order of action, because of according to one or more embodiments, and some actions
Can occur in different order and/or with from depicted and described herein or the most not shown and describe but this
Skilled person may be appreciated other actions and occurs concomitantly.
In the present invention, by adding the concept of region, can be individually to some region Proxy load, also
Can configure multiple region, multiple regions carry out load agent, multiple regions switch over, it is provided that generation
The motility of reason.On the other hand, issue and the pre-real-time switching issuing environment by providing formal, solve
The problem come into force after needing to restart after the amendment configuration of all proxy servers, this technology need not the service of restarting
Device, revises any configuration and comes into force the most in real time, it is achieved that the effect of dynamic proxy.
Additionally, compare nginx can only obtain load strategy related content from request header information, the present invention is led to
Cross analysis request body acquisition of information load strategy content, thus strengthen load strategy, solve general load
The problem that strategy execution mode is single, thus support that Proxy load equalizes multiformity, such as can support wechat
With various ways such as webservice.
Skilled artisans will appreciate that, the various illustrative described in conjunction with the embodiments described herein
Logic plate, module, circuit and algorithm steps can be embodied as electronic hardware, computer software or this two
The combination of person.For clearly explaining orally this interchangeability of hardware and software, various illustrative components, frame,
Module, circuit and step are made vague generalization above with its functional form and are described.This type of is functional
It is implemented as hardware or software depends on specifically applying and putting on the design constraint of total system.Technology
Personnel can realize described functional for every kind of application-specific by different modes, but such realization
Decision-making should not be interpreted to cause departing from the scope of the present invention.
The various illustrative logic modules and the circuit that describe in conjunction with presently disclosed embodiment can use general place
Reason device, digital signal processor (DSP), special IC (ASIC), field programmable gate array
(FPGA) or other PLD, discrete door or transistor logic, discrete nextport hardware component NextPort,
Or its any combination being designed to carry out function described herein realizes or performs.General processor can be
Microprocessor, but in alternative, this processor can be the processor of any routine, controller, micro-
Controller or state machine.Processor is also implemented as the combination of calculating equipment, such as DSP with micro-
One or more microprocessors that the combination of processor, multi-microprocessor cooperate with DSP core or
Any other this type of configuration.
The method described in conjunction with embodiment disclosed herein or the step of algorithm can be embodied directly in hardware, in by
Embody in the software module that processor performs or in combination of the two.Software module can reside in RAM
Memorizer, flash memory, ROM memory, eprom memory, eeprom memory, depositor,
Hard disk, removable dish, CD-ROM or known in the art any other form storage medium in.
Exemplary storage medium is coupled to processor so that this processor can read from/to this storage medium and write
Information.In alternative, storage medium can be integrated into processor.Processor and storage medium can be stayed
Stay in ASIC.ASIC can reside in user terminal.In alternative, processor and storage are situated between
Matter can be resident in the user terminal as discrete assembly.
In one or more exemplary embodiments, described function can hardware, software, firmware or its
Any combination realizes.If being embodied as computer program in software, the most each function can be as one
Bar or more a plurality of instruction or code storage on a computer-readable medium or mat its transmit.Computer-readable
Medium includes computer-readable storage medium and communication media, and it includes facilitating computer program from a ground to separately
Any medium of one ground transfer.Storage medium can be any usable medium that can be accessed by a computer.As
Example and non-limiting, such computer-readable medium can include RAM, ROM, EEPROM, CD-ROM
Or other optical disc storage, disk storage or other magnetic storage apparatus, maybe can be used to carry or store instruction or
The desirable program code of data structure form and other medium any that can be accessed by a computer.Any connection is also
It is properly termed a computer-readable medium.Such as, if software be use coaxial cable, fiber optic cables,
Twisted-pair feeder, numeral subscriber's line (DSL) or the wireless skill of the most infrared, radio and microwave etc
Art from web site, server or other remote source transmission, then this coaxial cable, fiber optic cables,
The wireless technology of twisted-pair feeder, DSL or the most infrared, radio and microwave etc is just included in Jie
Among the definition of matter.As used herein dish (disk) and dish (disc) include compact disc (CD),
Laser dish, laser disc, digital versatile dish (DVD), floppy disk and blu-ray disc, its mid-game (disk) often with
The mode of magnetic reproduces data, and dish (disc) reproduces data optically with laser.Combinations of the above is also
Should be included within the scope of computer readable media.
Thering is provided of this disclosure being previously described is for making any person skilled in the art all can make or make
Use the disclosure.Various amendment of this disclosure the most all will be apparent from, and
The generic principles defined herein can be applied to other variants without departing from the spirit of the disclosure or model
Enclose.Thus, the disclosure is not intended to be limited to example described herein and design, but should be awarded
Give the widest scope consistent with principle disclosed herein and novel features.
Claims (20)
1. for a Proxy Method for network, including:
Access request is performed domain name mapping, described access request is resolved to the in multiple proxy servers
One proxy server, the plurality of proxy server is deployed in different regions;And
By described first agent's server configuration information based on self by described access request agency to first-selected
Server cluster in region.
2. Proxy Method as claimed in claim 1, it is characterised in that described execution domain name mapping includes:
Described access request is resolved to described first agent service by launch position based on described access request
Device, the launch position of described access request falls in the first region residing for described first agent's server.
3. Proxy Method as claimed in claim 2, it is characterised in that based on described configuration information, institute
Stating the server cluster in first-selected region is the server cluster in described first region.
4. Proxy Method as claimed in claim 1, it is characterised in that described by described access request generation
Server cluster in the most first-selected region of reason farther includes:
Based on load balancing by the server cluster in described access request agency to described first-selected region
In a server.
5. Proxy Method as claimed in claim 4, it is characterised in that described by described access request generation
Server cluster in the most first-selected region of reason farther includes:
If the described server response abnormality acted on behalf of, then it is again based on load balancing by described access
Request agency is to other servers in the server cluster in the most described first-selected region until described access request
Obtain normal response.
6. Proxy Method as claimed in claim 4, it is characterised in that described by described access request generation
Server cluster in the most first-selected region of reason farther includes:
If the equal response abnormality of Servers-all in server cluster in described first-selected region, then by described the
One proxy server configuration information based on self is by the service in described access request agency to another region
Device cluster.
7. Proxy Method as claimed in claim 6, it is characterised in that also include:
Obtain in server cluster and the described access request that described access request is acted on behalf of to another region
After normal response, revise described configuration information another region described to be configured to first-selected region.
8. Proxy Method as claimed in claim 4, it is characterised in that described load balancing includes
Following at least one: repeating query equilibrium, weight repeating query equilibrium, Stochastic Equilibrium, response speed equilibrium, minimum company
Connect number equilibrium, disposal ability equalizes, DNS responds equilibrium.
9. Proxy Method as claimed in claim 4, it is characterised in that described access request includes head
Part and main part, described Proxy Method also includes:
By the main part of described first agent's server described access request of parsing to obtain ID, with
Mark for described load balancing.
10. Proxy Method as claimed in claim 9, it is characterised in that described first agent's server base
In the locally stored request form about described access request, the main part of described access request is performed
Resolve.
11. 1 kinds of agency plants for network, including:
Domain name resolution server, for performing domain name mapping to access request;
Multiple proxy servers, the plurality of proxy server is deployed in different regions;
Multiple server clusters, the plurality of server cluster is deployed in different regions,
Described access request is resolved to the plurality of proxy server by wherein said domain name resolution server
First agent's server, described first agent's server for configuration information based on self by described visit
Ask the server cluster in the most first-selected region of request agency.
12. agency plants as claimed in claim 11, it is characterised in that domain name resolution server
Described access request is resolved to described first agent's server, institute by launch position based on described access request
The launch position stating access request falls in the first region residing for described first agent's server.
13. agency plants as claimed in claim 12, it is characterised in that based on described configuration information,
Server cluster in described first-selected region is the server cluster in described first region.
14. agency plants as claimed in claim 11, it is characterised in that described first agent's server
It is further used for
Based on load balancing by the server cluster in described access request agency to described first-selected region
In a server.
15. agency plants as claimed in claim 14, it is characterised in that described first agent's server
If being further used for the described server response abnormality acted on behalf of, then it is again based on load balancing by institute
State access request agency to other servers in the server cluster in the most described first-selected region until described visit
The request of asking obtains normal response.
16. agency plants as claimed in claim 14, it is characterised in that described first agent's server
If the equal response abnormality of Servers-all in the server cluster being further used in described first-selected region, then base
Described access request is acted on behalf of the server cluster to another region by the configuration information in self.
17. agency plants as claimed in claim 16, it is characterised in that described first agent's server
It is further used for by the server cluster in described access request agency to another region and described access
After request obtains normal response, revise the configuration information of self another region described to be configured to first-selected ground
Territory.
18. agency plants as claimed in claim 14, it is characterised in that described load balancing bag
Include following at least one: repeating query equilibrium, weight repeating query equilibrium, Stochastic Equilibrium, response speed equilibrium, minimum
Connect number equilibrium, disposal ability equalizes, DNS responds equilibrium.
19. agency plants as claimed in claim 14, it is characterised in that described access request includes head
Portion's part and main part, described first agent's server also includes:
Parsing module, for resolving the main part of described access request to obtain ID, for institute
State the mark of load balancing.
20. agency plants as claimed in claim 19, it is characterised in that described first agent's server
Including data base, in described data base, storage has the request form of multiple request type, and described parsing module is looked into
Described data base is looked for carry out the main part to described access request with the request form asked according to described user
Perform parsing.
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610510314.5A CN105959413B (en) | 2016-06-30 | Network agent method and agency plant | |
CN201910425062.XA CN110138872B (en) | 2016-06-30 | 2016-06-30 | Computer readable medium for network proxy |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610510314.5A CN105959413B (en) | 2016-06-30 | Network agent method and agency plant |
Related Child Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910425062.XA Division CN110138872B (en) | 2016-06-30 | 2016-06-30 | Computer readable medium for network proxy |
Publications (2)
Publication Number | Publication Date |
---|---|
CN105959413A true CN105959413A (en) | 2016-09-21 |
CN105959413B CN105959413B (en) | 2019-07-16 |
Family
ID=
Cited By (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106453296A (en) * | 2016-09-30 | 2017-02-22 | 乐视控股(北京)有限公司 | Request service isolating method and system |
CN106686102A (en) * | 2017-01-03 | 2017-05-17 | 北京奇虎科技有限公司 | Switching method and device of service node |
CN107819872A (en) * | 2017-11-22 | 2018-03-20 | 聚好看科技股份有限公司 | Ask the method and device of network data |
CN108900598A (en) * | 2018-06-26 | 2018-11-27 | 杭州朗和科技有限公司 | Network request forwarding and response method, device, system, medium and electronic equipment |
CN109204188A (en) * | 2017-07-03 | 2019-01-15 | 矢崎总业株式会社 | setting device and computer |
CN109547547A (en) * | 2018-11-23 | 2019-03-29 | 北京知道创宇信息技术有限公司 | Return source dispatching method, device and its storage medium |
CN110138876A (en) * | 2019-05-30 | 2019-08-16 | 北京达佳互联信息技术有限公司 | Task deployment method, apparatus, equipment and platform |
CN110602254A (en) * | 2019-10-08 | 2019-12-20 | 腾讯科技(深圳)有限公司 | Method, device and system for realizing load balance |
CN112565473A (en) * | 2019-09-10 | 2021-03-26 | 阿里巴巴集团控股有限公司 | Access control system and method, electronic device, and computer-readable storage medium |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101431532A (en) * | 2008-12-15 | 2009-05-13 | 中国电信股份有限公司 | Content routing method, load balancing equipment and resource management equipment |
CN102333123A (en) * | 2011-10-08 | 2012-01-25 | 北京星网锐捷网络技术有限公司 | File storage method and device, searching method and device and network device |
CN102457557A (en) * | 2010-10-29 | 2012-05-16 | 卓望数码技术(深圳)有限公司 | Wireless network application system and wireless network application method based on C/S (client/server) structure |
US20140040478A1 (en) * | 2000-09-26 | 2014-02-06 | Brocade Communications Systems, Inc. | Global server load balancing |
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20140040478A1 (en) * | 2000-09-26 | 2014-02-06 | Brocade Communications Systems, Inc. | Global server load balancing |
CN101431532A (en) * | 2008-12-15 | 2009-05-13 | 中国电信股份有限公司 | Content routing method, load balancing equipment and resource management equipment |
CN102457557A (en) * | 2010-10-29 | 2012-05-16 | 卓望数码技术(深圳)有限公司 | Wireless network application system and wireless network application method based on C/S (client/server) structure |
CN102333123A (en) * | 2011-10-08 | 2012-01-25 | 北京星网锐捷网络技术有限公司 | File storage method and device, searching method and device and network device |
Non-Patent Citations (1)
Title |
---|
蒋业文: "CDN关键技术的研究及其系统设计", 《中国优秀硕士学位论文全文数据库(电子期刊)》 * |
Cited By (14)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106453296A (en) * | 2016-09-30 | 2017-02-22 | 乐视控股(北京)有限公司 | Request service isolating method and system |
CN106686102A (en) * | 2017-01-03 | 2017-05-17 | 北京奇虎科技有限公司 | Switching method and device of service node |
CN106686102B (en) * | 2017-01-03 | 2020-04-14 | 北京奇虎科技有限公司 | Service node switching method and device |
CN109204188A (en) * | 2017-07-03 | 2019-01-15 | 矢崎总业株式会社 | setting device and computer |
CN109204188B (en) * | 2017-07-03 | 2022-02-01 | 矢崎总业株式会社 | Setting device and computer |
CN107819872A (en) * | 2017-11-22 | 2018-03-20 | 聚好看科技股份有限公司 | Ask the method and device of network data |
CN108900598B (en) * | 2018-06-26 | 2021-06-11 | 杭州朗和科技有限公司 | Network request forwarding and responding method, device, system, medium and electronic equipment |
CN108900598A (en) * | 2018-06-26 | 2018-11-27 | 杭州朗和科技有限公司 | Network request forwarding and response method, device, system, medium and electronic equipment |
CN109547547A (en) * | 2018-11-23 | 2019-03-29 | 北京知道创宇信息技术有限公司 | Return source dispatching method, device and its storage medium |
CN110138876A (en) * | 2019-05-30 | 2019-08-16 | 北京达佳互联信息技术有限公司 | Task deployment method, apparatus, equipment and platform |
CN110138876B (en) * | 2019-05-30 | 2022-07-08 | 北京达佳互联信息技术有限公司 | Task deployment method, device, equipment and platform |
CN112565473A (en) * | 2019-09-10 | 2021-03-26 | 阿里巴巴集团控股有限公司 | Access control system and method, electronic device, and computer-readable storage medium |
CN110602254A (en) * | 2019-10-08 | 2019-12-20 | 腾讯科技(深圳)有限公司 | Method, device and system for realizing load balance |
CN110602254B (en) * | 2019-10-08 | 2022-05-20 | 腾讯科技(深圳)有限公司 | Method, device and system for realizing load balance |
Also Published As
Publication number | Publication date |
---|---|
CN110138872B (en) | 2022-02-25 |
CN110138872A (en) | 2019-08-16 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN111314472B (en) | Domain name resolution method, domain name resolution server and terminal equipment | |
US20090210513A1 (en) | Asynchronous automated routing of user to optimal host | |
US20080243634A1 (en) | Providing website hosting overage protection by transference to an overflow server | |
US10749838B2 (en) | DNS server and configuration loading method, DNS network system, and domain name resolution method and system | |
CN111182089B (en) | Container cluster system, method and device for accessing big data assembly and server | |
CN105915655A (en) | Proxy method and agent method for network | |
US20080243536A1 (en) | Providing website hosting overage protection by storage on an independent data server | |
EP2779593A1 (en) | High performance DNS traffic management | |
US20120054265A1 (en) | Optimized Content Distribution Based on Metrics Derived from the End User | |
CN102047243A (en) | Request routing based on class | |
US8977758B2 (en) | Service bus system, service bus device, and method for assuring connection uniqueness | |
CN102077189A (en) | Request routing using network computing components | |
US9686158B1 (en) | Point to node in a multi-tiered middleware environment | |
CN105357233A (en) | Remote call method and device | |
EP3066577B1 (en) | Content node selection using network performance profiles | |
CN104320488A (en) | Proxy server system and proxy service method | |
US20130198409A1 (en) | Efficient implementation of user-provided dns names | |
CN104301439B (en) | Load-balancing method, apparatus and system | |
CN111556135A (en) | Request scheduling method, system and device and electronic equipment | |
CN108737591A (en) | A kind of method and device of service configuration | |
CN105049463B (en) | Disperse database, data sharing method, the device for disperseing database | |
CN104092751A (en) | Service access method and device | |
CN106254515A (en) | A kind of load-balancing method storing system and equipment | |
CN107040617A (en) | The method and device of data processing | |
CN105959413A (en) | Network proxy method and system |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant | ||
PE01 | Entry into force of the registration of the contract for pledge of patent right |
Denomination of invention: Network proxy method and proxy system Effective date of registration: 20230223 Granted publication date: 20190716 Pledgee: China Construction Bank Corporation Shanghai No.5 Sub-branch Pledgor: SHANGHAI XIAOI ROBOT TECHNOLOGY Co.,Ltd. Registration number: Y2023980033272 |
|
PE01 | Entry into force of the registration of the contract for pledge of patent right |