CN103516744A - A data processing method, an application server and an application server cluster - Google Patents

A data processing method, an application server and an application server cluster Download PDF

Info

Publication number
CN103516744A
CN103516744A CN201210210710.8A CN201210210710A CN103516744A CN 103516744 A CN103516744 A CN 103516744A CN 201210210710 A CN201210210710 A CN 201210210710A CN 103516744 A CN103516744 A CN 103516744A
Authority
CN
China
Prior art keywords
application server
data processing
processing request
request message
response
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
CN201210210710.8A
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.)
Alibaba Group Holding Ltd
Original Assignee
Alibaba Group Holding 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 Alibaba Group Holding Ltd filed Critical Alibaba Group Holding Ltd
Priority to CN201210210710.8A priority Critical patent/CN103516744A/en
Publication of CN103516744A publication Critical patent/CN103516744A/en
Pending legal-status Critical Current

Links

Images

Abstract

The application discloses a data processing method, an application server and an application server cluster. The method mainly comprises the steps of selecting, based on locally stored ability messages of other application servers in the same cluster, an application server that is capable of responding to data processing request messages to make the server serve as a central application server when a source application server receives the data processing request messages and is determined not to be able to respond to data processing request messages; and then forwarding the data processing request messages to the selected central application server. Therefore, if a source application server selected by a control server on the basis of a load balancing algorithm or a load balancing configuration strategy cannot meet load demands, other application servers with processing abilities in the same cluster can be selected by the source application server to replace the source application server to respond to data processing request messages, thus solving problems of the prior art that a source application server is forced to respond to data processing request messages to cause load imbalance.

Description

A kind of methods and applications server and cluster of data processing
Technical field
The application relates to internet information treatment technology, relates in particular to a kind of methods and applications server and cluster of data processing.
Background technology
Along with the continuous increase of data message amount in the fast development of Internet technology and the Internet, people improve constantly the degree of dependence of the Internet, cause the data access flow of the Internet to increase rapidly.Current most of website (especially ecommerce Lei website) need to provide 24 hours persistent services, critical data that the interruption of any background server or communication failure cause is lost and all can be caused the background server using in very large loss ,Zhe Dui the Internet to propose high-performance, highly reliable requirement.
With respect to the development of network technology, the growth of the speed of each background server deal with data and internal storage access speed is but well below the growth rate of the network bandwidth and application program.The growth that the network bandwidth has brought number of users when increasing, this makes background server hardware resource consumption even more serious, use unit background server is that the mode of a website service can not meet real demand far away, and the performance restriction of current background server has become the bottleneck of Internet technology development.
Under existing Internet architecture, in order to overcome the problems referred to above, propose to set up background server cluster, utilize load-balancing technique when business is carried out, realize background server cluster in the load balancing of each server.
Specific implementation is:
The first step: many application servers are connected to form to an application server cluster by the network equipment, make every application server all provide same or analogous back-end data to process service.
Second step: dispose Control Server at application server cluster front end, its effect is each application server load balancing in the application server cluster of realizing under Control Server control; Specific works mode is: when receiving the data processing request of user Dui Gai website, utilize self load-balancing algorithm to determine the operating state of its each application server under controlling, and the data processing request receiving is assigned to wherein in an application server, indicate this application server return data result message; Or according to the load balancing having configured, the data processing request receiving is distributed in application server cluster, and indication receives the application server return data result message of data processing request.
As can be seen here, each Control Server is independently with respect to application server cluster, when a large amount of data processing request receiving is transmitted to application server, forwarding data process request according to being the load-balancing algorithm of self storage or the load balancing having configured.Wherein, described load-balancing algorithm comprises: sequentially algorithm, proportion algorithm, flow proportional algorithm etc., these algorithms are applicable to the application server of different characteristics.Cause the reason of each application server load imbalance conventionally to have two kinds:
The first situation: the hardware configuration situation that Control Server is carrying out data processing request and divides timing not consider each controlled application server.Although because some application server load is very large, the hardware configuration of this application server is relatively better, the speed of deal with data is also relatively very fast; Equally, although some application server load is very little, the hardware configuration of this application server is relatively low, and the speed of deal with data is also relatively slow.If the load-balancing algorithm that Control Server is only stored according to self or the load balancing having configured, be transmitted to definite application server by the data processing request receiving, there will be each application server to occur the situation of load imbalance.
For example: the current load condition of application server A is 50%, and the current load condition of application server B is 75%, but the hardware configuration of application server B is far away higher than application server A; Suppose that Control Server receives a data processing request, the load-balancing algorithm of storing according to body or the load balancing having configured are definite distributes to application server A by this data processing request, if but this data processing request is distributed to after application server A, the load of application server A will be strengthened, the processing speed of application server A is declined, and cause each application server load imbalance.
Second case: Control Server can not well be assessed its needed disposal ability to the data processing request receiving, divides timing also cannot consider whether application server meets its disposal ability.Because different data processing request shared system resource when processed is different, therefore, the disposal ability of the application server of processing is required also different.When Control Server is forwarded to an application server according to the load-balancing algorithm of self storage or the load balancing that configured by data processing request, owing to not considering the disposal ability of the needed application server of this data processing request, may cause the application server that receives data processing request to need at short notice the data volume of processing too much, traffic pressure is excessive, affects the efficiency of these application server processes data.
For example: in the back-end data treatment system of Yi Ge website, Control Server receives a plurality of synchronous processing requests and a plurality of asynchronous process request simultaneously, Control Server determines that according to the load-balancing algorithm of self storage asynchronous process request processed by application server A, but, the pending asynchronous process request of current application server A is more, and the required system resource of the asynchronous process request that Control Server sends is relatively large, therefore, when application server A receives after this asynchronous process request, a large amount of system resource will be taken, cause application server A deal with data pressure to increase, affect the speed of data processing, and then make to occur between each application server the phenomenon of load imbalance.
As can be seen here, there is the problem of load imbalance in Control Server according to the data handling utility server of load-balancing algorithm or the selection of load balancing collocation strategy.
Summary of the invention
The embodiment of the present application provides a kind of methods and applications server and cluster of data processing, when solving the data handling utility server that prior art selected according to load-balancing algorithm or load balancing collocation strategy by Control Server, still may there is the problem of application server load imbalance.
A method for data processing, the method comprises:
Source application server, when receiving data processing request message, judges the ability self whether with this data processing request message of response;
When source application server is determined the ability self without this data processing request message of response, according to the ability information of other application servers in the same cluster of this locality storage, selection has the application server of this data processing request message capability of response as middle application server, and described data processing message is transmitted to the middle application server of selection.
, this application server comprises:
Judge module, for when receiving data processing request message, judges the ability self whether with this data processing request message of response;
Forwarding module, while not thering is for determining the ability that responds this data processing request message, according to the ability information of other application servers in the same cluster of this locality storage, selection has the application server of this data processing request message capability of response as middle application server, and described data processing message is transmitted to the middle application server of selection.
, comprise a plurality of above-mentioned application servers.
The application's beneficial effect is as follows:
The embodiment of the present application by source application server when receiving data processing request message, judge the ability self whether with this data processing request message of response, when determining the ability self without this data processing request message of response, according to the capabilities message of other application servers in the same cluster of this locality storage, selection has the application server of this data processing request message capability of response as middle application server, and described data processing request message is transmitted to the middle application server of selection, like this when Control Server can not meet loading demand according to the source application server of load-balancing algorithm or the selection of load balancing collocation strategy, Ke You source application server is selected other application servers with disposal ability in same cluster and is carried out the response of alternate source application server to data processing request message, this has solved forces in prior art to come response data to process the problem of the load imbalance that request message causes by source application server, improved treatment effeciency.
Accompanying drawing explanation
Fig. 1 is the schematic flow sheet of method of a kind of data processing of the embodiment of the present application one;
Fig. 2 is the schematic flow sheet of method of a kind of data processing of the embodiment of the present application two;
Fig. 3 is the schematic flow sheet of method of a kind of data processing of the embodiment of the present application three;
Fig. 4 is the structural representation of a kind of application server of the embodiment of the present application four.
Embodiment
In order to realize the application's object, the embodiment of the present application provides a kind of method and server and cluster of data processing, by source application server when receiving data processing request message, judge the ability self whether with this data processing request message of response, when determining the ability self without this data processing request message of response, according to the capabilities message of other application servers in the same cluster of this locality storage, selection has the application server of this data processing request message capability of response as middle application server, and described data processing request message is transmitted to the middle application server of selection.
Compared with prior art, source application server is not simply according to receiving data processing request message, directly to process, and returns to response results message, but judge self whether to there is the ability of processing this data processing request message, when not possessing this data processing request message of processing, this data processing request message is transmitted to definite application server with this data processing request ability, while having avoided like this Control Server can not meet loading demand according to the source application server of load-balancing algorithm or the selection of load balancing collocation strategy, Ke You source application server is selected other application servers with disposal ability in same cluster and is carried out the response of alternate source application server to data processing request message, this has solved forces in prior art to come response data to process the problem of the load imbalance that request message causes by source application server, improved treatment effeciency.
Below in conjunction with Figure of description, each embodiment of the application is described in detail.
Embodiment mono-:
As shown in Figure 1, it is the schematic flow sheet of method of a kind of data processing of the embodiment of the present application one, and described method comprises:
Step 101: source application server, when receiving data processing request message, judges the ability self whether with this data processing request message of response, if so, returns to response success message; Otherwise, perform step 102.
In this step 101, described source application server refers to the application server of the data processing request message that receives Control Server transmission.
The described response success message of returning can refer to that source application server is back to Control Server using the result of data processing request message as response success message, is returned to the terminal that sends data processing request message by Control Server.
It should be noted that, the application server in each embodiment of the application has the ability of the data processing request that receives of judgement required system resource size when processed, and has to determine currently self whether can respond the ability of this data processing request message.
The ability that described response data is processed request message refers to according to current application server hardware occupation condition, determines whether to also have sufficient system resource for the treatment of the data processing request receiving.
Step 102: when source application server is determined the ability self without this data processing request message of response, according to the ability information of other application servers in the same cluster of this locality storage, selection has the application server of this data processing request message capability of response as middle application server, and described data processing request message is transmitted to the middle application server of selection.
Wherein, when each application server is set up to cluster, basic hardware and software configuration information for each application server in this application server cluster of each application server configuration, comprising: IP address, the listening port of internal load service etc., and this configuration information is stored in to this locality of each application server, and the application server in cluster upgrades while changing, such as increasing application server or the application server etc. that rolls off the production line.
Particularly, the mode that in cluster, arbitrary application server obtains the ability information of other application servers in same cluster is:
Application server is periodically to the state information of other application servers broadcast in cluster self, and periodically receive the state information of other application servers broadcast in cluster, cluster identity, server identification and the ability information of in described state information, having carried the application server place cluster of broadcasting status messages.
Described ability information comprises: the load condition of current application server, each hardware state parameter and software program running state information etc.
It should be noted that, in the same cluster of described local storage, the ability information of other application servers is close to the state information that receives each application server receiving in the cycle of data processing request message.
Wherein, load condition can represent by the form of percentage, also can represent by concrete load value; Each hardware state parameter can be occupancy, internal memory use amount of cpu resource etc.; Software program state information can be the quantity of current use software program, and the stock number that software program operation takies etc., specifically respectively join numerical representation information and be not specifically limited here.
More preferably, described load condition can obtain by the mode of computational load value, is specially:
The first step: for distributing different weighted values according to the function of application server for its hardware resource and software station resource;
Second step: when broadcast cycle is about to arrive, determine the operation parameter of this application server hardware resource and the operation parameter of software resource;
The 3rd step: utilize described definite weighted value, carry out weighted sum operation, obtain the load value of this this broadcast cycle of application server.
More preferably, the application server in same cluster is divided into a plurality of groups, in each group, comprises a plurality of application servers; And set up Socket between the application server in each group and connect, and determine the running status of application server in group by sending keep-alive instruction (keep-alive), and the regular synchronous state information of each application server in group.
It should be noted that in ,Ge group, setting up the application server that Socket connects becomes standby host mutually, it is the highest that the application server that has a standby host relation can be set its priority when selecting intermediate server.
Particularly, source application server judges in the group of place whether exist and have the application server that responds this data processing request message capability, if, in the group of Ze Cong place, select application server as middle application server, otherwise select application server as middle application server in other groups.
Step 103: described middle application server judges the ability self whether with this data processing request message of response, if so, performs step 104; If not, perform step 105.
In step 103, described middle application server judges that the mode of the ability self whether with this data processing request message of response is identical with the mode of source application server judgement.
Step 104: described middle application server responds this data processing request message ,Bing Xiang source application server as object application server and returns to response success message.
In step 104, described intermediate server is by judging the ability self with this data processing request message of response of determining, this intermediate server responds this data processing request message, and result is returned to source server as response success message, and then by source application server, the response success message receiving is back to Control Server.
It should be noted that, because data processing request message is received by source application server, but the processing of data processing request message is not by source application server processes, but according to ability information, determine other application servers that can respond this data processing request message in the same cluster of being selected by source application server, therefore the middle application server of, processing this data processing request message is called as the object application server of this data processing request message.
Step 105: described middle application server returns to response failed message to source application server.
In step 104, described intermediate server is by judging the ability self without this data processing request message of response of determining, this intermediate server returns to response failed message to source application server, and then by source application server, the response failed message receiving is back to Control Server.
By the scheme of the embodiment of the present application one, by source application server when receiving data processing request message, judge the ability self whether with this data processing request message of response, when determining the ability self without this data processing request message of response, according to the capabilities message of other application servers in the same cluster of this locality storage, selection has the middle application server of this data processing request message capability of response, and described data processing request message is transmitted to the middle application server of selection, avoided like this problem in prior art, the problem includes: the problem of load imbalance between each application server that the required disposal ability of the disposal ability of not considering application server or data processing request causes.
It should be noted that, when the intermediate server of source application server selection has the ability of this data processing request message of response, this middle application server responds this data processing request message ,Bing Xiang source application server as object application server and returns to response success message; When the intermediate server of source application server selection does not have the ability of this data processing request message of response, this need to reselect other application servers of ability during as middle application server with this data processing request message of response, and the mode reselecting has two kinds: application server definite middle application server in a kind of Shi You source continues to select to have other application servers of ability of this data processing request message of response as middle application server; Another kind is to source application server, to return to other application servers that failed message Hou,You source application server selects to have the ability that responds this data processing request message again at the intermediate server without the ability of this data processing request message of response.
By embodiment bis-and embodiment tri-, describe in detail and reselect other application servers of the ability with this data processing request message of response as two kinds of modes of middle application server respectively below.
Embodiment bis-:
As shown in Figure 2, it is the flow chart of method of a kind of data processing of the embodiment of the present application two, suppose to have comprised in current application server cluster these five application servers of source application server, application server A, application server B, application server C and application server D, wherein, source application server, application server A and application server B are divided in same a small group, and the method for carrying out data processing by these five application servers comprises:
Step 201: source application server, when receiving data processing request message, judges the ability self whether with this data processing request message of response, if so, returns to response success message; Otherwise, perform step 202.
Step 202: when source application server is determined the ability self without this data processing request message of response, according to the ability information of other application servers in the same cluster of this locality storage, selection has the application server of this data processing request message capability of response as middle application server, and described data processing request message is transmitted to the middle application server of selection.
Particularly, source application server determines that the concrete steps of middle application server comprise:
The first step: source application server is when determining the ability self without this data processing request message of response, according to the ability information of other application servers in the same cluster of this locality storage, determine that the application server that can respond this data processing request message is: application server A, application server B and application server C;
Second step: source application server selects an application server as middle application server from the application server that can respond this data processing request message of determining, and described data processing request message is transmitted to the middle application server of selection.
Particularly, source application server is according to the state information of each application server broadcast in the cycle that approaches this data processing request message of reception most receiving, selecting application server A is middle application server, and described data processing request message is transmitted to the middle application server A of selection.
More preferably, source application server determines that the concrete steps of middle application server comprise:
The first step: source application server is when determining the ability self without this data processing request message of response, according to the ability information of other application servers in the same cluster of this locality storage, determine that the application server that can respond this data processing request message is: application server A, application server B and application server C.
Second step: source application server selects to belong to other application servers of same a small group, i.e. application server A and application server B from the application server that can respond this data processing request message of determining.
The 3rd step: source application server selects an application server that can respond this data processing request message as middle application server again from same a small group, and described data processing request message is transmitted to the middle application server of selection.
Particularly, source application server is according to the state information of each application server broadcast in the cycle that approaches this data processing request message of reception most receiving, selection is middle application server with the application server A in a small group, and described data processing request message is transmitted to the middle application server A of selection.
It should be noted that, because source application server, application server A and application server B belong in same a small group, with having set up Socket passage in a small group between each application server, facilitate Forward-reques message and response message, the preferential intermediate server from selecting request message to forward in same a small group, the load balancing with each application server of a small group can not only be met in cluster, and the response efficiency of request message can also be improved.
Step 203: middle application server A judges the ability self whether with this data processing request message of response, if so, performs step 204; Otherwise, perform step 205.
In this step 203, described middle application server A adopts embodiment Yi Zhong source application server to judge that the method self whether with the ability that responds this data processing request message judges self-ability.
Step 204: described middle application server A responds this data processing request message ,Bing Xiang source application server as object application server and returns to response success message, end operation.
Step 205: described middle application server A, according to the ability information of other application servers in the same cluster of this locality storage, reselects an application server B with this data processing request message capability of response as middle application server.
Described middle application server A selects the principle of next middle application server identical with the principle of source application server: preferential selection with the application server in a small group with this data processing request message capability of response.
The described application server reselecting is the server of same cluster Zhong Chu source application server and the middle application server part selected.
Step 206: middle application server B judges the ability self whether with this data processing request message of response, if so, performs step 207; Otherwise, perform step 208.
In this step 206, described middle application server B adopts embodiment Yi Zhong source application server to judge that the method self whether with the ability that responds this data processing request message judges self-ability.
Step 207: described middle application server B responds this data processing request message ,Bing Xiang source application server as object application server and returns to response success message, and end operation.
It should be noted that, middle application server B is after the data processing request message to receiving is processed, using result as response success message, send to the middle application server A that forwards this data processing request message, and by middle application server, response success message is sent to source application server.
Step 208: described middle application server B traversal is determined the application server that can respond this data processing request message according to ability information, final not definite object application server that can be used as, now, middle application server B returns to response failed message to source application server.
Particularly, because intermediate server B is according to the ability information of other application servers in the same cluster of this locality storage, determine with middle application server B and belong to the application server in same a small group without this data processing request message capability of response, therefore middle application server B need to select application server as middle application server in other groups, the mode of selecting is identical by the mode of server with a small group planted agent with selection, does not describe here.
It should be noted that, at middle application server B, in traversal, according to ability information, determine while can respond the application server of this data processing request message, determine that application server C, application server D do not possess the ability that can respond this data processing request message, therefore, this data processing request message can be transmitted to application server C and application server D, but first response failed message is returned to the middle application server A that forwarding data is processed request message, by middle application server A, to source application server, return to response failed message.
Embodiment tri-:
As shown in Figure 3, it is the structural representation of method of a kind of data processing of the embodiment of the present application three, suppose to have comprised in current application server cluster these five application servers of source application server, application server A, application server B, application server C and application server D, wherein, source application server, application server A and application server B belong to same a small group, and the method for carrying out data processing by these five application servers comprises:
Step 301: source application server, when receiving data processing request message, judges the ability self whether with this data processing request message of response, if so, returns to response success message; Otherwise, perform step 302.
It should be noted that, source application server determines self not have response during this data processing request message capability, and the principle of whether selecting this data processing request to be transmitted to other application server processes is the time of the response failure result of returning to this data processing request message of determining according to the attribute information of the data processing request message receiving.
If the attribute information of the data processing request message the receiving business ,Ze source application server that to be requirement of real-time higher is being determined currently while not having this data processing request message capability of response, directly return to response failed message;
If the attribute information of the data processing request message receiving is the business that requirement of real-time is lower, source application server determine current while not thering is this data processing request message capability of response, the application server can in same a small group by the data processing request message receiving is transmitted to this data processing request message capability of response is processed, and the principle that selection is transmitted to other application servers is to select to have the application server of this data processing request message capability of response.
Step 302: when source application server is determined the ability self without this data processing request message of response, according to the ability information of other application servers in the same cluster of this locality storage, selection has the application server of this data processing request message capability of response as middle application server, and described data processing request message is transmitted to the middle application server of selection.
Particularly, source application server determines that the concrete steps of middle application server comprise:
The first step: source application server is when determining the ability self without this data processing request message of response, according to the ability information of other application servers in the same cluster of this locality storage, determine that the application server that can respond this data processing request message is: application server A, application server B and application server C;
Second step: source application server selects an application server as middle application server from the application server that can respond this data processing request message of determining, and described data processing request message is transmitted to the middle application server of selection.
Particularly, source application server is according to the state information of each application server broadcast in the nearest cycle receiving, and selecting application server A is middle application server, and described data processing request message is transmitted to the middle application server of selection.
More preferably, source application server determines that the concrete steps of middle application server comprise:
The first step: source application server is when determining the ability self without this data processing request message of response, according to the ability information of other application servers in the same cluster of this locality storage, determine that the application server that can respond this data processing request message is: application server A, application server B and application server C.
Second step: source application server selects to belong to other application servers of same a small group, i.e. application server A and application server B from the application server that can respond this data processing request message of determining.
The 3rd step: source application server selects an application server that can respond this data processing request message as middle application server again from same a small group, and described data processing request message is transmitted to the middle application server of selection.
Particularly, source application server is according to the state information of each application server broadcast in the cycle that approaches this data processing request message of reception most receiving, selection is middle application server with the application server A in a small group, and described data processing request message is transmitted to the middle application server A of selection.
It should be noted that, because source application server, application server A and application server B belong in same a small group, with having set up Socket passage in a small group between each application server, facilitate Forward-reques message and response message, the preferential intermediate server from selecting request message to forward in same a small group, the load balancing with each application server of a small group can not only be met in cluster, and the response efficiency of request message can also be improved.
Step 303: described middle application server A judges the ability self whether with this data processing request message of response, if, described middle application server responds this data processing request message as object application server, Bing Xiang source application server returns to response success message, and end operation;
Otherwise described middle application server A returns to response failed message to source application server.
Particularly, if the attribute information of the data processing request message receiving is the business that requirement of real-time is higher, source application server determine current while not thering is this data processing request message capability of response, directly return to response failed message, for example: the data processing request receiving is payment transaction request, if the response time is excessively of a specified duration, may cause the phenomenon that occurs that a transaction is repeatedly paid, now, source application server is when receiving payment transaction request, determine and currently do not there is response during this data processing request message capability, directly return to response failed message, refuse this payment transaction request,
If the attribute information of the data processing request message receiving is the business that requirement of real-time is lower, source application server determine current while not thering is this data processing request message capability of response, can, by the data processing request message receiving being transmitted to the application server in same a small group with this data processing request message capability of response, wait for the result of other application servers.
For example: the data processing request receiving is the request message of linked web pages, source application server is receiving the request message of linked web pages, and determine current while not thering is this data processing request message capability of response, by selecting and determining, this request message is transmitted to the application server with this data processing request message capability of response, by this application server processes, if this application server is current, can respond this data processing request, Ze Xiang source application server returns to response success message, if this application server is current, can not respond this data processing request, by selecting and determine that this request message is transmitted to the next application server with this data processing request message capability of response, by the application server processes of selecting, carry out successively aforesaid operations, until the hop count of this request message reaches the threshold value of setting, by current middle application server, to the application server of Forward-reques message, return to response failed message to source application server successively.
The threshold value of described setting can be according to the make out the scale of application server cluster, also can determine according to real network state, and the size of threshold value is not specifically limited here.
More preferably, source application server is when receiving data processing request message, determine self do not have mutually should data processing request message ability time, according to the ability information of other application servers in the same cluster of this locality storage, select an application server with this data processing request message capability of response as middle application server, by this middle application server, judged the ability self whether with this data processing request of response.
When this middle application server is determined the ability self without this data processing request of response, to source application server, return to response failure, now, source application server will no longer continue to select other application server, but directly the response failed message receiving is returned to Control Server, can improve like this efficiency of whole application server cluster deal with data.
Step 304: source application server is when receiving the response failed message that middle application server A returns, according to the ability information of other application servers in the same cluster of this locality storage, reselect an application server B with this data processing request message capability of response as middle application server.
Due to the application server B in addition in same a small group with source application server, therefore, source application server can also adopt the mode of step 302 using application server B as middle application server, and this data processing request is transmitted to middle application server B.
Wherein, the application server that described source application server reselects is the middle application server for having selected not.
Step 305: described middle application server B judges the ability self whether with this data processing request message of response, if, described middle application server B responds this data processing request message as object application server, Bing Xiang source application server returns to response success message, and end operation;
Otherwise described middle application server B returns to response failed message to source application server.
Step 306: source application server is when receiving the response failed message that middle application server B returns, judgement traversal determines that according to the ability information of storage the number of times of the application server that can respond this data processing request message reaches setting threshold value, if so, return to response failed message to Control Server; Otherwise, perform step 307.
Described setting threshold value can be determined according to the attribute of the data processing request message receiving, and also can determine according to the actual needs, is not specifically limited here.
Step 307: source application server, according to the ability information of other application servers in the same cluster of this locality storage, reselects an application server C with this data processing request message capability of response as middle application server.
Because the application server coexisting in Yi Ge group with source application server does not have the ability of this data processing request message of response, therefore, source application server selects application server as middle application server in other groups.
Step 308: described middle application server C judges the ability self whether with this data processing request message of response, if, described middle application server responds this data processing request message as object application server, Bing Xiang source application server returns to response success message, and end operation;
Otherwise described middle application server returns to response failed message to source application server.
Step 309: source application server is when receiving the response failed message that middle application server C returns, determine that traversal reaches setting threshold value according to the definite number of times that can respond the application server of this data processing request message of the ability information of storage, returns to response failed message to Control Server.
Now, source application server has traveled through according to the ability information of storage determines the application server that can respond this data processing request message, determining that not having object application server can respond this data processing request message Shi, source application server returns to response failed message to Control Server.
Embodiment tetra-:
As shown in Figure 4, it is the structural representation of a kind of application server of the embodiment of the present application four, and described application server can be source application server; It can be object application server; It can also be middle application server.
If described application server is source application server, described application server comprises: judge module 11 and forwarding module 12, wherein:
Judge module 11, for when receiving data processing request message, judges the ability self whether with this data processing request message of response;
Forwarding module 12, while not thering is for determining the ability that responds this data processing request message, according to the ability information of other application servers in the same cluster of this locality storage, selection has the application server of this data processing request message capability of response as middle application server, and described data processing request message is transmitted to the middle application server of selection.
Particularly, described application server also comprises: state information broadcast module 13 and state information receiver module 14, wherein,
State information broadcast module 13, for periodically to the state information of other application servers broadcast in cluster self.
State information receiver module 14, for periodically receiving the state information of other application server broadcast in cluster, cluster identity, server identification and the ability information of having carried the application server place cluster of broadcasting status messages in described state information.
Described forwarding module 12, specifically for working as, the application server in same cluster is divided into a plurality of groups, in each group, comprise a plurality of application servers, judge in the group of place and whether exist and there is the application server that responds this data processing request message capability, if so, in the group of Ze Cong place, select application server as middle application server; Otherwise select application server as middle application server in other groups.
Described application server also comprises: receiver module 15, wherein,
Receiver module 15, for receiving the response success message of returning or returning to failed message.
If described application server is middle application server, described application server also comprises: select module 16 and return messages failure module 17, wherein,
Select module 16, for according to the ability information of same other application servers of cluster of this locality storage, reselect an application server with this data processing request message capability of response as middle application server;
Return messages failure module 17, for returning to response failed message.
If described application server is object application server, described application server also comprises: data respond module 18, return messages success module 19, wherein,
Data respond module 18, for responding the data processing request message receiving;
Return messages success module 19, for returning to response success message to source application server.
It should be noted that, the source application server that an application server in cluster can be a data processing request message, it can be the middle application server of another data processing request message, it can also be the object application server of other data processing request message, therefore, application server can have the function of source application server, middle application server and object application server simultaneously.
, comprise a plurality of above-mentioned application servers.
The application is with reference to describing according to flow chart and/or the block diagram of the method for the embodiment of the present application, equipment (system) and computer program.Should understand can be in computer program instructions realization flow figure and/or block diagram each flow process and/or the flow process in square frame and flow chart and/or block diagram and/or the combination of square frame.Can provide these computer program instructions to the processor of all-purpose computer, special-purpose computer, Embedded Processor or other programmable data processing device to produce a machine, the instruction of carrying out by the processor of computer or other programmable data processing device is produced for realizing the device in the function of flow process of flow chart or a plurality of flow process and/or square frame of block diagram or a plurality of square frame appointments.
These computer program instructions also can be stored in energy vectoring computer or the computer-readable memory of other programmable data processing device with ad hoc fashion work, the instruction that makes to be stored in this computer-readable memory produces the manufacture that comprises command device, and this command device is realized the function of appointment in flow process of flow chart or a plurality of flow process and/or square frame of block diagram or a plurality of square frame.
These computer program instructions also can be loaded in computer or other programmable data processing device, make to carry out sequence of operations step to produce computer implemented processing on computer or other programmable devices, thereby the instruction of carrying out is provided for realizing the step of the function of appointment in flow process of flow chart or a plurality of flow process and/or square frame of block diagram or a plurality of square frame on computer or other programmable devices.
Obviously, those skilled in the art can carry out various changes and modification and not depart from the spirit and scope of the present invention the present invention.Like this, if within of the present invention these are revised and modification belongs to the scope of the claims in the present invention and equivalent technologies thereof, the present invention is also intended to comprise these changes and modification interior.

Claims (10)

1. a method for data processing, is characterized in that, the method comprises:
Source application server, when receiving data processing request message, judges the ability self whether with this data processing request message of response;
When source application server is determined the ability self without this data processing request message of response, according to the ability information of other application servers in the same cluster of this locality storage, selection has the application server of this data processing request message capability of response as middle application server, and described data processing request message is transmitted to the middle application server of selection.
2. the method for claim 1, is characterized in that, after described data processing request message is transmitted to the middle application server of selection, described method also comprises:
Described middle application server judges the ability self whether with this data processing request message of response;
If so, described middle application server responds this data processing request message ,Bing Xiang source application server as object application server and returns to response success message;
If not, described middle application server returns to response failed message to source application server.
3. the method for claim 1, is characterized in that, described method also comprises:
Described middle application server judges the ability self whether with this data processing request message of response;
If so, described middle application server responds this data processing request message ,Bing Xiang source application server as object application server and returns to response success message;
If not, described middle application server is according to the ability information of other application servers in the same cluster of this locality storage, select an application server with this data processing request message capability of response as middle application server, and repeat the described operation that judges the ability self whether with this data processing request message of response by the middle application server of newly selecting, until the middle application server of selecting can return to response success message as this backward source of data processing request message application server of object application server responses, or until traversal is determined the application server that can respond this data processing request message according to ability information.
4. method as claimed in claim 3, is characterized in that, the application server of described selection is the application server outside same cluster Zhong Chu source application server and the middle application server selected.
5. the method for claim 1, is characterized in that, described method also comprises:
Described middle application server judges the ability self whether with this data processing request message of response;
If so, described middle application server responds this data processing request message ,Bing Xiang source application server as object application server and returns to response success message;
If not, described middle application server returns to response failed message to source application server;
Source application server is according to the ability information of other application servers in the same cluster of this locality storage, reselect an application server with this data processing request message capability of response as middle application server, and repeat the described operation that judges the ability self whether with this data processing request message of response by the middle application server reselecting, until application server definite middle application server in source can respond this data processing request message as object application server, or, until application server traversal in source determines that according to the ability information of storage the number of times of the application server that can respond this data processing request message reaches setting threshold value.
6. method as claimed in claim 5, is characterized in that, described method also comprises: the application server that described source application server reselects is the application server outside same cluster Zhong Chu source application server and the middle application server selected.
7. the method for claim 1, is characterized in that, in cluster, arbitrary application server obtains the ability information of other application servers in same cluster in the following manner:
Application server is periodically to the state information of other application servers broadcast in cluster self, and periodically receive the state information of other application servers broadcast in cluster, cluster identity, server identification and the ability information of in described state information, having carried the application server place cluster of broadcasting status messages.
8. the method for stating as claim 1 or 7, is characterized in that, described method also comprises: the application server in same cluster is divided into a plurality of groups, comprises a plurality of application servers in each group;
Source application server, according to the ability information of other application servers in the same cluster of this locality storage, selects the application server with this data processing request message capability of response as middle application server, specifically comprises:
Source application server judges in the group of place whether exist and have the application server that responds this data processing request message capability;
If so, in the group of Ze Cong place, select application server as middle application server;
If not, in other groups, select application server as middle application server.
9. an application server, is characterized in that, this application server comprises:
Judge module, for when receiving data processing request message, judges the ability self whether with this data processing request message of response;
Forwarding module, while not thering is for determining the ability that responds this data processing request message, according to the ability information of other application servers in the same cluster of this locality storage, selection has the application server of this data processing request message capability of response as middle application server, and described data processing request message is transmitted to the middle application server of selection.
10. an application server cluster, is characterized in that, comprises a plurality of application servers claimed in claim 9.
CN201210210710.8A 2012-06-20 2012-06-20 A data processing method, an application server and an application server cluster Pending CN103516744A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201210210710.8A CN103516744A (en) 2012-06-20 2012-06-20 A data processing method, an application server and an application server cluster

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201210210710.8A CN103516744A (en) 2012-06-20 2012-06-20 A data processing method, an application server and an application server cluster

Publications (1)

Publication Number Publication Date
CN103516744A true CN103516744A (en) 2014-01-15

Family

ID=49898773

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201210210710.8A Pending CN103516744A (en) 2012-06-20 2012-06-20 A data processing method, an application server and an application server cluster

Country Status (1)

Country Link
CN (1) CN103516744A (en)

Cited By (21)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105025042A (en) * 2014-04-16 2015-11-04 中国移动通信集团河北有限公司 Method of determining data information, system and proxy servers
CN105100175A (en) * 2014-05-22 2015-11-25 北京金山网络科技有限公司 Server cluster control method, central server and node server
WO2016074497A1 (en) * 2014-11-12 2016-05-19 中兴通讯股份有限公司 Method for dividing work in stack system, master device, slave device, and system
CN105656853A (en) * 2014-11-14 2016-06-08 华为技术有限公司 Messaging method and related device
CN106797405A (en) * 2016-12-14 2017-05-31 华为技术有限公司 Distributed load equalizing system, health examination method and service node
CN106921754A (en) * 2017-05-04 2017-07-04 泰康保险集团股份有限公司 The load-balancing method of group system, device, medium and electronic equipment
CN106973065A (en) * 2017-04-28 2017-07-21 武汉票据交易中心有限公司 A kind of server event processing system and method
CN107306289A (en) * 2016-04-21 2017-10-31 中国移动通信集团重庆有限公司 A kind of load-balancing method and equipment based on cloud computing
CN107465753A (en) * 2017-08-23 2017-12-12 郑州云海信息技术有限公司 A kind of web services system
CN107680374A (en) * 2017-09-29 2018-02-09 南威软件股份有限公司 A kind of intelligent acquisition scheduling system for crossing car data
CN108718335A (en) * 2018-05-14 2018-10-30 北京百悟科技有限公司 A kind of load-balancing method, device, Web server and storage medium
CN109495587A (en) * 2018-12-25 2019-03-19 苏州思必驰信息科技有限公司 Language model synchronous method and system for voice dialogue platform
CN109981459A (en) * 2019-02-28 2019-07-05 联想(北京)有限公司 A kind of method for sending information, client and computer readable storage medium
CN110138653A (en) * 2019-05-30 2019-08-16 北京字节跳动网络技术有限公司 Message informing method and device
CN110351335A (en) * 2019-06-06 2019-10-18 国网浙江省电力有限公司衢州供电公司 A kind of cloud computing communication efficiency and service balancing method
CN110875945A (en) * 2018-09-04 2020-03-10 京东方科技集团股份有限公司 Method, apparatus and medium for task processing on a generic service entity
CN110995863A (en) * 2019-12-19 2020-04-10 上海交通大学 Data center load distribution method and system based on load demand characteristics
CN111355824A (en) * 2020-02-21 2020-06-30 上海奇频信息科技有限公司 Terminal number translation method, near-end translation device, far-end translation device and translation system
CN111400059A (en) * 2020-03-09 2020-07-10 五八有限公司 Data processing method and data processing device
CN111405025A (en) * 2020-03-11 2020-07-10 广东中兴新支点技术有限公司 Data transmission method and device, transmission equipment and readable storage medium
CN113364809A (en) * 2016-06-28 2021-09-07 贝宝公司 Offloading network data to perform load balancing

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2004077259A2 (en) * 2003-02-24 2004-09-10 Bea Systems Inc. System and method for server load balancing and server affinity
CN101207550A (en) * 2007-03-16 2008-06-25 中国科学技术大学 Load balancing system and method for multi business to implement load balancing
CN101662506A (en) * 2009-10-14 2010-03-03 中兴通讯股份有限公司 Load balancing method based on CPU kernel sharing and device thereof

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2004077259A2 (en) * 2003-02-24 2004-09-10 Bea Systems Inc. System and method for server load balancing and server affinity
CN101207550A (en) * 2007-03-16 2008-06-25 中国科学技术大学 Load balancing system and method for multi business to implement load balancing
CN101662506A (en) * 2009-10-14 2010-03-03 中兴通讯股份有限公司 Load balancing method based on CPU kernel sharing and device thereof

Cited By (34)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105025042A (en) * 2014-04-16 2015-11-04 中国移动通信集团河北有限公司 Method of determining data information, system and proxy servers
CN105025042B (en) * 2014-04-16 2019-06-28 中国移动通信集团河北有限公司 A kind of method and system of determining data information, proxy server
CN105100175A (en) * 2014-05-22 2015-11-25 北京金山网络科技有限公司 Server cluster control method, central server and node server
CN105100175B (en) * 2014-05-22 2019-01-22 北京猎豹网络科技有限公司 A kind of server cluster control method, central server and node server
WO2016074497A1 (en) * 2014-11-12 2016-05-19 中兴通讯股份有限公司 Method for dividing work in stack system, master device, slave device, and system
CN105656647A (en) * 2014-11-12 2016-06-08 中兴通讯股份有限公司 Method, master equipment, slave equipment and system for realizing labor division in stacking system
CN105656647B (en) * 2014-11-12 2020-06-30 中兴通讯股份有限公司 Method, main equipment, standby equipment and system for realizing division of labor in stacking system
CN105656853A (en) * 2014-11-14 2016-06-08 华为技术有限公司 Messaging method and related device
CN105656853B (en) * 2014-11-14 2018-11-20 华为技术有限公司 A kind of message delivery method and relevant apparatus
CN107306289A (en) * 2016-04-21 2017-10-31 中国移动通信集团重庆有限公司 A kind of load-balancing method and equipment based on cloud computing
CN107306289B (en) * 2016-04-21 2020-11-27 中国移动通信集团重庆有限公司 Load balancing method and device based on cloud computing
CN113364809B (en) * 2016-06-28 2024-03-15 贝宝公司 Offloading network data to perform load balancing
CN113364809A (en) * 2016-06-28 2021-09-07 贝宝公司 Offloading network data to perform load balancing
CN106797405A (en) * 2016-12-14 2017-05-31 华为技术有限公司 Distributed load equalizing system, health examination method and service node
CN106797405B (en) * 2016-12-14 2020-01-10 华为技术有限公司 Distributed load balancing system, health check method and service node
CN106973065A (en) * 2017-04-28 2017-07-21 武汉票据交易中心有限公司 A kind of server event processing system and method
CN106921754A (en) * 2017-05-04 2017-07-04 泰康保险集团股份有限公司 The load-balancing method of group system, device, medium and electronic equipment
CN107465753A (en) * 2017-08-23 2017-12-12 郑州云海信息技术有限公司 A kind of web services system
CN107680374A (en) * 2017-09-29 2018-02-09 南威软件股份有限公司 A kind of intelligent acquisition scheduling system for crossing car data
CN108718335A (en) * 2018-05-14 2018-10-30 北京百悟科技有限公司 A kind of load-balancing method, device, Web server and storage medium
US11700189B2 (en) 2018-09-04 2023-07-11 Boe Technology Group Co., Ltd. Method for performing task processing on common service entity, common service entity, apparatus and medium for task processing
CN110875945A (en) * 2018-09-04 2020-03-10 京东方科技集团股份有限公司 Method, apparatus and medium for task processing on a generic service entity
CN109495587A (en) * 2018-12-25 2019-03-19 苏州思必驰信息科技有限公司 Language model synchronous method and system for voice dialogue platform
CN109981459A (en) * 2019-02-28 2019-07-05 联想(北京)有限公司 A kind of method for sending information, client and computer readable storage medium
CN110138653A (en) * 2019-05-30 2019-08-16 北京字节跳动网络技术有限公司 Message informing method and device
CN110351335B (en) * 2019-06-06 2021-11-16 国网浙江省电力有限公司衢州供电公司 Communication efficiency and service balancing method for cloud computing
CN110351335A (en) * 2019-06-06 2019-10-18 国网浙江省电力有限公司衢州供电公司 A kind of cloud computing communication efficiency and service balancing method
CN110995863B (en) * 2019-12-19 2021-07-30 上海交通大学 Data center load distribution method and system based on load demand characteristics
CN110995863A (en) * 2019-12-19 2020-04-10 上海交通大学 Data center load distribution method and system based on load demand characteristics
CN111355824A (en) * 2020-02-21 2020-06-30 上海奇频信息科技有限公司 Terminal number translation method, near-end translation device, far-end translation device and translation system
CN111355824B (en) * 2020-02-21 2023-12-15 上海奇频信息科技有限公司 Terminal number translation method, near-end translation equipment, far-end translation equipment and translation system
CN111400059A (en) * 2020-03-09 2020-07-10 五八有限公司 Data processing method and data processing device
CN111400059B (en) * 2020-03-09 2023-11-14 五八有限公司 Data processing method and data processing device
CN111405025A (en) * 2020-03-11 2020-07-10 广东中兴新支点技术有限公司 Data transmission method and device, transmission equipment and readable storage medium

Similar Documents

Publication Publication Date Title
CN103516744A (en) A data processing method, an application server and an application server cluster
CN109274745B (en) Internet of things system and method for optimizing calculation of edge nodes
CN109862592B (en) Resource management and scheduling method in mobile edge computing environment based on multi-base-station cooperation
CN103412786A (en) High performance server architecture system and data processing method thereof
CN106790552B (en) A kind of content providing system based on content distributing network
CN102624884B (en) A kind of method, device and equipment for receiving P2P resource
CN104284201A (en) Video content processing method and device
CN104780210A (en) Load balancing method and device
CN109697122A (en) Task processing method, equipment and computer storage medium
CN105491150A (en) Load balance processing method based on time sequence and system
CN102436399A (en) Load-balanced acquisition method
US10616069B2 (en) Cache based on dynamic device clustering
CN110166524A (en) Switching method, device, equipment and the storage medium of data center
CN115328579B (en) Scheduling method and system for neural network training and computer readable storage medium
WO2021120633A1 (en) Load balancing method and related device
CN101196928A (en) Contents searching method, system and engine distributing unit
CN102510403B (en) Receive and the cluster distributed system and method for real-time analysis for vehicle data
CN103763206A (en) Network scheduling method and gateway
CN114710571A (en) Data packet processing system
CN109495526A (en) A kind of file transmitting method, device, system, electronic equipment and storage medium
CN105430028A (en) Service calling method, service providing method, and node
CN102075584B (en) Distributed file system and access method thereof
CN112422251B (en) Data transmission method and device, terminal and storage medium
CN103731484B (en) A kind of power save transmission method towards mobile cloud computing and middleware system
CN105515844A (en) System for improving software defined network reliability

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: 20140115