CN109688187A - Flow load balance method, apparatus, equipment and readable storage medium storing program for executing - Google Patents

Flow load balance method, apparatus, equipment and readable storage medium storing program for executing Download PDF

Info

Publication number
CN109688187A
CN109688187A CN201811047672.2A CN201811047672A CN109688187A CN 109688187 A CN109688187 A CN 109688187A CN 201811047672 A CN201811047672 A CN 201811047672A CN 109688187 A CN109688187 A CN 109688187A
Authority
CN
China
Prior art keywords
user terminal
near point
application server
service
site
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
Application number
CN201811047672.2A
Other languages
Chinese (zh)
Other versions
CN109688187B (en
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.)
Ping An Technology Shenzhen Co Ltd
Original Assignee
Ping An 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 Ping An Technology Shenzhen Co Ltd filed Critical Ping An Technology Shenzhen Co Ltd
Priority to CN201811047672.2A priority Critical patent/CN109688187B/en
Publication of CN109688187A publication Critical patent/CN109688187A/en
Application granted granted Critical
Publication of CN109688187B publication Critical patent/CN109688187B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/60Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources
    • H04L67/63Routing a service request depending on the request content or context
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1001Protocols in which an application is distributed across nodes in the network for accessing one among a plurality of replicated servers
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1001Protocols in which an application is distributed across nodes in the network for accessing one among a plurality of replicated servers
    • H04L67/1004Server selection for load balancing

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer And Data Communications (AREA)

Abstract

The invention discloses a kind of flow load balance method, apparatus, equipment and readable storage medium storing program for executing, the method is based on distributed computing technology, the described method includes: determining whether the user terminal is to access site for service for the first time when detecting the access request of user terminal access site for service;If so, the association that the access request is sent to site for service is shunted server;It receives the association and shunts server feedback to the near point application server address list of the user terminal, and acquire the corresponding first object data of the access request, wherein, the association shunts IP address of the server according to the user end in access request and obtains and feed back the near point application server address list;When detecting the user terminal access site for service again, corresponding data content is acquired based on the near point application server address list.The technical issues of existing flow load server load pressure of present invention solution is excessive, influences user experience.

Description

Flow load balance method, apparatus, equipment and readable storage medium storing program for executing
Technical field
The present invention relates to field of computer technology more particularly to a kind of flow load balance method, apparatus, equipment and readable Storage medium.
Background technique
Currently, site for service etc. is all the mode of passive flux forwarding, i.e. user terminal is all logical when accessing site for service It crosses site for service and corresponds to background traffic loaded server to do the cutting and forwarding of flow, that is to say, that the request of user is each Site for service background traffic loaded server will be arrived first and be just forwarded to actual application server.There is a large number of users end to ask When seeking access site for service, background traffic loaded server has a large amount of load pressure, or even will appear routed phenomenon of running quickly, separately Outside, since all user's requests are all to carry out cutting and forwarding by flow load server, thus, if flow load server It is attacked, will cause user terminal can not access server site, influence the consequence of user experience.
Summary of the invention
The main purpose of the present invention is to provide a kind of flow load balance method, apparatus, equipment and readable storage medium storing program for executing, It aims to solve the problem that since all user's requests are all to carry out cutting and forwarding by flow load server, causes flow load service The technical issues of device load pressure is excessive, influences user experience.
To achieve the above object, the present invention provides a kind of flow load balance method, the flow load balance method packet It includes:
When detecting the access request of user terminal access site for service, determine whether the user terminal is to access institute for the first time State site for service;
If the user terminal is to access the site for service for the first time, the access request is sent to the site for service Association shunt server;
It receives the association and shunts server feedback to the near point application server address list of the user terminal, and obtain Obtain the corresponding first object data of the access request, wherein the association shunts server and accesses according to the user end IP address in request obtains and feeds back the near point application server address list;
When detecting the user terminal access site for service again, obtained based on the near point application server address list Obtain corresponding data content.
Optionally, described when detecting the access request of user terminal access site for service, whether determine the user terminal It is to access the site for service step for the first time to include:
When detecting the access request of user terminal access site for service, whether inquiry user terminal has the site for service The address list of corresponding near point application server, wherein the address of the site for service and the near point application server There are preset association relationships for address;
If the user terminal has the address list of the corresponding near point application server of the site for service, it is determined that described User terminal is not to access the site for service for the first time;
If the user terminal does not have the address list of the corresponding near point application server of the site for service, it is determined that institute Stating user terminal is to access the site for service for the first time.
Optionally, described when detecting the access request of user terminal access site for service, whether determine the user terminal Being after accessing the site for service step for the first time includes:
If the user terminal is not to access the site for service for the first time, the near point application server address is arbitrarily chosen An address in list, by the address of selection alternately address;
To the alternative corresponding first near point application server transmission in the address access request, and receive described first Second target data of near point application server feedback.
Optionally, after the access request step to the alternative corresponding near point application server transmission in address Include:
Judge whether the user terminal receives the first near point application server feedback in the first preset duration Second target data;
If the user terminal does not receive second target data in the first preset duration, taken near point application Again another near point application server outside the first near point application server is chosen in business device address list, by the another close of selection Point application server is as the second near point application server;
The access request is sent to the second near point application server, and receives the second near point application server The third target data of feedback, to stop the choosing of other third near point application servers based on the received third target data It takes.
Optionally, include: after the access request step to the second near point application server transmission
Judge whether the user terminal receives the second near point application server feedback in the second preset duration Third target data;
If the user terminal does not receive the third target data in the second preset duration, the access is asked It asks to retransmit and shunts server to the association of the site for service, generate and send the first near point application server, institute It states the second near point application server and corresponds to invalid prompt information, visited so that the association shunts server based on the user terminal Ask that the IP address in request reacquires and feeds back new near point application server address;
If the user terminal receives the third target data in the second preset duration, based on described received the Three target datas stop the selection of other third near point application servers.
Optionally, described to receive the association shunting server feedback to the near point application server address of the user terminal List, and acquire the corresponding first object data step of the access request and include:
It receives the association and shunts server feedback to the near point application server address list of the user terminal, and receive The association that the association shunts server feedback shunts the request number of the currently pending access request of server;
According to the request number, determine that the access request corresponds to the request approach of first object data, to obtain To the corresponding first object data of the access request.
Optionally, described according to the request number, determine that the access request corresponds to the request way of first object data Diameter includes: to acquire the corresponding first object data step of the access request
If the request number is less than preset number, receives the association and shunt server feedback to the user terminal The access request is transmitted to the site for service so that the association shunts server by near point application server address list Destination application server, and receive the first object data of destination application server feedback;
If the request number is greater than or equal to preset number, receives the association and shunt server feedback to the use The near point application server address list at family end is based on the near point application server address list, chooses one of near point Application server receives the first object data of the destination application server feedback as destination application server.
The present invention also provides a kind of flow load balance device, the flow load balance device includes:
First determining module, for determining the user when detecting the access request of user terminal access site for service Whether end is to access the site for service for the first time;
Sending module sends the access request if being to access the site for service for the first time for the user terminal Server is shunted to the association of the site for service;
First receiving module shunts server feedback to the near point application service of the user terminal for receiving the association Device address list, and acquire the corresponding first object data of the access request, wherein the association shunts server root It is obtained according to the IP address in the user terminal access request and feeds back the near point application server address list.
Optionally, first determining module includes:
Query unit, for when detecting the access request of user terminal access site for service, whether inquiry user terminal to be deposited There is the address list of the corresponding near point application server of the site for service, wherein the address of the site for service and described close There are preset association relationships for the address of point application server;
First determination unit, if there being the ground of the corresponding near point application server of the site for service for the user terminal Location list, it is determined that the user terminal is not to access the site for service for the first time;
Second determination unit, if not having the corresponding near point application server of the site for service for the user terminal Address list, it is determined that the user terminal is to access the site for service for the first time.
Optionally, the flow load balance device further include:
It chooses module and arbitrarily chooses the near point if not being to access the site for service for the first time for the user terminal An address in application server address list, by the address of selection alternately address;
Second receiving module, for being asked to the alternative corresponding first near point application server transmission in the address access It asks, and receives the second target data of the first near point application server feedback.
Optionally, the second receiving module further include:
Whether judging unit receives the first near point application for judging the user terminal in the first preset duration Second target data of server feedback;
Again selection unit, if not receiving second target data in the first preset duration for the user terminal When, from another near point application clothes chosen again in the near point application server address list outside the first near point application server Business device, using another near point application server of selection as the second near point application server;
First receiving unit, for sending the access request to the second near point application server, and described in reception The third target data of second near point application server feedback, to stop other thirds based on the received third target data The selection of near point application server.
Optionally, the receiving unit includes:
Whether judgment sub-unit receives second near point in the second preset duration for judging the user terminal and answers With the third target data of server feedback;
Subelement is retransmitted, if not receiving the third number of targets in the second preset duration for the user terminal According to when, then the association retransmitted the access request to the site for service shunts server, generates and sends described the One near point application server, the second near point application server correspond to invalid prompt information, take so that the association shunts Business device is reacquired based on the IP address in the user terminal access request and feeds back new near point application server address;
If the user terminal receives the third target data in the second preset duration, based on described received the Three target datas stop the selection of other third near point application servers.Optionally, first receiving module includes:
Second receiving unit shunts server feedback to the near point application service of the user terminal for receiving the association Device address list, and receive the association shunting currently pending access request of server that the association shunts server feedback Request number;
Third determination unit, for determining that the access request corresponds to first object data according to the request number Request approach, to acquire the corresponding first object data of the access request.
Optionally, the third determination unit includes:
First receiving subelement receives the association and shunts service if being less than preset number for the request number Device feeds back to the near point application server address list of the user terminal, asks the access so that the association shunts server The destination application server for being transmitted to the site for service is sought, and receives the first object number of the destination application server feedback According to;
Second receiving subelement receives the association point if being greater than or equal to preset number for the request number Streaming server feeds back to the near point application server address list of the user terminal, is arranged based on the near point application server address Table chooses one of near point application server as destination application server, and receives the destination application server feedback First object data.
In addition, to achieve the above object, the present invention also provides a kind of flow load balance equipment, the flow load balances Equipment includes: memory, processor, communication bus and the flow load balance program being stored on the memory,
The communication bus is for realizing the communication connection between processor and memory;
The processor is for executing the flow load balance program, to perform the steps of
When detecting the access request of user terminal access site for service, determine whether the user terminal is to access institute for the first time State site for service;
If the user terminal is to access the site for service for the first time, the access request is sent to the site for service Association shunt server;
It receives the association and shunts server feedback to the near point application server address list of the user terminal, and obtain Obtain the corresponding first object data of the access request, wherein the association shunts server and accesses according to the user end IP address in request obtains and feeds back the near point application server address list;
When detecting the user terminal access site for service again, obtained based on the near point application server address list Obtain corresponding data content.
In addition, to achieve the above object, the present invention also provides a kind of readable storage medium storing program for executing, the readable storage medium storing program for executing storage Have one perhaps more than one program the one or more programs can be held by one or more than one processor Row is to be used for:
When detecting the access request of user terminal access site for service, determine whether the user terminal is to access institute for the first time State site for service;
If the user terminal is to access the site for service for the first time, the access request is sent to the site for service Association shunt server;
It receives the association and shunts server feedback to the near point application server address list of the user terminal, and obtain Obtain the corresponding first object data of the access request, wherein the association shunts server and accesses according to the user end IP address in request obtains and feeds back the near point application server address list;
When detecting the user terminal access site for service again, obtained based on the near point application server address list Obtain corresponding data content.
Whether the present invention is by first determining the user terminal when detecting that user terminal accesses the access request of site for service It is to access the site for service for the first time;If the user terminal is to access the site for service for the first time, the access request is sent out The association for giving the site for service shunts server;It receives the association and shunts server feedback to the near point of the user terminal Application server address list, and acquire the corresponding first object data of the access request, wherein the association shunts IP address of the server according to the user end in access request obtains and feeds back the near point application server address list;? When detecting the user terminal access site for service again, correspondence is acquired based on the near point application server address list Data content.It i.e. in this application, is no longer the mode of passive flux forwarding, i.e., all user's requests are not all by flow Whether loaded server carries out cutting and forwarding, but be to access the site for service for the first time according to user terminal, carries out flow Actively forward in batches, avoid site for service background traffic loaded server and need cutting and forward all access request, Thus, it is possible to which the pressure of site for service background traffic loaded server is effectively relieved, thus solve since all users ask Asking all is to carry out cutting and forwarding by flow load server, causes flow load server load pressure excessive, influences user The technical issues of experience.
Detailed description of the invention
Fig. 1 is the flow diagram of inventive flow load-balancing method first embodiment;
Fig. 2 is described in inventive flow load-balancing method in the access request for detecting user terminal access site for service When, determine whether the user terminal is the refinement flow diagram for accessing the site for service step for the first time;
Fig. 3 is the device structure schematic diagram for the hardware running environment that present invention method is related to.
The embodiments will be further described with reference to the accompanying drawings for the realization, the function and the advantages of the object of the present invention.
Specific embodiment
It should be appreciated that the specific embodiments described herein are merely illustrative of the present invention, it is not intended to limit the present invention.
The present invention provides a kind of flow load balance method, in the first embodiment of inventive flow load-balancing method In, referring to Fig.1, the flow load balance method includes:
Step S10 determines whether the user terminal is first when detecting the access request of user terminal access site for service The secondary access site for service;
The access request is sent to described by step S20 if the user terminal is to access the site for service for the first time The association of site for service shunts server;
Step S30 receives the near point application server address column that the association shunts server feedback to the user terminal Table, and acquire the corresponding first object data of the access request, wherein the association shunts server according to the use IP address in the access request of family end obtains and feeds back the near point application server address list;
Step S40, when detecting the user terminal access site for service again, based on the near point application server Location list acquires corresponding data content.
Specific step is as follows:
Step S10 determines whether the user terminal is first when detecting the access request of user terminal access site for service The secondary access site for service;
In the present embodiment, flow load balance method can be applied to user terminal, and user terminal, which can be, passes through browser Site for service is accessed, is also possible to access by official's application searches of site for service, the present embodiment is with user terminal in browser In directly access and be specifically described for the application scenarios of site for service, in the access for detecting user terminal access site for service When request, determine whether the user terminal is to access the site for service for the first time, for user terminal, can be by determination The no buffer address for having site for service judges whether the user terminal is to access the site for service for the first time, if user terminal has The buffer address of site for service, it is obvious that user terminal is not to access the site for service for the first time, does not have service network in user terminal The buffer address stood, does not identify whether user terminal accesses the site for service for the first time, this is because coming for user terminal It says, the site for service address of caching has timeliness.
Wherein, described when detecting the access request of user terminal access site for service referring to Fig. 2, determine the user Whether end is to access the site for service step for the first time to include:
Step S11, when detecting the access request of user terminal access site for service, it is described whether inquiry user terminal has The address list of the corresponding near point application server of site for service, wherein the address of the site for service and the near point application There are preset association relationships for the address of server;
In the present embodiment, by inquiring whether user terminal has the corresponding near point application server of the site for service The mode of address list judges whether the user terminal is to access the site for service for the first time, wherein near point application server is The application server of site for service, and the near point server is usually that site for service background traffic loaded server is needed user End request is forwarded to, and needs the application server of the actual treatment user terminal access request.Wherein, the ground of the site for service There are preset association relationship, which is that can be identified by user terminal for location and the address of the near point application server Out, the preset association relationship can be site for service address it is identical as the address part of near point application server, or It is that the address of site for service and the address of near point application server all carry identical identification information.
Step S12, if the user terminal has the address list of the corresponding near point application server of the site for service, Determining the user terminal not is to access the site for service for the first time;
Step S13, if the user terminal does not have the address list of the corresponding near point application server of the site for service, Then determine that the user terminal is to access the site for service for the first time.
If the user terminal has the address list of the corresponding near point application server of the site for service, it is determined that described User terminal is not to access the site for service for the first time, wherein the address list of the corresponding near point application server of the site for service Middle near point application server can be one either it is multiple, if the user terminal does not have the corresponding near point of the site for service The address list of application server, it is determined that the user terminal is to access the site for service for the first time, it should be noted that at this In embodiment, if having the buffer address of site for service in user terminal, it is determined that the user terminal has the site for service pair The address list for the near point application server answered.Judge whether there be the slow of site for service in user terminal wherein it is possible to first pass through After depositing address, then it is determined the address column whether user terminal has the corresponding near point application server of the site for service The determination step of table.
The access request is sent to described by step S20 if the user terminal is to access the site for service for the first time The association of site for service shunts server;
If the user terminal is to access the site for service for the first time, the access request is sent to the site for service Association shunt server, wherein the association of the site for service shunts server and is generally the shunting server of site for service, In addition, if it includes browsing that the association, which shunts server also, when user terminal accesses site for service by the cloud acceleration function of browser The shunting server of device, wherein if user terminal accesses site for service by the cloud acceleration function of browser, the access of user terminal Request is shunted by the shunting server of browser before this, after shunted again by the shunting server of site for service.The present embodiment It is specifically described so that association shunts server as the shunting server of site for service as an example.
Step S30 receives the near point application server address column that the association shunts server feedback to the user terminal Table, and acquire the corresponding first object data of the access request, wherein the association shunts server according to the use IP address in the access request of family end obtains and feeds back the near point application server address list;
Association shunts server after receiving user terminal and being to access the access request of the site for service for the first time, according to institute The IP address in user terminal access request is stated to obtain and feed back the near point application server address list, specifically, if with The IP address carried in the access request of family end is the IP address in Shanghai, then the near point application server address of site for service feedback Shanghai, if the IP address carried in user terminal access request is the IP address in Shenzhen, then site for service feedback near point Application server address is also Shenzhen, wherein site for service corresponds to each according to the IP address of user terminal and the IP address The history busy extent of application server determines each near point application server address of the user terminal, such as the IP address pair Answering each application server is a, b, c, d, e, f etc., and the application server address for feeding back to the user terminal only needs 3, The access request number then handled in time in the past section according to application servers such as a, b, c, d, e, f, determines the user terminal Each near point application server address, after determining each near point application server address of the user terminal, by user terminal Each near point application server address is sent to user terminal, and user terminal is receiving the association shunting server feedback to described After the near point application server address list of user terminal, the corresponding first object data of the access request are acquired,
Step S40, when detecting the user terminal access site for service again, based on the near point application server Location list acquires corresponding data content.
In the present embodiment, when detecting the user terminal access site for service again, since user terminal has had It is capable of handling the near point application server address of access request, thus, it is based on the near point application server address list Acquire corresponding data content.
It should be noted that in the present embodiment, it is described when detecting the access request of user terminal access site for service, Determine whether the user terminal is after accessing the site for service step for the first time and includes:
Step A1 arbitrarily chooses the near point application clothes if the user terminal is not to access the site for service for the first time An address being engaged in device address list, by the address of selection alternately address;
In the present embodiment, each near point server address can be randomly ordered, to generate near point server address List arbitrarily chooses the near point application server address column if the user terminal is not to access the site for service for the first time An address in table, by the address of selection alternately address, in addition, in the present embodiment, each near point server Address list can also carry out ordered arrays according to predetermined order rule, which can be according near point service Device title is ranked up, alternatively, can also be ranked up according near point server feedback to the chronological order of user terminal, because And other than the mode arbitrarily obtained, it can also be according near point server address each in each near point list of server addresses Sequence orderly obtain alternative address.
Step A2 to the alternative corresponding first near point application server transmission in the address access request, and is received Second target data of the first near point application server feedback.
After choosing alternative address, asked to the alternative corresponding first near point application server transmission in the address access It asks, and receives the second target data that the first near point application server is fed back, wherein if the association of site for service shunts After server is attacked, due to the presence of near point application server address list, the access request of user terminal still can be located Reason, rather than the state shelved, thus, the user experience is improved.
Whether the present invention is by first determining the user terminal when detecting that user terminal accesses the access request of site for service It is to access the site for service for the first time;If the user terminal is to access the site for service for the first time, the access request is sent out The association for giving the site for service shunts server;It receives the association and shunts server feedback to the near point of the user terminal Application server address list, and acquire the corresponding first object data of the access request, wherein the association shunts IP address of the server according to the user end in access request obtains and feeds back the near point application server address list;? When detecting the user terminal access site for service again, correspondence is acquired based on the near point application server address list Data content.It i.e. in this application, is no longer the mode of passive flux forwarding, i.e., all user's requests are not all by flow Whether loaded server carries out cutting and forwarding, but be to access the site for service for the first time according to user terminal, carries out flow Actively forward in batches, avoid site for service background traffic loaded server and need cutting and forward all access request, Thus, it is possible to which the pressure of site for service background traffic loaded server is effectively relieved, thus solve since all users ask Asking all is to carry out cutting and forwarding by flow load server, causes flow load server load pressure excessive, influences user The technical issues of experience.
Further, the present invention provides another embodiment of flow load balance method, in this embodiment, described to institute It states after the corresponding near point application server in alternative address sends the access request step and includes:
Step B1, judges whether the user terminal receives the first near point application server in the first preset duration Second target data of feedback;
In the present embodiment, there may be changes for the application server of site for service, if user terminal does not request to visit for a long time Ask site for service, thus, after change, user terminal may not have close after address change the application server of site for service Point application server address or the currently stored near point application server address of user terminal may be it is invalid, thus, use Family end be also impossible to acquire based on the invalid near point application server address in requisition for data, i.e., in the present embodiment In, need to judge whether the user terminal receives the of the first near point application server feedback in the first preset duration Two target datas.
Step B2, if the user terminal does not receive second target data in the first preset duration, from described close Again another near point application server outside the first near point application server is chosen in point application server address list, will be chosen Another near point application server as the second near point application server;
The second near point application server of step B3, Xiang Suoshu sends the access request, and receives second near point and answer With the third target data of server feedback, taken with stopping other third near point applications based on the received third target data The selection of business device.
If the user terminal does not receive second target data in the first preset duration, need from the near point Again another near point application server outside the first near point application server is chosen in application server address list, by selection Another near point application server is as the second near point application server, wherein chooses the side of another near point application server again Formula can be identical as the mode of the first near point application server is chosen, and can also be different, and is choosing the second near point application server Afterwards, Xiang Suoshu the second near point application server sends the access request, and receives the second near point application server feedback Third target data, to stop the selection of other third near point application servers based on the received third target data.
In the present embodiment, described to send access request step packet later to the second near point application server It includes:
Step C1, judges whether the user terminal receives the second near point application server in the second preset duration The third target data of feedback;
Step C2, if the user terminal does not receive the third target data in the second preset duration, by institute It states access request to retransmit to the association shunting server of the site for service, generates and sends the first near point application clothes Business device, the second near point application server correspond to invalid prompt information, so that the association shunts server based on described IP address in user terminal access request reacquires and feeds back new near point application server address;
If the user terminal receives the third target data in the second preset duration, based on described received the Three target datas stop the selection of other third near point application servers.Due to currently stored the second near point application clothes of user terminal Business device address is also likely to be invalid, it is then desired to which it is described to judge whether the user terminal receives in the second preset duration The third target data of second near point application server feedback, does not receive the second near point application in the second preset duration After the third target data of server feedback, to avoid excessive when consumption, the selection of other near point application servers is no longer carried out, But the association for then retransmitting the access request to the site for service shunts server, takes so that the association shunts Business device is reacquired based on the IP address in the user terminal access request and feeds back new near point application server address;Separately Outside, it is invalid that user terminal also generates and sends the first near point application server, the second near point application server corresponds to Prompt information rejects the invalid near point application clothes so that server end when sending new near point application server again Business device, to promote user experience.
In the present embodiment, first near point whether is received in the first preset duration by judging the user terminal Second target data of application server feedback;If the user terminal does not receive second number of targets in the first preset duration According to when, from another near point application chosen again in the near point application server address list outside the first near point application server Server, using another near point application server of selection as the second near point application server;It is taken to second near point application Business device sends the access request, and receives the third target data of the second near point application server feedback, to be based on institute State the selection that received third target data stops other third near point application servers.Due in the present embodiment, not connecing When receiving the data for needing to feed back, other schemes can be timely responded to, thus, it is possible to avoid the processing card of user terminal access request Shell, the user experience is improved.
Further, the present invention provides another embodiment of flow load balance method, in this embodiment, the reception The association shunts server feedback to the near point application server address list of the user terminal, and acquires the access The corresponding first object data step is requested to include:
Step S31 receives the near point application server address column that the association shunts server feedback to the user terminal Table, and receive the number of request that the association shunts the association shunting currently pending access request of server of server feedback Mesh;
In the present embodiment, the association shunting server feedback is being received to the near point application server of the user terminal After address list, the access request for the first time that user terminal requests access to site for service can be association and shunt at server shunting forwarding Reason, is also possible to the near point application server address by feeding back to the user terminal, correspondence access request will be sent to for the first time Near point application server processes, which kind of specific processing mode or processing approach need to obtain the association and shunt server feedback The association shunt the currently pending access request of server request number be determined.
Step S32 determines that the access request corresponds to the request approach of first object data according to the request number, To acquire the corresponding first object data of the access request.
According to the request number, determine that the access request corresponds to the request approach of first object data, to obtain To the corresponding first object data of the access request.Wherein, described according to the request number, determine the access request pair The request approach of first object data is answered, includes: to acquire the corresponding first object data step of the access request
Step D1 receives the association and shunts server feedback to described if the request number is less than preset number The near point application server address list of user terminal, for the association shunt server the access request is transmitted to it is described The destination application server of site for service, and receive the first object data of the destination application server feedback;
Step D2 receives the association and shunts server feedback if the request number is greater than or equal to preset number To the near point application server address list of the user terminal, it is based on the near point application server address list, is chosen wherein One near point application server receives the first object number of the destination application server feedback as destination application server According to.
In the present embodiment, due to that the access request can be transmitted to institute when association shunting server is not busy The destination application server of site for service is stated, if association shunting server is busy, directly sends the request to target Application server processes judge whether association shunting server is busy according to whether request number is greater than or equal to preset number, Thus, it is possible to reduce the processing time of user terminal access request, it is thus possible to promote user experience.
Referring to Fig. 3, Fig. 3 is the device structure schematic diagram for the hardware running environment that the embodiment of the present invention is related to.
Flow load balance equipment of the embodiment of the present invention can be PC, be also possible to smart phone, tablet computer, e-book Reader, MP3 (Moving Picture Experts Group Audio Layer III, dynamic image expert's compression standard Audio level 3) player, MP4 (Moving Picture Experts Group Audio Layer IV, dynamic image expert Compression standard audio level 3) terminal devices such as player, portable computer.
As shown in figure 3, the flow load balance equipment may include: processor 1001, such as CPU, memory 1005 leads to Believe bus 1002.Wherein, communication bus 1002 is for realizing the connection communication between processor 1001 and memory 1005.Storage Device 1005 can be high speed RAM memory, be also possible to stable memory (non-volatile memory), such as disk Memory.Memory 1005 optionally can also be the storage equipment independently of aforementioned processor 1001.
Optionally, which can also include target user interface, network interface, camera, RF (Radio Frequency, radio frequency) circuit, sensor, voicefrequency circuit, WiFi module etc..Target user interface may include Display screen (Display), input unit such as keyboard (Keyboard), optional target user interface can also include having for standard Line interface, wireless interface.Network interface optionally may include standard wireline interface and wireless interface (such as WI-FI interface).
It will be understood by those skilled in the art that flow load balance device structure shown in Fig. 3 is not constituted to flow The restriction of load-balancing device may include perhaps combining certain components or different than illustrating more or fewer components Component layout.
As shown in figure 3, as may include that operating system, network are logical in a kind of memory 1005 of computer storage medium Believe module and flow load balance program.Operating system is to manage and control flow load balance device hardware and software resource Program, support the operation of flow load balance program and other softwares and/or program.Network communication module is for realizing depositing Communication between the 1005 each component in inside of reservoir, and communicated between other hardware and softwares in flow load balance equipment.
In flow load balance equipment shown in Fig. 3, processor 1001 is for executing the stream stored in memory 1005 The step of measuring load balancing program, realizing flow load balance method described in any of the above embodiments.
Inventive flow load-balancing device specific embodiment and above-mentioned each embodiment of flow load balance method are basic Identical, details are not described herein.
The present invention also provides a kind of flow load balance device, the flow load balance device includes:
First determining module, for determining the user when detecting the access request of user terminal access site for service Whether end is to access the site for service for the first time;
Sending module sends the access request if being to access the site for service for the first time for the user terminal Server is shunted to the association of the site for service;
First receiving module shunts server feedback to the near point application service of the user terminal for receiving the association Device address list, and acquire the corresponding first object data of the access request, wherein the association shunts server root It is obtained according to the IP address in the user terminal access request and feeds back the near point application server address list.
Inventive flow load balancing apparatus specific embodiment and above-mentioned each embodiment of flow load balance method are basic Identical, details are not described herein.
The present invention provides a kind of readable storage medium storing program for executing, the readable storage medium storing program for executing is stored with one or more than one journey Sequence, the one or more programs can also be executed by one or more than one processor for realizing above-mentioned The step of flow load balance method described in one.
Readable storage medium storing program for executing specific embodiment of the present invention and above-mentioned each embodiment of flow load balance method are essentially identical, Details are not described herein.
The above is only a preferred embodiment of the present invention, is not intended to limit the scope of the invention, all to utilize this hair Equivalent structure or equivalent flow shift made by bright specification and accompanying drawing content is applied directly or indirectly in other relevant skills Art field similarly includes in patent process range of the invention.

Claims (10)

1. a kind of flow load balance method, which is characterized in that the flow load balance method includes:
When detecting the access request of user terminal access site for service, determine whether the user terminal is to access the clothes for the first time Business website;
If the user terminal is to access the site for service for the first time, the access request is sent to the pass of the site for service Connection shunts server;
It receives the association and shunts server feedback to the near point application server address list of the user terminal, and acquire The corresponding first object data of the access request, wherein the association shunts server access request according to the user end In IP address obtain and feed back the near point application server address list;
When detecting the user terminal access site for service again, obtained based on the near point application server address list To corresponding data content.
2. flow load balance method as described in claim 1, which is characterized in that described to detect user terminal access service When the access request of website, determine whether the user terminal is to access the site for service step for the first time to include:
When detecting the access request of user terminal access site for service, it is corresponding whether inquiry user terminal has the site for service Near point application server address list, wherein the address of the address of the site for service and the near point application server There are preset association relationships;
If the user terminal has the address list of the corresponding near point application server of the site for service, it is determined that the user End is not to access the site for service for the first time;
If the user terminal does not have the address list of the corresponding near point application server of the site for service, it is determined that the use Family end is to access the site for service for the first time.
3. flow load balance method as described in claim 1, which is characterized in that described to detect user terminal access service When the access request of website, determine whether the user terminal is after accessing the site for service step for the first time and includes:
If the user terminal is not to access the site for service for the first time, the near point application server address list is arbitrarily chosen In an address, by the address of selection alternately address;
To the alternative corresponding first near point application server transmission in the address access request, and receive first near point Second target data of application server feedback.
4. flow load balance method as claimed in claim 3, which is characterized in that described corresponding close to the alternative address Point application server sends the access request step
Judge whether the user terminal receives the second of the first near point application server feedback in the first preset duration Target data;
If the user terminal does not receive second target data in the first preset duration, from the near point application server Again another near point application server outside the first near point application server is chosen in address list, and another near point of selection is answered Use server as the second near point application server;
The access request is sent to the second near point application server, and receives the second near point application server feedback Third target data, to stop the selection of other third near point application servers based on the received third target data.
5. flow load balance method as claimed in claim 4, which is characterized in that described to the second near point application service Device sends the access request step
Judge whether the user terminal receives the third of the second near point application server feedback in the second preset duration Target data;
If the user terminal does not receive the third target data in the second preset duration, by the access request weight The association for being newly sent to the site for service shunts server, generates and sends the first near point application server, described the Two near point application servers correspond to invalid prompt information, are asked so that the association shunts server based on user terminal access IP address in asking reacquires and feeds back new near point application server address;
If the user terminal receives the third target data in the second preset duration, it is based on the received third mesh Mark data stop the selection of other third near point application servers.
6. flow load balance method as described in any one in claim 1-5, which is characterized in that described to receive the association point Streaming server feeds back to the near point application server address list of the user terminal, and it is corresponding to acquire the access request First object data step includes:
It receives the association and shunts server feedback to the near point application server address list of the user terminal, and described in reception The association that association shunts server feedback shunts the request number of the currently pending access request of server;
According to the request number, determine that the access request corresponds to the request approach of first object data, to acquire State the corresponding first object data of access request.
7. flow load balance method as claimed in claim 6, which is characterized in that it is described according to the request number, it determines The access request corresponds to the request approach of first object data, to acquire the corresponding first object number of the access request Include: according to step
If the request number is less than preset number, receives the association and shunt server feedback to the near point of the user terminal Application server address list, so that the association shunts the mesh that the access request is transmitted to the site for service by server Application server is marked, and receives the first object data of the destination application server feedback;
If the request number is greater than or equal to preset number, receives the association and shunt server feedback to the user terminal Near point application server address list, be based on the near point application server address list, choose one of near point application Server receives the first object data of the destination application server feedback as destination application server.
8. a kind of flow load balance device, which is characterized in that the flow load balance device includes:
First determining module, for determining that the user terminal is when detecting the access request of user terminal access site for service No is to access the site for service for the first time;
The access request is sent to institute if being to access the site for service for the first time for the user terminal by sending module The association for stating site for service shunts server;
Receiving module, the near point application server address column for shunting server feedback to the user terminal for receiving the association Table, and acquire the corresponding first object data of the access request, wherein the association shunts server according to the use IP address in the access request of family end obtains and feeds back the near point application server address list.
9. a kind of flow load balance equipment, which is characterized in that the flow load balance equipment includes: memory, processor, Communication bus and the flow load balance program being stored on the memory,
The communication bus is for realizing the communication connection between processor and memory;
The processor is for executing the flow load balance program, to realize as described in any one of claims 1 to 7 The step of flow load balance method.
10. a kind of readable storage medium storing program for executing, which is characterized in that flow load balance program is stored on the readable storage medium storing program for executing, Such as flow load balance of any of claims 1-7 is realized when the flow load balance program is executed by processor The step of method.
CN201811047672.2A 2018-09-07 2018-09-07 Flow load balancing method, device, equipment and readable storage medium Active CN109688187B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811047672.2A CN109688187B (en) 2018-09-07 2018-09-07 Flow load balancing method, device, equipment and readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811047672.2A CN109688187B (en) 2018-09-07 2018-09-07 Flow load balancing method, device, equipment and readable storage medium

Publications (2)

Publication Number Publication Date
CN109688187A true CN109688187A (en) 2019-04-26
CN109688187B CN109688187B (en) 2022-04-22

Family

ID=66185680

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811047672.2A Active CN109688187B (en) 2018-09-07 2018-09-07 Flow load balancing method, device, equipment and readable storage medium

Country Status (1)

Country Link
CN (1) CN109688187B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112637316A (en) * 2020-12-17 2021-04-09 中国农业银行股份有限公司 Communication method and device

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101557427A (en) * 2009-05-11 2009-10-14 阿里巴巴集团控股有限公司 Method for providing diffluent information and realizing the diffluence of clients, system and server thereof
WO2010028590A1 (en) * 2008-09-12 2010-03-18 中兴通讯股份有限公司 Method for providing address list, peer-to-peer network and scheduling method thereof
US20120198045A1 (en) * 2008-08-06 2012-08-02 Edgecast Networks, Inc. Global load balancing on a content delivery network
US20120233248A1 (en) * 2009-11-24 2012-09-13 Huawei Technologies Co., Ltd. Method and system for processing request message, and load balancer device
CN103634269A (en) * 2012-08-21 2014-03-12 中国银联股份有限公司 A single sign-on system and a method
CN103905500A (en) * 2012-12-27 2014-07-02 腾讯数码(天津)有限公司 Method and apparatus for accessing to application server
US20160234297A1 (en) * 2015-02-11 2016-08-11 International Business Machines Corporation Load-balancing input/output requests in clustered storage systems
CN106599308A (en) * 2016-12-29 2017-04-26 郭晓凤 Distributed metadata management method and system

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20120198045A1 (en) * 2008-08-06 2012-08-02 Edgecast Networks, Inc. Global load balancing on a content delivery network
WO2010028590A1 (en) * 2008-09-12 2010-03-18 中兴通讯股份有限公司 Method for providing address list, peer-to-peer network and scheduling method thereof
CN101557427A (en) * 2009-05-11 2009-10-14 阿里巴巴集团控股有限公司 Method for providing diffluent information and realizing the diffluence of clients, system and server thereof
US20120233248A1 (en) * 2009-11-24 2012-09-13 Huawei Technologies Co., Ltd. Method and system for processing request message, and load balancer device
CN103634269A (en) * 2012-08-21 2014-03-12 中国银联股份有限公司 A single sign-on system and a method
CN103905500A (en) * 2012-12-27 2014-07-02 腾讯数码(天津)有限公司 Method and apparatus for accessing to application server
WO2014101433A1 (en) * 2012-12-27 2014-07-03 腾讯科技(深圳)有限公司 Method and device for accessing application server
US20150334086A1 (en) * 2012-12-27 2015-11-19 Tencent Technology (Shenzhen) Company Limited Method and device for accessing application server
US20160234297A1 (en) * 2015-02-11 2016-08-11 International Business Machines Corporation Load-balancing input/output requests in clustered storage systems
CN106599308A (en) * 2016-12-29 2017-04-26 郭晓凤 Distributed metadata management method and system

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
YUYI MAO 等: "Joint Task Offloading Scheduling and Transmit Power Allocation for Mobile-Edge Computing Systems", 《IEEE》 *
王俊涛 等: "多前端并行负载均衡集群服务器的设计与实现", 《计算机工程与应用》 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112637316A (en) * 2020-12-17 2021-04-09 中国农业银行股份有限公司 Communication method and device
CN112637316B (en) * 2020-12-17 2024-02-27 中国农业银行股份有限公司 Communication method and device

Also Published As

Publication number Publication date
CN109688187B (en) 2022-04-22

Similar Documents

Publication Publication Date Title
CN106302434B (en) Server adaptation method, device and system
KR102021631B1 (en) Managing data transfers over network connections based on priority and a data usage plan
CN104580393B (en) Expansion method, device and server cluster system for server cluster system
CN103888358B (en) Routing method, device, system and gateway equipment
CN107395683A (en) The system of selection of a kind of time source path and server
CN106933871A (en) Short linking processing method, device and short linked server
CN109327550A (en) A kind of distribution method of access request, device, storage medium and computer equipment
CN107786621B (en) User information management method, access processing method, device and system
US20170180470A1 (en) Method and electronic device for sending CDN address
CN101156407B (en) Method for supplying content through communication network
CN106998370A (en) Access control method, device and system
CN102882939A (en) Load balancing method, load balancing equipment and extensive domain acceleration access system
CN103607312B (en) Data request processing method and system for server system
KR101705596B1 (en) Server device connecting usb device and device sharing method
WO2013140336A2 (en) System and method of managing servers for streaming desk top applications
CN105337786A (en) Server performance detection method, apparatus and equipment
US20170134927A1 (en) Device-to-device content delivery method through interworking with service control apparatus
CN109428839B (en) CDN scheduling method, device and system
CN109936639A (en) A kind of service calling method and server
US20170289243A1 (en) Domain name resolution method and electronic device
US20190205976A1 (en) Account number registration method, apparatus, and system
CN105791381A (en) Access control method and apparatus
CN105791254A (en) Network request processing method, device and terminal
US20150006622A1 (en) Web contents transmission method and apparatus
CN110213349A (en) A kind of HTTP dispatching method and device

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
GR01 Patent grant
GR01 Patent grant