CN103457869A - Conversation maintaining method and device - Google Patents

Conversation maintaining method and device Download PDF

Info

Publication number
CN103457869A
CN103457869A CN2013103818008A CN201310381800A CN103457869A CN 103457869 A CN103457869 A CN 103457869A CN 2013103818008 A CN2013103818008 A CN 2013103818008A CN 201310381800 A CN201310381800 A CN 201310381800A CN 103457869 A CN103457869 A CN 103457869A
Authority
CN
China
Prior art keywords
sign
session
server
request message
http request
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN2013103818008A
Other languages
Chinese (zh)
Inventor
邓晓明
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Star Net Ruijie Networks Co Ltd
Original Assignee
Beijing Star Net Ruijie Networks 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 Beijing Star Net Ruijie Networks Co Ltd filed Critical Beijing Star Net Ruijie Networks Co Ltd
Priority to CN2013103818008A priority Critical patent/CN103457869A/en
Publication of CN103457869A publication Critical patent/CN103457869A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Computer And Data Communications (AREA)

Abstract

The invention provides a conversation maintaining method and device. According to the conversation maintaining method and device, a conversation maintaining identification is set for a client side through load balancing equipment, the conversation maintaining identification is sent to the client side through an HTTP redirected response message which contains the conversation maintaining identification, the client side carries a conversation maintaining message in a subsequent HTTP request message, the load balancing equipment sends the HTTP request message to a corresponding server according to the correspondence between the conversation maintaining identification which is locally stored and servers so that HTTP request messages containing the same conversation maintaining identification can be sent to the same server, then conversation maintaining is achieved, and the server sends an HTTP response message to the load balancing equipment after receiving the HTTP request message. According to the conversation maintaining method and device, due to the fact that the HTTP response message can be directly transmitted to the client side by the load balancing equipment, the correspondence between the conversation maintaining identification and the server can be obtained without the need of analyzing each HTTP response message sent by the server. Accordingly, burden of the load balancing equipment is relieved, and processing capacity is improved.

Description

Session keeping method and device
Technical field
The present invention relates to computer technology, relate in particular to a kind of session keeping method and device.
Background technology
In the application scenarios of server cluster, many the servers with identical or identity function link together by load-balancing device, when the user end to server request service, the balance policy that the load-balancing device basis has configured is by the HTML (Hypertext Markup Language) of client (Hypertext transfer protocol, hereinafter to be referred as: HTTP) request message sends to the station server in server cluster, namely, according to the present load situation of each server in server cluster, the HTTP request message of client is reasonably allocated to different servers, thereby make balancedly load sharing of each server, improve systematic function.In this case, the different HTTP request messages of same client just may be assigned to different servers and processed.
Yet, under a lot of application scenarios, the request of client need to be processed by same station server.For example, the shopping cart of e-commerce website, carry out data interaction between client browser and webpage (Web) server, and when client, when adding commodity in shopping cart, server must retain the shopping cart information of client, just not there will be problem; The HTTP request message of the client that therefore, need to keep technology to need session to keep with assurance by session is assigned on same server to be processed.In prior art, load-balancing device is transmitted to server by the HTTP request message of client, server distributes cookie information according to the HTTP request message of client, and cookie information is included in the HTTP response message and sends to load-balancing device, the HTTP response message that the load-balancing device resolution server sends, and the corresponding relation of the server of the cookie information in storage HTTP response message and transmission above-mentioned HTTP response message, then, the HTTP response message is transmitted to client, client comprises above-mentioned cookie information in the follow-up HTTP request message that needs session to keep, load-balancing device is according to the cookie information of the cookie information in the HTTP request message and record and the corresponding relation of server, the HTTP request message is forwarded to the server in the corresponding relation of cookie information and server, thereby realize that session keeps.
Yet, adopt the method for prior art, cookie information is by Servers installed, load-balancing device can't be predicted server can comprise cookie information in which HTTP response message, therefore, each the HTTP response message that needs resolution server to send, to obtain the corresponding relation of cookie information and server, reduced the disposal ability of load-balancing device.
Summary of the invention
The invention provides a kind of session keeping method and device, to improve the disposal ability of load-balancing device.
Embodiment of the present invention first aspect provides a kind of session keeping method, comprising:
Receive the HTML (Hypertext Markup Language) HTTP request message that client sends, described HTTP request message is the HTTP request message that needs session to keep;
Judge in described HTTP request message that whether comprising session keeps sign, described session keeps identifying the HTTP request message be used to indicate comprising identical session maintenance sign and sends to same server;
If do not comprise, for arranging session, the client that sends described HTTP request message keeps sign, and send the HTTP redirection response message to described client, comprise described session in described HTTP redirection response message and keep sign, so that described client keeps sign to send and comprise the HTTP request message that described session keeps sign to load-balancing device according to described session;
If comprise, according to described session, keep the corresponding relation of sign and server, described HTTP request message is sent to described session and keeps server corresponding to sign;
The HTTP response message that described server is sent is transmitted to described client.
Embodiment of the present invention second aspect provides a kind of session keeping method, comprising:
The HTTP redirection response message that balancing received load equipment sends, comprise session and keep sign in described HTTP redirection response message;
Send the HTTP request message to described load-balancing device, comprise described session in described HTTP request message and keep sign, so that described load-balancing device keeps sign to be defined as the server of described client service according to described session.
The embodiment of the present invention third aspect provides a kind of session holding device, comprising:
Receiver module, the HTML (Hypertext Markup Language) HTTP request message sent for receiving client, described HTTP request message is the HTTP request message that needs session to keep;
Processing module, for judging whether described HTTP request message comprises session and keep sign, described session keeps identifying the HTTP request message be used to indicate comprising identical session maintenance sign and sends to same server; If do not comprise, for arranging session, the client that sends described HTTP request message keeps sign, and send the HTTP redirection response message to described client, comprise described session in described HTTP redirection response message and keep sign, so that described client keeps sign to send and comprise the HTTP request message that described session keeps sign to load-balancing device according to described session; If comprise, according to described session, keep the corresponding relation of sign and server, described HTTP request message is sent to described session and keeps server corresponding to sign;
Sending module, be transmitted to described client for the HTTP response message that described server is sent.
Embodiment of the present invention fourth aspect provides a kind of session holding device, comprising: receiver module, and the HTTP redirection response message sent for balancing received load equipment, comprise session and keep sign in described HTTP redirection response message;
Sending module, for to described load-balancing device, sending the HTTP request message, comprise described session and keep sign in described HTTP request message, so that described load-balancing device keeps sign to be defined as the server of described client service according to described session.
Session keeping method provided by the invention and device, by load-balancing device, be that client arranges session maintenance sign, and keep the HTTP redirection response message of sign to keep sign to send to client above-mentioned session by comprising session, so that carrying above-mentioned session in follow-up HTTP request message, client keeps message, load-balancing device keeps the corresponding relation of sign and server according to the session of this locality storage, the HTTP request message is sent to the server that above-mentioned session keeps the corresponding relation of sign and server, to guarantee that having identical session keeps the HTTP request message of sign by same server service, thereby realize that session keeps, after server receives the HTTP request message, send the HTTP response message to load-balancing device, load-balancing device can directly be transmitted to client, and keep the corresponding relation of sign and server to obtain session without each the HTTP response message sent by resolution server, therefore, alleviated the burden of load-balancing device, improved disposal ability.
The accompanying drawing explanation
The schematic flow sheet that Fig. 1 is session keeping method embodiment mono-of the present invention;
The schematic flow sheet that Fig. 2 is session keeping method embodiment bis-of the present invention;
The schematic flow sheet that Fig. 3 is session keeping method embodiment tri-of the present invention;
The structural representation that Fig. 4 is session holding device embodiment mono-of the present invention;
The structural representation that Fig. 5 is session holding device embodiment bis-of the present invention;
The structural representation that Fig. 6 is session holding device embodiment tri-of the present invention.
Embodiment
In prior art, load-balancing device can't be predicted server can arrange cookie information in which HTTP response message, therefore, each HTTP response message that need to send by resolution server, to obtain the corresponding relation of cookie information and server, reduced the disposal ability of load-balancing device.In order to address the above problem, after load-balancing device of the present invention receives the HTTP request message of client transmission, if the HTTP request message is the HTTP request message that needs session to keep, judge in the HTTP request message that whether comprising session keeps sign, session keeps identifying the HTTP request message be used to indicate comprising identical session maintenance sign and sends to same server, it can be cookie information that session keeps sign, do not keep sign if comprise session in the HTTP request message, for arranging session, the client that sends the HTTP request message keeps sign, and send above-mentioned session maintenance sign by the HTTP redirection response message to described client, client is after the HTTP redirection response message that comprises above-mentioned session maintenance sign, to comprise above-mentioned session and keep sign in follow-up request message, after if load-balancing device receives the HTTP request message that comprises above-mentioned session maintenance sign, the corresponding relation that keeps sign and server according to the session of the local storage of load-balancing device, the HTTP request message is sent to above-mentioned session and keeps server corresponding to sign, to guarantee that having identical session keeps the HTTP request message of sign by same server service, thereby realize that session keeps, after server receives the HTTP request message, send the HTTP response message to load-balancing device, load-balancing device can directly be transmitted to client, and keep the corresponding relation of sign and server to obtain session without each the HTTP response message sent by resolution server, therefore, alleviated the burden of load-balancing device, improved disposal ability.
The schematic flow sheet that Fig. 1 is session keeping method embodiment mono-of the present invention, as shown in Figure 1, the method for the present embodiment comprises:
S101: load-balancing device receives the HTTP request message that client sends.
The above-mentioned HTTP request message is the HTTP request message that needs session to keep; load-balancing device can be by resolving URL(uniform resource locator) (the Uniform Resource Locator in the HTTP request message; hereinafter to be referred as: URL) field; know whether the HTTP request message is the HTTP request message that needs session to keep; for example, in url field, comprise " tab=mo& Authuser=0#my-drive " during character string, can determine that this HTTP request message is the HTTP request message that needs session to keep, and comprises above-mentioned " tab=mo& Authuser=0#my-drive " the HTTP request message of character string all should provide service by same server, just can guarantee normally carrying out of business.
S102: load-balancing device judges in the HTTP request message that whether comprising session keeps sign, if, carry out S104, if not, carry out S103.
Session keeps identifying the HTTP request message be used to indicate comprising identical session maintenance sign and sends to same server.Each session keeps the corresponding action scope of sign, and client can keep action scope corresponding to sign to determine the HTTP request message to be sent that needs session to keep according to session, comprises above-mentioned session and keep sign in HTTP request message to be sent.As a kind of feasible implementation wherein, it can be cookie information that session keeps sign.
S103: load-balancing device keeps sign for the client that sends the above-mentioned HTTP request message arranges session, and sends the HTTP redirection response message to described client, and current handling process finishes.
Wherein, comprise above-mentioned session in the HTTP redirection response message and keep sign, after client arrives the HTTP redirection response message, resend the HTTP request message to load-balancing device, different from last HTTP request message, comprise above-mentioned session in the HTTP request message resend and keep sign.And all comprise above-mentioned session and keep sign in the follow-up HTTP request message that belongs to session maintenance mark action territory, make load-balancing device keep sign to be defined as the server of client service according to above-mentioned session, to have identical session keeps the HTTP request message of sign to send to same server, provide service by same server, keep to guarantee session.
S104: load-balancing device keeps the corresponding relation of sign and server according to session, the HTTP request message is sent to server.
As a kind of feasible implementation wherein, session keeps the corresponding relation of sign and server, can be to be after client arranges session maintenance sign at load-balancing device, set up and preserve according to the first preset rules the corresponding relation that above-mentioned session keeps sign and server, then keep the corresponding relation of sign and server according to session, the HTTP request message is sent to described session and keeps server corresponding to sign.
The feasible implementation as another kind, can be also after receiving first the HTTP request message that comprises above-mentioned session maintenance sign, judge whether load-balancing device this locality stores the corresponding relation that above-mentioned session keeps sign and server, if storage, according to session, keep the corresponding relation of sign and server, the above-mentioned HTTP request message is sent to described session and keeps server corresponding to sign; If not storage, according to the second preset rules, set up and preserve the corresponding relation that above-mentioned session keeps sign and server, and keep the corresponding relation of sign and server according to described session, described HTTP request message is sent to above-mentioned session and keeps server corresponding to sign.
In above-mentioned two kinds of implementations, the first preset rules or second preset rules specific rules the present invention are not restricted this, below with several frequently seen preset rules, are illustrated:
The first preset rules: poll, according to set order, keeps sign to correspond to successively different server session.For example: 3 station server A, B, C are arranged, first reply keeps sign to correspond to server A, second session keeps sign to correspond to server B, the 3rd session keeps sign to correspond to server C, the 4th session keeps sign to correspond to server A, the corresponding relation according to this order assign sessions maintenance sign successively with server.It is 1:1:1 that the session that every station server is corresponding keeps the quantitative proportion of sign.
The second preset rules: WRR, similar with poll, but the session corresponding according to its weight allocation of every station server keeps sign.For example the weight of server A, B, C is respectively 4,3,1, and it is 4:3:1 that corresponding with every station server so session keeps the ratio of sign.
The third preset rules: priority, first server is divided into groups (every group comprises 1 or multiple servers), be each priority of server group definition and a threshold value (for determining the session that in group, server is corresponding, keeping the total upper limit of sign).While setting up corresponding relation, first keep sign to correspond to the server group that priority is the highest session, when session corresponding to the server group of limit priority keeps identification number to arrive threshold value, just subsequent session is kept identifying the server group that corresponds to time high priority, by that analogy.In addition, between the multiple servers in same server group, adopt the mode of above-mentioned poll or WRR.
Wherein, the first preset rules can be identical with the second preset rules, also can be not identical.
Due to the loading condition of the server in server cluster in real-time change, therefore, in above-mentioned two kinds of possible implementations, rear a kind of implementation is set up session and is kept sign more reasonable with the opportunity of the corresponding relation of server, and the loading condition of the server distributed is more suitable for processing the request of above-mentioned client.
Alternatively, in this step, load-balancing device keeps the corresponding relation of sign and server according to described session, described HTTP request message is sent to described server, can be specifically to keep sign to delete the session in the HTTP request message, then will delete the HTTP request message after session keeps sign, keep the corresponding relation of sign and server according to session, and send to above-mentioned session and keep server corresponding to sign.
The session that the corresponding relation of session maintenance sign and server can be stored in load-balancing device this locality keeps in the mapping table of sign and server, as shown in table 1:
Table 1 session keeps the mapping table of sign and server
Session keeps sign Server
Session keeps identification strings 1 Server 1
Session keeps identification strings 2 Server 3
After server receives the HTTP request message of load-balancing device transmission, according to the HTTP request message, to load-balancing device, send the HTTP response message.
S105: the HTTP response message that load-balancing device sends server is transmitted to client.
In the present embodiment, because load-balancing device is that client arranges session maintenance sign, and keep the HTTP redirection response message of sign to keep sign to send to client above-mentioned session by comprising session, so that carrying above-mentioned session in follow-up HTTP request message, client keeps message, load-balancing device keeps the corresponding relation of sign and server according to the session of this locality storage, the HTTP request message is sent to the server that above-mentioned session keeps the corresponding relation of sign and server, to guarantee that having identical session keeps the HTTP request message of sign by same server service, thereby realize that session keeps, after server receives the HTTP request message, send the HTTP response message to load-balancing device, load-balancing device can directly be transmitted to client, and keep the corresponding relation of sign and server to obtain session without each the HTTP response message sent by resolution server, therefore, alleviated the burden of load-balancing device, improved disposal ability.
The schematic flow sheet that Fig. 2 is session keeping method embodiment bis-of the present invention, as shown in Figure 2, the method for the present embodiment comprises:
S201: the HTTP redirection response message that the client load-balancing device sends, above-mentioned HTTP is redirected in response message and comprises session maintenance sign.
S202: client sends the HTTP request message to above-mentioned load-balancing device, comprises above-mentioned session in the above-mentioned HTTP request message and keeps sign.
Load-balancing device keeps sign to be defined as the server of above-mentioned client service according to above-mentioned session.
What the method for the present embodiment was different from method embodiment illustrated in fig. 1 is, the method of implementing shown in Fig. 1 be take load-balancing device as the executive agent description, the present embodiment be take client and is described as executive agent, but technical scheme is identical, can, with reference to the technical scheme of embodiment of the method shown in Fig. 1, repeat no more herein.
The schematic flow sheet that Fig. 3 is session keeping method embodiment bis-of the present invention, as shown in Figure 3, the method for the present embodiment comprises:
S301: the HTTP request message that server balancing received load equipment sends.
S302: server sends the HTTP response message according to the above-mentioned HTTP request message to load-balancing device.
What the method for the present embodiment was different from method embodiment illustrated in fig. 1 is, the method of implementing shown in Fig. 1 be take load-balancing device as the executive agent description, the present embodiment be take server and is described as executive agent, but technical scheme is identical, can, with reference to the technical scheme of embodiment of the method shown in Fig. 1, repeat no more herein.
The structural representation that Fig. 4 is session holding device embodiment mono-of the present invention, the device of the present embodiment can be deployed in load-balancing device, as shown in Figure 4, the device of the present embodiment, comprise receiver module 401, processing module 402 and sending module 403, wherein, the HTML (Hypertext Markup Language) HTTP request message that receiver module 401 sends for receiving client, the above-mentioned HTTP request message is the HTTP request message that needs session to keep; Processing module 402 is for judging whether the above-mentioned HTTP request message comprises session and keep sign, and above-mentioned session keeps identifying the HTTP request message be used to indicate comprising identical session maintenance sign and sends to same server; If do not comprise, for arranging session, the client that sends the above-mentioned HTTP request message keeps sign, and send the HTTP redirection response message to above-mentioned client, above-mentioned HTTP is redirected in response message and comprises above-mentioned session maintenance sign, so that above-mentioned client keeps sign to send the HTTP request message that comprises above-mentioned session maintenance sign to load-balancing device according to above-mentioned session; If comprise, according to above-mentioned session, keep the corresponding relation of sign and server, the above-mentioned HTTP request message is sent to above-mentioned session and keeps server corresponding to sign; Sending module 403 is transmitted to above-mentioned client for the HTTP response message that above-mentioned server is sent.
In the above-described embodiments, above-mentioned processing module 402 also is used to the client that sends the above-mentioned HTTP request message to arrange after session keeps sign, according to the first preset rules, sets up and preserve the corresponding relation that above-mentioned session keeps sign and server.
In the above-described embodiments, above-mentioned processing module 402 keeps the corresponding relation of sign and server according to above-mentioned session, when the above-mentioned HTTP request message is sent to the server corresponding with above-mentioned session maintenance sign, specifically for judging load-balancing device this locality, whether store the corresponding relation that above-mentioned session keeps sign and server; If the corresponding relation with server according to above-mentioned session maintenance sign, send to the above-mentioned HTTP request message with above-mentioned session and keep server corresponding to sign; If not, according to the second preset rules, set up and preserve the corresponding relation that above-mentioned session keeps sign and server, and keep the corresponding relation of sign and server according to above-mentioned session, the above-mentioned HTTP request message is sent to above-mentioned session and keeps server corresponding to sign.
In the above-described embodiments, above-mentioned processing module 402 keeps the corresponding relation of sign and server according to above-mentioned session, when the above-mentioned HTTP request message is sent to the server corresponding with above-mentioned session maintenance sign, specifically for the above-mentioned session of deleting in the above-mentioned HTTP request message, keep sign; By the HTTP request message of deleting after above-mentioned session keeps sign, the corresponding relation according to above-mentioned session maintenance sign with server, send to above-mentioned session and keep server corresponding to sign.
In the above-described embodiments, above-mentioned session keeps being designated cookie information.
But the technical scheme of embodiment of the method shown in the execution graph 1 of the device correspondence of the present embodiment, its realize principle and technique effect similar, repeat no more herein.
The structural representation that Fig. 5 is session holding device embodiment bis-of the present invention, the device of the present embodiment is deployed in terminal, as shown in Figure 5, the apparatus module receiver module 501 of the present embodiment and sending module 502, wherein, the HTTP redirection response message that receiver module 501 sends for balancing received load equipment, above-mentioned HTTP is redirected in response message and comprises session maintenance sign; Sending module 502, for to above-mentioned load-balancing device, sending the HTTP request message, comprises above-mentioned session and keeps sign in the above-mentioned HTTP request message, so that above-mentioned load-balancing device keeps sign to be defined as the server of above-mentioned client service according to above-mentioned session.
But the technical scheme of embodiment of the method shown in the execution graph 2 of the device correspondence of the present embodiment, its realize principle and technique effect similar, repeat no more herein.
The structural representation that Fig. 6 is session holding device embodiment tri-of the present invention, the device of the present embodiment is deployed in server, as shown in Figure 6, the device of the present embodiment comprises receiver module 601 and sending module 602, wherein, the HTTP request message that receiver module 601 sends for balancing received load equipment; Sending module 602 is for sending the HTTP response message according to the above-mentioned HTTP request message to load-balancing device.
But the technical scheme of embodiment of the method shown in the execution graph 3 of the device correspondence of the present embodiment, its realize principle and technique effect similar, repeat no more herein.
One of ordinary skill in the art will appreciate that: realize that the hardware that all or part of step of above-mentioned each embodiment of the method can be relevant by program command completes.Aforesaid program can be stored in a computer read/write memory medium.This program, when carrying out, is carried out the step that comprises above-mentioned each embodiment of the method; And aforesaid storage medium comprises: various media that can be program code stored such as ROM, RAM, magnetic disc or CDs.
Finally it should be noted that: above each embodiment, only in order to technical scheme of the present invention to be described, is not intended to limit; Although with reference to aforementioned each embodiment, the present invention is had been described in detail, those of ordinary skill in the art is to be understood that: its technical scheme that still can put down in writing aforementioned each embodiment is modified, or some or all of technical characterictic wherein is equal to replacement; And these modifications or replacement do not make the essence of appropriate technical solution break away from the scope of various embodiments of the present invention technical scheme.

Claims (11)

1. a session keeping method, is characterized in that, comprising:
Receive the HTML (Hypertext Markup Language) HTTP request message that client sends, described HTTP request message is the HTTP request message that needs session to keep;
Judge in described HTTP request message that whether comprising session keeps sign, described session keeps identifying the HTTP request message be used to indicate comprising identical session maintenance sign and sends to same server;
If do not comprise, for arranging session, the client that sends described HTTP request message keeps sign, and send the HTTP redirection response message to described client, comprise described session in described HTTP redirection response message and keep sign, so that described client keeps sign to send and comprise the HTTP request message that described session keeps sign to load-balancing device according to described session;
If comprise, according to described session, keep the corresponding relation of sign and server, described HTTP request message is sent to described session and keeps server corresponding to sign;
The HTTP response message that described server is sent is transmitted to described client.
2. method according to claim 1, is characterized in that, the described client for the described HTTP request message of transmission also comprises after session maintenance sign is set:
Set up and preserve according to the first preset rules the corresponding relation that described session keeps sign and server.
3. method according to claim 1, is characterized in that, the described corresponding relation that keeps sign and server according to described session sends to described HTTP request message with described session and keeps server corresponding to sign, comprising:
Judge whether load-balancing device this locality stores the corresponding relation that described session keeps sign and server;
If the corresponding relation with server according to described session maintenance sign, send to described HTTP request message with described session and keep server corresponding to sign;
If not, according to the second preset rules, set up and preserve the corresponding relation that described session keeps sign and server, and keep the corresponding relation of sign and server according to described session, described HTTP request message is sent to described session and keeps server corresponding to sign.
4. according to the described method of claim 1~3 any one, it is characterized in that the described corresponding relation that keeps sign and server according to described session sends to described HTTP request message with described session and keeps server corresponding to sign to comprise:
The described session of deleting in described HTTP request message keeps sign;
By the HTTP request message of deleting after described session keeps sign, the corresponding relation according to described session maintenance sign with server, send to described session and keep server corresponding to sign.
5. method according to claim 4, is characterized in that, described session keeps being designated cookie information.
6. a session keeping method, is characterized in that, comprising:
The HTTP redirection response message that balancing received load equipment sends, comprise session and keep sign in described HTTP redirection response message;
Send the HTTP request message to described load-balancing device, comprise described session in described HTTP request message and keep sign, so that described load-balancing device keeps sign to be defined as the server of described client service according to described session.
7. a session holding device, is characterized in that, comprising:
Receiver module, the HTML (Hypertext Markup Language) HTTP request message sent for receiving client, described HTTP request message is the HTTP request message that needs session to keep;
Processing module, for judging whether described HTTP request message comprises session and keep sign, described session keeps identifying the HTTP request message be used to indicate comprising identical session maintenance sign and sends to same server; If do not comprise, for arranging session, the client that sends described HTTP request message keeps sign, and send the HTTP redirection response message to described client, comprise described session in described HTTP redirection response message and keep sign, so that described client keeps sign to send and comprise the HTTP request message that described session keeps sign to load-balancing device according to described session; If comprise, according to described session, keep the corresponding relation of sign and server, described HTTP request message is sent to described session and keeps server corresponding to sign;
Sending module, be transmitted to described client for the HTTP response message that described server is sent.
8. device according to claim 7, it is characterized in that, described processing module also is used to the client that sends described HTTP request message to arrange after session keeps sign, according to the first preset rules, sets up and preserve the corresponding relation that described session keeps sign and server.
9. device according to claim 7, it is characterized in that, described processing module keeps the corresponding relation of sign and server according to described session, when described HTTP request message is sent to the server corresponding with described session maintenance sign, specifically for judging load-balancing device this locality, whether store the corresponding relation that described session keeps sign and server; If the corresponding relation with server according to described session maintenance sign, send to described HTTP request message with described session and keep server corresponding to sign; If not, according to the second preset rules, set up and preserve the corresponding relation that described session keeps sign and server, and keep the corresponding relation of sign and server according to described session, described HTTP request message is sent to described session and keeps server corresponding to sign.
10. according to the described device of claim 7~9 any one, it is characterized in that, described processing module keeps the corresponding relation of sign and server according to described session, when described HTTP request message is sent to the server corresponding with described session maintenance sign, specifically for the described session of deleting in described HTTP request message, keep sign; By the HTTP request message of deleting after described session keeps sign, the corresponding relation according to described session maintenance sign with server, send to described session and keep server corresponding to sign.
11. a session holding device, is characterized in that, comprising:
Receiver module, the HTTP redirection response message sent for balancing received load equipment, comprise session and keep sign in described HTTP redirection response message;
Sending module, for to described load-balancing device, sending the HTTP request message, comprise described session and keep sign in described HTTP request message, so that described load-balancing device keeps sign to be defined as the server of described client service according to described session.
CN2013103818008A 2013-08-28 2013-08-28 Conversation maintaining method and device Pending CN103457869A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN2013103818008A CN103457869A (en) 2013-08-28 2013-08-28 Conversation maintaining method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN2013103818008A CN103457869A (en) 2013-08-28 2013-08-28 Conversation maintaining method and device

Publications (1)

Publication Number Publication Date
CN103457869A true CN103457869A (en) 2013-12-18

Family

ID=49739839

Family Applications (1)

Application Number Title Priority Date Filing Date
CN2013103818008A Pending CN103457869A (en) 2013-08-28 2013-08-28 Conversation maintaining method and device

Country Status (1)

Country Link
CN (1) CN103457869A (en)

Cited By (27)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103957207A (en) * 2014-04-29 2014-07-30 北京太一星晨信息技术有限公司 Conversation keeping method and device
CN104811488A (en) * 2015-04-13 2015-07-29 深信服网络科技(深圳)有限公司 Load balancing equipment-based session keeping method and system and load balancing equipment
CN104994029A (en) * 2015-06-23 2015-10-21 浪潮电子信息产业股份有限公司 Link load balance outbound session persistence method based on intelligent learning algorithm
CN105591959A (en) * 2014-10-24 2016-05-18 华耀(中国)科技有限公司 System and method for load balancing by SSL session resuming
CN105939313A (en) * 2015-09-01 2016-09-14 杭州迪普科技有限公司 State code redirecting method and device
CN106790150A (en) * 2016-12-28 2017-05-31 北京信安世纪科技有限公司 A kind of session keeping method and device
CN107360251A (en) * 2017-08-16 2017-11-17 中国工商银行股份有限公司 Method, system and the load balancing apparatus that session is kept
CN108076149A (en) * 2017-12-15 2018-05-25 杭州迪普科技股份有限公司 Session keeping method and device
CN108432212A (en) * 2016-02-16 2018-08-21 华为技术有限公司 Communication means, device and system based on Flow Control Transmission Protocol SCTP
CN108664343A (en) * 2018-05-09 2018-10-16 顺丰科技有限公司 A kind of stateful call method and device of micro services
CN108696554A (en) * 2017-04-10 2018-10-23 北京京东尚科信息技术有限公司 Load-balancing method and device
CN108696557A (en) * 2017-04-11 2018-10-23 北京京东尚科信息技术有限公司 Information processing system, method and apparatus
CN108768878A (en) * 2018-06-06 2018-11-06 北京奇艺世纪科技有限公司 A kind of SiteServer LBS, method, apparatus and load-balancing device
CN109101337A (en) * 2018-07-23 2018-12-28 赛尔网络有限公司 A kind of server node upgrade method and electronic equipment based on HAProxy
CN109150745A (en) * 2018-10-26 2019-01-04 新华三信息安全技术有限公司 A kind of message processing method and device
CN109361749A (en) * 2018-10-24 2019-02-19 华为技术有限公司 Message processing method, relevant device and computer storage medium
CN109451068A (en) * 2018-12-28 2019-03-08 杭州迪普科技股份有限公司 The insertion method and device of Set-Cookie value
CN109474705A (en) * 2018-12-28 2019-03-15 杭州迪普科技股份有限公司 A kind of session keeping method and device
CN109495526A (en) * 2017-09-12 2019-03-19 北京金山云网络技术有限公司 A kind of file transmitting method, device, system, electronic equipment and storage medium
CN110913011A (en) * 2019-12-05 2020-03-24 东软集团股份有限公司 Session keeping method, session keeping device, readable storage medium and electronic equipment
CN111586177A (en) * 2017-06-28 2020-08-25 杭州云英网络科技有限公司 Cluster session loss prevention method and system
CN111988362A (en) * 2020-07-22 2020-11-24 北京达佳互联信息技术有限公司 Data transmission method, device, terminal and storage medium
CN112565441A (en) * 2020-12-11 2021-03-26 北京天融信网络安全技术有限公司 Data communication method and electronic equipment
CN113190607A (en) * 2021-05-21 2021-07-30 上海申铁信息工程有限公司 HTTP request-based database load balancing method, device and medium
CN113452778A (en) * 2021-06-25 2021-09-28 中国农业银行股份有限公司 Session keeping method, device, equipment, system and storage medium
CN114338689A (en) * 2021-12-30 2022-04-12 中国工商银行股份有限公司 Session holding method, apparatus, device, medium, and program product
CN114827239A (en) * 2022-05-31 2022-07-29 杭州迪普科技股份有限公司 Bidirectional session holding method and device based on 8583 protocol

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101340371A (en) * 2008-08-12 2009-01-07 杭州华三通信技术有限公司 Session keeping method and load balance apparatus
CN101783771A (en) * 2010-03-24 2010-07-21 杭州华三通信技术有限公司 Method and equipment for realizing load balance continuity
CN101808118A (en) * 2010-03-02 2010-08-18 浪潮(北京)电子信息产业有限公司 Access method, device and system of server
CN102075445A (en) * 2011-02-28 2011-05-25 杭州华三通信技术有限公司 Load balancing method and device

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101340371A (en) * 2008-08-12 2009-01-07 杭州华三通信技术有限公司 Session keeping method and load balance apparatus
CN101808118A (en) * 2010-03-02 2010-08-18 浪潮(北京)电子信息产业有限公司 Access method, device and system of server
CN101783771A (en) * 2010-03-24 2010-07-21 杭州华三通信技术有限公司 Method and equipment for realizing load balance continuity
CN102075445A (en) * 2011-02-28 2011-05-25 杭州华三通信技术有限公司 Load balancing method and device

Cited By (45)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103957207B (en) * 2014-04-29 2017-11-28 北京太一星晨信息技术有限公司 A kind of session keeping method and device
CN103957207A (en) * 2014-04-29 2014-07-30 北京太一星晨信息技术有限公司 Conversation keeping method and device
CN105591959A (en) * 2014-10-24 2016-05-18 华耀(中国)科技有限公司 System and method for load balancing by SSL session resuming
CN104811488A (en) * 2015-04-13 2015-07-29 深信服网络科技(深圳)有限公司 Load balancing equipment-based session keeping method and system and load balancing equipment
CN104994029A (en) * 2015-06-23 2015-10-21 浪潮电子信息产业股份有限公司 Link load balance outbound session persistence method based on intelligent learning algorithm
CN104994029B (en) * 2015-06-23 2018-09-04 浪潮电子信息产业股份有限公司 A kind of outbound session keeping method of balancing link load based on intelligence learning algorithm
CN105939313A (en) * 2015-09-01 2016-09-14 杭州迪普科技有限公司 State code redirecting method and device
CN105939313B (en) * 2015-09-01 2019-03-15 杭州迪普科技股份有限公司 Status code reorientation method and device
CN108432212A (en) * 2016-02-16 2018-08-21 华为技术有限公司 Communication means, device and system based on Flow Control Transmission Protocol SCTP
US10764411B2 (en) 2016-02-16 2020-09-01 Huawei Technologies Co., Ltd. Stream control transmission protocol SCTP-based communications method and system, and apparatus
CN106790150A (en) * 2016-12-28 2017-05-31 北京信安世纪科技有限公司 A kind of session keeping method and device
CN106790150B (en) * 2016-12-28 2020-07-31 北京信安世纪科技股份有限公司 Session maintaining method and device
CN108696554A (en) * 2017-04-10 2018-10-23 北京京东尚科信息技术有限公司 Load-balancing method and device
CN108696557A (en) * 2017-04-11 2018-10-23 北京京东尚科信息技术有限公司 Information processing system, method and apparatus
CN108696557B (en) * 2017-04-11 2021-08-10 北京京东尚科信息技术有限公司 Information processing system, method and device
CN111586177B (en) * 2017-06-28 2022-11-08 杭州云毅网络科技有限公司 Cluster session loss prevention method and system
CN111586177A (en) * 2017-06-28 2020-08-25 杭州云英网络科技有限公司 Cluster session loss prevention method and system
CN107360251A (en) * 2017-08-16 2017-11-17 中国工商银行股份有限公司 Method, system and the load balancing apparatus that session is kept
CN109495526A (en) * 2017-09-12 2019-03-19 北京金山云网络技术有限公司 A kind of file transmitting method, device, system, electronic equipment and storage medium
CN108076149A (en) * 2017-12-15 2018-05-25 杭州迪普科技股份有限公司 Session keeping method and device
CN108076149B (en) * 2017-12-15 2021-07-23 杭州迪普科技股份有限公司 Session maintaining method and device
CN108664343B (en) * 2018-05-09 2022-08-23 顺丰科技有限公司 State calling method and device for micro-service
CN108664343A (en) * 2018-05-09 2018-10-16 顺丰科技有限公司 A kind of stateful call method and device of micro services
CN108768878A (en) * 2018-06-06 2018-11-06 北京奇艺世纪科技有限公司 A kind of SiteServer LBS, method, apparatus and load-balancing device
CN109101337A (en) * 2018-07-23 2018-12-28 赛尔网络有限公司 A kind of server node upgrade method and electronic equipment based on HAProxy
CN109361749A (en) * 2018-10-24 2019-02-19 华为技术有限公司 Message processing method, relevant device and computer storage medium
US11316916B2 (en) 2018-10-24 2022-04-26 Huawei Technologies Co., Ltd. Packet processing method, related device, and computer storage medium
CN109361749B (en) * 2018-10-24 2022-03-29 华为云计算技术有限公司 Message processing method, related equipment and computer storage medium
CN109150745A (en) * 2018-10-26 2019-01-04 新华三信息安全技术有限公司 A kind of message processing method and device
CN109150745B (en) * 2018-10-26 2022-06-21 新华三信息安全技术有限公司 Message processing method and device
CN109451068B (en) * 2018-12-28 2021-11-23 杭州迪普科技股份有限公司 Method and device for inserting Set-Cookie value
CN109474705A (en) * 2018-12-28 2019-03-15 杭州迪普科技股份有限公司 A kind of session keeping method and device
CN109451068A (en) * 2018-12-28 2019-03-08 杭州迪普科技股份有限公司 The insertion method and device of Set-Cookie value
CN109474705B (en) * 2018-12-28 2021-04-27 杭州迪普科技股份有限公司 Session maintaining method and device
CN110913011A (en) * 2019-12-05 2020-03-24 东软集团股份有限公司 Session keeping method, session keeping device, readable storage medium and electronic equipment
CN111988362A (en) * 2020-07-22 2020-11-24 北京达佳互联信息技术有限公司 Data transmission method, device, terminal and storage medium
CN111988362B (en) * 2020-07-22 2022-11-22 北京达佳互联信息技术有限公司 Data transmission method, device, terminal and storage medium
CN112565441A (en) * 2020-12-11 2021-03-26 北京天融信网络安全技术有限公司 Data communication method and electronic equipment
CN112565441B (en) * 2020-12-11 2023-07-14 北京天融信网络安全技术有限公司 Data communication method and electronic equipment
CN113190607A (en) * 2021-05-21 2021-07-30 上海申铁信息工程有限公司 HTTP request-based database load balancing method, device and medium
CN113190607B (en) * 2021-05-21 2024-04-16 上海申铁信息工程有限公司 HTTP request-based database load balancing method, device and medium
CN113452778A (en) * 2021-06-25 2021-09-28 中国农业银行股份有限公司 Session keeping method, device, equipment, system and storage medium
CN113452778B (en) * 2021-06-25 2023-10-13 中国农业银行股份有限公司 Session holding method, device, equipment, system and storage medium
CN114338689A (en) * 2021-12-30 2022-04-12 中国工商银行股份有限公司 Session holding method, apparatus, device, medium, and program product
CN114827239A (en) * 2022-05-31 2022-07-29 杭州迪普科技股份有限公司 Bidirectional session holding method and device based on 8583 protocol

Similar Documents

Publication Publication Date Title
CN103457869A (en) Conversation maintaining method and device
US10268841B1 (en) Data anonymity and separation for user computation
US11563674B2 (en) Content based routing method and apparatus
CN101841520B (en) Domain name system and information processing method and device for domain name system
CN104980289B (en) Information push method, device and system
CN103971687B (en) Implementation of load balancing in a kind of speech recognition system and device
CN104427005A (en) Method and system for realizing accurate request scheduling on content delivery network
US20150370899A1 (en) Shortened url management method and management device, and storage medium storing computer program for management thereof
CN102402558A (en) Method and system for providing message containing website
JP2015508543A (en) Processing store visit data
CN103455439A (en) Local caching device, system and method for providing content caching service
CN105337837A (en) Message transmitting method and device
CN108769242A (en) A kind of method for dispatching message and device
CN102693297A (en) Data processing method, node and ETL (extract transform and load) system
CN108156118A (en) User Identity method and device
CN102170631B (en) Service information acquisition method, equipment and system
CN102447714A (en) Cookie management method
US20170237825A1 (en) Resource Download Method, Electronic Device, and Apparatus
CN103024003A (en) Webpage registering method and device
CN104092751B (en) A kind of Operational Visit method and apparatus
CN103020241A (en) Dynamic page cache method and system based on session
CN105207993A (en) Data access and scheduling method in CDN, and system
CN104253835A (en) User behavior data acquisition method and system
CN102075386B (en) Identification method and device
CN107169752B (en) Resource transfer method and device

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20131218