CN104618253B - A kind of transmitting message treating method and apparatus of dynamic change - Google Patents

A kind of transmitting message treating method and apparatus of dynamic change Download PDF

Info

Publication number
CN104618253B
CN104618253B CN201510032868.4A CN201510032868A CN104618253B CN 104618253 B CN104618253 B CN 104618253B CN 201510032868 A CN201510032868 A CN 201510032868A CN 104618253 B CN104618253 B CN 104618253B
Authority
CN
China
Prior art keywords
message
preserving
order
processing
source
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.)
Active
Application number
CN201510032868.4A
Other languages
Chinese (zh)
Other versions
CN104618253A (en
Inventor
张力
王宇博
李振江
周保华
陈魁
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Datang Mobile Communications Equipment Co Ltd
Original Assignee
Datang Mobile Communications Equipment 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 Datang Mobile Communications Equipment Co Ltd filed Critical Datang Mobile Communications Equipment Co Ltd
Priority to CN201510032868.4A priority Critical patent/CN104618253B/en
Publication of CN104618253A publication Critical patent/CN104618253A/en
Application granted granted Critical
Publication of CN104618253B publication Critical patent/CN104618253B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Abstract

The invention discloses a kind of transmitting message treating method and apparatus of dynamic change, to solve the problems, such as that the feature stream mode classification that existing packet order preserving uses can not be changed dynamically.This method is, outstanding message is received first, then judge whether the type of the message is the message for needing order-preserving, when finally determining that the message is the message for needing order-preserving, obtain the traffic stream identifier of the message, three kinds of feature flow algorithms based on system intialization, a kind of optimal feature flow algorithm is selected to generate the distribution of traffic flows mode of the message according to network congestion degree in network congestion, the processing of message is carried out based on the distribution of traffic flows mode, in this way, pass through prefabricated various features packet classification algorithm, feature packet classification algorithm can be dynamically changed according to different networkings and equipment form, cost is small, operability is strong.

Description

A kind of transmitting message treating method and apparatus of dynamic change
Technical field
The present invention relates to the transmitting message treating method and apparatus that the communications field more particularly to a kind of dynamic are changed.
Background technology
With universal, demand continuous improvement of the user to network bandwidth of computer network, the processing capacity of the network equipment Also higher and higher.As the core processing unit of the network equipment, CPU (Central Processing Unit, core processor) Performance become and determine the major criterion of a network device processing ability.Since the appearance of multi-core processor so that network is set New step in standby processing capacity.The processor of multicore architecture can carry out parallel processing to message, improve processing Ability, but the phenomenon that produce packet out-ordering in parallel processing, such as TCP (Transmission are generated when message being caused to forward Control Protocol, transmission control protocol) message or UDP (User Datagram Protocol, User Datagram Protocol View) packet out-ordering the problems such as, the order-preserving demand of message generates therewith.For example, double-core CPU connects successively according to the sequence of message 1,2 It receives 2 messages and is distributed to core C1, core C2 processing respectively, due to message content, the tactful and each core of CPU processing Loading condition has differences, it is possible to message 2 occurs and first be disposed, message 1 post-processes the case where finishing, if at this point, CPU The message being disposed is directly transmitted away, there have been send disorder phenomenon of the message sequence for 2,1.
It carries out using two methods, the first order-preserving method when packet order preserving design in the prior art being in message into networking Pretreatment number is carried out to message before the processing of network transmission device, is sent after processing is completed according to number, but using this The shortcomings that method progress order-preserving is processing module complexity, and to equipment requirement height, the quality of algorithm directly affects at the entirety of equipment Reason ability.Second of order-preserving method is classified according to message properties of flow, is assigned to classification in different threads and is handled, passes through guarantor The shortcomings that it is continuous to entire message protect to demonstrate,prove the sequential processes of independent feature stream, but carries out order-preserving in this way is feature The extracting mode of stream directly influences the access processing capacity of equipment, and it is unalterable that the data stream type on network, which is not, , it is characterized in that being not stop variation according to operator's networking and customer service type, current feature packet classification algorithm can not Dynamic changes, and the scope of application is single, is not suitable for flexible networking.
Invention content
The object of the present invention is to provide a kind of transmitting message treating method and apparatus of dynamic change, to solve existing message The problem of feature stream mode classification that order-preserving uses can not be changed dynamically.
The purpose of the present invention is what is be achieved through the following technical solutions:
A kind of transmitting message processing method of dynamic change, including:
Receive outstanding message;
Judge whether the type of the message is the message for needing order-preserving;
When determining that the message is the message for needing order-preserving, the traffic stream identifier of the message is obtained, is based on system intialization Three kinds of feature flow algorithms, the distribution of traffic flows mode that a kind of feature flow algorithm generates the message is randomly choosed, based on described Distribution of traffic flows mode carries out the processing of the message.
In this way, by prefabricated various features packet classification algorithm, can according to different networkings and equipment form can dynamic more The shortcomings that changing feature packet classification algorithm, minimizing existing message traffic stream order-preserving mode, and cost is small, operability By force, further promote Message processing performance, in addition, under certain specific occasion, selected by dynamic algorithm rather than group again Net can simplify a group net topology, reduce network complexity, while reducing cost of equipment maintenance.
Optionally, judge the message type whether be need the message of order-preserving, including:
Obtain the attribute information of the message, however, it is determined that the message is the message of TCP or UDP types, then described in judgement Message is the message for needing order-preserving;If it is determined that the message is other kinds of message, then judge that the message is without order-preserving Message.
Optionally, determine the message be without the message of order-preserving after, further comprise:
The message without order-preserving is selected into corresponding processor in the way of round robin schedule, described will be not necessarily to order-preserving Message be sent to the processing that the message without order-preserving is carried out on corresponding processor.
Optionally, the message without order-preserving is sent on corresponding processor and carries out the message for being not necessarily to order-preserving Processing, specifically include:
If the performance indicator of corresponding processor reaches preset threshold value, the nothing being sent on the processor is abandoned Need the message of order-preserving;
If the performance indicator of corresponding processor does not reach preset threshold value, the message without order-preserving is sent The processing of the message without order-preserving is carried out on to the corresponding processor.
Optionally, the traffic stream identifier of the message be the source IP address of message, source purpose IP address, layer protocols No. three, Source port number, source destination slogan.
Optionally, when determining that the message is the message for needing order-preserving, the traffic stream identifier of the message is obtained, based on being Three kinds of feature flow algorithms for uniting preset randomly choose the distribution of traffic flows mode that a kind of feature flow algorithm generates the message, base The processing of the message is carried out in the distribution of traffic flows mode, is specifically included:
When determining that the message is the message for needing order-preserving, the source IP address and layer protocols No. three of the message are obtained, profit With hash algorithm, the major key mark that Hash operation generates 4 bits is carried out, the major key mark pair is sent the messages to The processing of the message is carried out on the processor answered;Alternatively,
When determining that the message is the message for needing order-preserving, the source IP address, layer protocols No. three and source of the message are obtained Port numbers carry out the major key mark that Hash operation generates 4 bits, send the messages to described using hash algorithm Major key identifies the processing that the message is carried out on corresponding processor;Alternatively,
When determining that the message is the message for needing order-preserving, source purpose IP address, the layer protocols No. three of the message are obtained The major key mark that Hash operation generates 4 bits is carried out, the message is sent out using hash algorithm with source destination slogan It is sent to the major key and identifies the processing for carrying out the message on corresponding processor.
Optionally, it sends the messages to the major key and identifies the processing for carrying out the message on corresponding processor, It specifically includes:
If the performance indicator that the major key identifies corresponding processor reaches preset threshold value, discarding is sent to the major key Identify the message on corresponding processor;
If the performance indicator that the major key identifies corresponding processor does not reach preset threshold value, the message is sent out It is sent to the major key and identifies the processing for carrying out the message on corresponding processor.
A kind of transmitting message processing unit of dynamic change, including:
Receiving unit, for receiving outstanding message;
Judging unit, for judging whether the type of the message is the message for needing order-preserving;
Dispatching Unit when for determining that the message is the message for needing order-preserving, obtains the traffic stream identifier of the message, Three kinds of feature flow algorithms based on system intialization randomly choose the distribution of traffic flows side that a kind of feature flow algorithm generates the message Formula carries out the processing of the message based on the distribution of traffic flows mode.
In this way, by prefabricated various features packet classification algorithm, can according to different networkings and equipment form can dynamic more The shortcomings that changing feature packet classification algorithm, minimizing existing message traffic stream order-preserving mode, and cost is small, operability By force, further promote Message processing performance, in addition, under certain specific occasion, selected by dynamic algorithm rather than group again Net can simplify a group net topology, reduce network complexity, while reducing cost of equipment maintenance.
Optionally, when judging whether the type of the message is the message for needing order-preserving, the judging unit is used for:
Obtain the attribute information of the message, however, it is determined that the message is the message of TCP or UDP types, then described in judgement Message is the message for needing order-preserving;If it is determined that the message is other kinds of message, then judge that the message is without order-preserving Message.
Optionally, determine the message be without the message of order-preserving after, the Dispatching Unit is further used for:
The message without order-preserving is selected into corresponding processor in the way of round robin schedule, described will be not necessarily to order-preserving Message be sent to the processing that the message without order-preserving is carried out on corresponding processor.
Optionally, the message without order-preserving is sent on corresponding processor and carries out the message for being not necessarily to order-preserving Processing when, the Dispatching Unit is specifically used for:
If the performance indicator of corresponding processor reaches preset threshold value, the nothing being sent on the processor is abandoned Need the message of order-preserving;
If the performance indicator of corresponding processor does not reach preset threshold value, the message without order-preserving is sent The processing of the message without order-preserving is carried out on to the corresponding processor.
Optionally, the traffic stream identifier for the message that the Dispatching Unit obtains is the source IP address of message, source purpose IP address, layer protocols No. three, source port number, source destination slogan.
Optionally, when determining that the message is the message for needing order-preserving, the traffic stream identifier of the message is obtained, based on being Three kinds of feature flow algorithms for uniting preset randomly choose the distribution of traffic flows mode that a kind of feature flow algorithm generates the message, base When the distribution of traffic flows mode carries out the processing of the message, the Dispatching Unit is specifically used for:
When determining that the message is the message for needing order-preserving, the source IP address and layer protocols No. three of the message are obtained, profit With hash algorithm, the major key mark that Hash operation generates 4 bits is carried out, the major key mark pair is sent the messages to The processing of the message is carried out on the processor answered;Alternatively,
When determining that the message is the message for needing order-preserving, the source IP address, layer protocols No. three and source of the message are obtained Port numbers carry out the major key mark that Hash operation generates 4 bits, send the messages to described using hash algorithm Major key identifies the processing that the message is carried out on corresponding processor;Alternatively,
When determining that the message is the message for needing order-preserving, source purpose IP address, the layer protocols No. three of the message are obtained The major key mark that Hash operation generates 4 bits is carried out, the message is sent out using hash algorithm with source destination slogan It is sent to the major key and identifies the processing for carrying out the message on corresponding processor.
Optionally, it sends the messages to the major key and identifies the processing for carrying out the message on corresponding processor When, the Dispatching Unit is specifically used for:
If the performance indicator that the major key identifies corresponding processor reaches preset threshold value, discarding is sent to the major key Identify the message on corresponding processor;
If the performance indicator that the major key identifies corresponding processor does not reach preset threshold value, the message is sent out It is sent to the major key and identifies the processing for carrying out the message on corresponding processor.
Description of the drawings
Fig. 1 is the processing schematic diagram of the order-preserving message under multi-core processor form in the embodiment of the present invention;
Fig. 2 is the transmitting message process flow schematic diagram dynamically changed in the embodiment of the present invention;
Fig. 3 is the transmitting message processing device structure diagram dynamically changed in the embodiment of the present invention.
Specific implementation mode
Following will be combined with the drawings in the embodiments of the present invention, and technical solution in the embodiment of the present invention carries out clear, complete Site preparation describes, it is clear that described embodiments are only a part of the embodiments of the present invention, is not whole embodiment.It is based on Embodiment in the present invention, it is obtained by those of ordinary skill in the art without making creative efforts every other Embodiment shall fall within the protection scope of the present invention.
The present invention describes a kind of processing mode of the order-preserving message under multi-core processor form in implementing, using feature Packet classification algorithm, carries out the order-preserving processing of message, and specific process flow is seen shown in Fig. 1.
Using multi-core processor when, general tupe be processor 1 to processor N be stream process core or The different characteristic stream extraction of TCP or UDP message traffic streams is given obstructed processing core according to different algorithms and carried out by thread Processing because there are hardware processing capability differences and feature stream path difference between processing core, and be inside processing core by Processing is executed according to standing orders, as long as this requires ensureing there is no order-preserving requirement between feature stream, as long as then in feature stream Portion is handled in a processing core, and the order-preserving characteristic of the TCP or UDP message stream would not lose after the processing of Fig. 1 Sequential attribute is lost, can thus achieve the purpose that TCP the or UDP message traffic stream order-preservings.
As shown in fig.2, providing a kind of transmitting message processing method of dynamic change, detailed process in the embodiment of the present invention It is as follows.
Step 200:Receive outstanding message.
Step 201:Judge whether the type of the message is the message for needing order-preserving.
Specifically, after receiving outstanding message, obtain the attribute information of the message, however, it is determined that the message be TCP or The message of UDP types then judges the message to need the message of order-preserving;If it is determined that the message is other kinds of message, then judge The message is the message without order-preserving.
Further, determine the message that receives be without the message of order-preserving after, by the message without order-preserving according to The mode of round robin schedule selects corresponding processor, which is sent on corresponding processor and carries out message Processing, wherein round robin schedule (Round Robin Scheduling) algorithm be exactly by take turns cry in a manner of successively by request scheduling Different processors.
For example, periodically receiving outstanding message, it is assumed that system is provided with 16 feature stream handles, number 1- 16, when receiving the message without order-preserving for the first time, which is sent to the place that message is carried out on the processor that number is 1 The message when receiving the message without order-preserving for the second time, is sent to the place that message is carried out on the processor that number is 2 by reason Reason, and so on, until processor that number is 16 also performs the processing of the message without order-preserving and then secondary receives nothing When needing the message of order-preserving, the processing for carrying out message on the processor that number is 1 is reselected, is so recycled.
Specifically.The above-mentioned message without order-preserving is sent to the processing that the message is carried out on corresponding processor, specifically It is divided into two kinds of situations:
The first situation is:If the performance indicator of corresponding processor reaches preset threshold value, discarding, which is sent to, changes place Manage the message that should be not necessarily to order-preserving on device.
In this way, when the processing capacity of single processor or thread reaches bottleneck, discarding is sent to the processing processor or line The current message of journey is to ensure that back-pressure does not influence the Message processing for being distributed to other processors or thread to message, can improve in this way The process performance of message.
Second case is:If the performance indicator of corresponding processor does not reach preset threshold value, by this without protecting The message of sequence is sent to the processing that the message for being not necessarily to order-preserving is carried out on corresponding processor.
Step 202:When determining that the message is the message for needing order-preserving, the traffic stream identifier of the message is obtained, is based on system Three kinds of preset feature flow algorithms randomly choose the distribution of traffic flows mode that a kind of feature flow algorithm generates the message, based on should Distribution of traffic flows mode carries out the processing of the message.
Specifically, the traffic stream identifier of message is the source IP address of message, source purpose IP address, layer protocols No. three, source Slogan, source destination slogan.
The present invention implement according to the characteristics of TCP or UDP message traffic streams, the nothing between the message traffic stream of different port Guan Xing extracts source IP address, source purpose IP address link information, source port information, the destination interface of TCP or UDP service messages Information, the different various features of combination producing flow through filter distributor, by being adapted to driving, can be existed according to different network environments The different feature stream ways of distribution of plant maintenance side dynamic select, and dynamic comes into force, and is reconfigured without equipment initialization.
In realization at present, the prefabricated three kinds of feature packet classification algorithms of system:
Algorithm 1:It extracts the source IP address of TCP or UDP messages and layer protocols No. three carries out Hash operation and generate a 4bits Distribution index value carry out service message distribution.
Algorithm 2:The source IP address, source port number (Port) and layer protocols No. three for extracting TCP or UDP messages carry out Hash fortune Calculate the distribution for the distribution index value progress service message for generating a 4bits.
Algorithm 3:Source purpose IP address, source purpose Port and the layer protocols No. three for extracting TCP or UDP messages carry out Hash fortune Calculate the distribution for the distribution index value progress service message for generating a 4bits.
Specifically, when determining that the message is the message for needing order-preserving, the traffic stream identifier of the message is obtained, it is pre- based on system The three kinds of feature flow algorithms set randomly choose the distribution of traffic flows mode that a kind of feature flow algorithm generates the message, are based on the industry Business stream distribution mode carries out the processing of the message, specifically includes following three kinds of modes:
First way is:When determining that the message is the message for needing order-preserving, obtain the message source IP address and three layers Protocol number carries out the major key mark that Hash operation generates 4 bits, which is sent to the major key using hash algorithm Identify the processing that the message is carried out on corresponding processor.
The feature flow algorithm of this mode is suitble to networking to limit certain dedicated web site and user's download or limitation transmission flow Scene, prevent single user's flow excessive to transmission cause to bear, further increase the efficiency of transmission of message, lifting system Energy.
The second way is:When determining that the message is the message for needing order-preserving, obtain the message source IP address, three layers association View number and source port number carry out the major key mark that Hash operation generates 4 bits, which are sent using hash algorithm The processing that the message is carried out on corresponding processor is identified to the major key;Or.
The feature flow algorithm of this mode is suitble to the scene for the link number that limitation user downloads in networking, this algorithm can be to solid Determine TCP port 20 and 21 and make certain current limliting, prevents from causing single user's download link excessive.
The third mode is:When determining that the message is the message for needing order-preserving, obtain the message source purpose IP address, three Layer protocol number and source destination slogan carry out the major key mark that Hash operation generates 4 bits, by this using hash algorithm Message is sent to the major key and identifies the processing for carrying out the message on corresponding processor.
The feature flow algorithm of this mode is suitable for maximizing the network using transmission performance without limitation.
In this way, by three kinds of feature flow algorithms of system intialization, most according to network congestion degree selection in network congestion A kind of excellent feature flow algorithm generates the distribution of traffic flows mode of the message, such as passes through the packet loss frequency meter inside equipment Number judges network congestion degree, selects the distribution of services mode of discarding degree minimum.
For example, when receiving the pending message for needing order-preserving, above-mentioned three kinds of distribution of traffic flows modes can be based on, according to The difference of network environment selects a kind of suitable feature flow algorithm, carries out the major key mark that Hash operation generates 4 bits (distributing index value), preferably, a corresponding processor of major key mark, but be not changeless, it is set according to system Multiple processors can also be corresponded to by setting a major key mark, it is assumed that 16 processors are provided in system, number is 1-16 respectively, Each the different major key mark generated correspond to a different processor respectively, and correspondence is as shown in table 1.
Table 1
It should be noted that major key mark in table 1 and the correspondence of processor be it is a kind of simple for example, Actual analysis and determination can be carried out specific corresponding to relationship according to the operating condition for managing device everywhere in real system.
The processing of the message is carried out on corresponding processor specifically, the message is sent to the major key and is identified, including with Lower two kinds of situations:
The first situation is:If the performance indicator that the major key identifies corresponding processor reaches preset threshold value, abandon It is sent to the major key and identifies the message on corresponding processor.
In this way, when the processing capacity of single processor or thread reaches bottleneck, discarding is sent to the processing processor or line The current message of journey is to ensure that back-pressure does not influence the Message processing for being distributed to other processors or thread to message, can improve in this way The process performance of message.
Second case is:If the performance indicator that the major key identifies corresponding processor does not reach preset threshold value, It the message is sent to the major key identifies and carry out the processing of the message on corresponding processor.
Based on the above-mentioned technical proposal, as shown in fig.3, the present invention is provided in implementing at a kind of transmitting message of dynamic change Device is managed, including:Receiving unit 30, judging unit 31, Dispatching Unit 32, wherein:
Receiving unit 30, for receiving outstanding message.
Judging unit 31, for judging whether the type of the message is the message for needing order-preserving.
Dispatching Unit 32 when for determining that the message is the message for needing order-preserving, obtains the traffic stream identifier of the message, base In three kinds of feature flow algorithms of system intialization, the distribution of traffic flows mode that a kind of feature flow algorithm generates the message is randomly choosed, The processing of the message is carried out based on the distribution of traffic flows mode.
Preferably, when judging whether the type of the message is the message for needing order-preserving, judging unit 31 is used for:
Obtain the attribute information of the message, however, it is determined that the message is the message of TCP or UDP types, then judges that the message is Need the message of order-preserving;If it is determined that the message is other kinds of message, then judge that the message is the message without order-preserving.
Preferably, determine the message be without the message of order-preserving after, Dispatching Unit 32 is further used for:
The message without order-preserving is selected into corresponding processor in the way of round robin schedule, this is not necessarily to the report of order-preserving Text is sent to the processing that the message for being not necessarily to order-preserving is carried out on corresponding processor.
Preferably, the message without order-preserving to be sent to the place for carrying out the message for being not necessarily to order-preserving on corresponding processor When reason, Dispatching Unit 32 is specifically used for:
If the performance indicator of corresponding processor reaches preset threshold value, abandoning to be sent on the processor should be not necessarily to protect The message of sequence;
If the performance indicator of corresponding processor does not reach preset threshold value, which is sent to The processing of the message for being not necessarily to order-preserving is carried out on the corresponding processor.
Preferably, the traffic stream identifier for the message that Dispatching Unit 32 is got is the source IP address of message, source destination IP Location, layer protocols No. three, source port number, source destination slogan.
Preferably, when determining that the message is the message for needing order-preserving, the traffic stream identifier of the message is obtained, it is pre- based on system The three kinds of feature flow algorithms set randomly choose the distribution of traffic flows mode that a kind of feature flow algorithm generates the message, are based on the industry When business stream distribution mode carries out the processing of the message, Dispatching Unit 32 is specifically used for:
When determining that the message is the message for needing order-preserving, the source IP address and layer protocols No. three of the message are obtained, Kazakhstan is utilized Uncommon algorithm, carries out the major key mark that Hash operation generates 4 bits, which, which is sent to the major key, identifies corresponding processing The processing of the message is carried out on device;Alternatively,
When determining that the message is the message for needing order-preserving, the source IP address, layer protocols No. three and source port of the message are obtained Number, using hash algorithm, the major key mark that Hash operation generates 4 bits is carried out, which is sent to major key mark The processing of the message is carried out on corresponding processor;Alternatively,
When determining that the message is the message for needing order-preserving, source purpose IP address, layer protocols No. three and the source of the message are obtained Destination slogan carries out the major key mark that Hash operation generates 4 bits, which is sent to this using hash algorithm Major key identifies the processing that the message is carried out on corresponding processor.
Preferably, when the message being sent to the major key identifying the processing for carrying out the message on corresponding processor, distribution Unit 32 is specifically used for:
If the performance indicator that the major key identifies corresponding processor reaches preset threshold value, discarding is sent to major key mark The message on corresponding processor;
If the performance indicator that the major key identifies corresponding processor does not reach preset threshold value, which is sent to The major key identifies the processing that the message is carried out on corresponding processor.
In conclusion the present invention receives outstanding message in implementing, judge whether the type of the message is to need order-preserving Message when determining that the message is the message for needing order-preserving, obtains the traffic stream identifier of the message, three based on system intialization kind spy Levy flow algorithm, in network congestion according to network congestion degree, select it is optimal, a kind of feature flow algorithm generate the industry of the message Business stream distribution mode, the processing of message is carried out based on the distribution of traffic flows mode, is calculated in this way, passing through prefabricated various features flow point class Method can dynamically change feature packet classification algorithm according to different networkings and equipment form, minimize existing message The shortcomings that Business Stream order-preserving mode, and cost is small, and operability is strong, Message processing performance is further promoted, in addition, at certain Under specific occasion, by dynamic algorithm selection rather than networking again, it can simplify a group net topology, reduce network complexity, together When reduce cost of equipment maintenance.
It should be understood by those skilled in the art that, the embodiment of the present invention can be provided as method, system or computer program Product.Therefore, complete hardware embodiment, complete software embodiment or reality combining software and hardware aspects can be used in the present invention Apply the form of example.Moreover, the present invention can be used in one or more wherein include computer usable program code computer The computer program production implemented in usable storage medium (including but not limited to magnetic disk storage, CD-ROM, optical memory etc.) The form of product.
The present invention be with reference to according to the method for the embodiment of the present invention, the flow of equipment (system) and computer program product Figure and/or block diagram describe.It should be understood that can be realized by computer program instructions every first-class in flowchart and/or the block diagram The combination of flow and/or box in journey and/or box and flowchart and/or the block diagram.These computer programs can be provided Instruct the processor of all-purpose computer, special purpose computer, Embedded Processor or other programmable data processing devices to produce A raw machine so that the instruction executed by computer or the processor of other programmable data processing devices is generated for real The device for the function of being specified in present one flow of flow chart or one box of multiple flows and/or block diagram or multiple boxes.
These computer program instructions, which may also be stored in, can guide computer or other programmable data processing devices with spy Determine in the computer-readable memory that mode works so that instruction generation stored in the computer readable memory includes referring to Enable the manufacture of device, the command device realize in one flow of flow chart or multiple flows and/or one box of block diagram or The function of being specified in multiple boxes.
These computer program instructions also can be loaded onto a computer or other programmable data processing device so that count Series of operation steps are executed on calculation machine or other programmable devices to generate computer implemented processing, in computer or The instruction executed on other programmable devices is provided for realizing in one flow of flow chart or multiple flows and/or block diagram one The step of function of being specified in a box or multiple boxes.
Although preferred embodiments of the present invention have been described, it is created once a person skilled in the art knows basic Property concept, then additional changes and modifications may be made to these embodiments.So it includes excellent that the following claims are intended to be interpreted as It selects embodiment and falls into all change and modification of the scope of the invention.
Obviously, those skilled in the art can carry out the embodiment of the present invention various modification and variations without departing from this hair The spirit and scope of bright embodiment.In this way, if these modifications and variations of the embodiment of the present invention belong to the claims in the present invention And its within the scope of equivalent technologies, then the present invention is also intended to include these modifications and variations.

Claims (14)

1. a kind of transmitting message processing method of dynamic change, which is characterized in that including:
Receive outstanding message;
Judge whether the type of the message is the message for needing order-preserving;
When determining that the message is the message for needing order-preserving, the traffic stream identifier of the message is obtained, three based on system intialization Kind feature flow algorithm selects a kind of feature flow algorithm to generate the industry of the message according to different network environments and equipment form Business stream distribution mode, the processing of the message is carried out based on the distribution of traffic flows mode;
Wherein, feature flow algorithm includes algorithm 1:The source IP address and layer protocols No. three for extracting message carry out Hash operation;Algorithm 2:The source IP address, source port number and layer protocols No. three for extracting message carry out Hash operation;Algorithm 3:Extract the source purpose of message IP address, source purpose Port and layer protocols No. three carry out Hash operation.
2. the method as described in claim 1, which is characterized in that judge whether the type of the message is the message for needing order-preserving, Including:
Obtain the attribute information of the message, however, it is determined that the message is the message of TCP or UDP types, then judges the message To need the message of order-preserving;If it is determined that the message is other kinds of message, then judge that the message is the message without order-preserving.
3. method as claimed in claim 2, which is characterized in that determine the message be without the message of order-preserving after, into one Step includes:
The message without order-preserving is selected into corresponding processor in the way of round robin schedule, by the report without order-preserving Text is sent to the processing that the message without order-preserving is carried out on corresponding processor.
4. method as claimed in claim 3, which is characterized in that the message without order-preserving is sent to corresponding processor Processing described in upper progress without the message of order-preserving, specifically includes:
If the performance indicator of corresponding processor reaches preset threshold value, discarding is sent to described without protecting on the processor The message of sequence;
If the performance indicator of corresponding processor does not reach preset threshold value, the message without order-preserving is sent to institute State the processing that the message without order-preserving is carried out on corresponding processor.
5. the method as described in claim 1, which is characterized in that the traffic stream identifier of the message be message source IP address, Source purpose IP address, layer protocols No. three, source port number, source destination slogan.
6. method as described in any one in claim 1-5, which is characterized in that determine that the message is the message for needing order-preserving When, the traffic stream identifier of the message is obtained, three based on system intialization kind feature flow algorithm randomly chooses a kind of feature stream calculation Method generates the distribution of traffic flows mode of the message, the processing of the message is carried out based on the distribution of traffic flows mode, specifically Including:
When determining that the message is the message for needing order-preserving, the source IP address and layer protocols No. three of the message are obtained, Kazakhstan is utilized Uncommon algorithm carries out the major key mark that Hash operation generates 4 bits, it is corresponding to send the messages to the major key mark The processing of the message is carried out on processor;Alternatively,
When determining that the message is the message for needing order-preserving, the source IP address, layer protocols No. three and source port of the message are obtained Number, using hash algorithm, the major key mark that Hash operation generates 4 bits is carried out, the major key is sent the messages to Identify the processing that the message is carried out on corresponding processor;Alternatively,
When determining that the message is the message for needing order-preserving, source purpose IP address, layer protocols No. three and the source of the message are obtained Destination slogan carries out the major key mark that Hash operation generates 4 bits, sends the messages to using hash algorithm The major key identifies the processing that the message is carried out on corresponding processor.
7. method as claimed in claim 6, which is characterized in that send the messages to the major key and identify corresponding processing The processing that the message is carried out on device, specifically includes:
If the performance indicator that the major key identifies corresponding processor reaches preset threshold value, discarding is sent to the major key mark The message on corresponding processor;
If the performance indicator that the major key identifies corresponding processor does not reach preset threshold value, send the messages to The major key identifies the processing that the message is carried out on corresponding processor.
8. a kind of transmitting message processing unit of dynamic change, which is characterized in that including:
Receiving unit, for receiving outstanding message;
Judging unit, for judging whether the type of the message is the message for needing order-preserving;
Dispatching Unit when for determining that the message is the message for needing order-preserving, obtaining the traffic stream identifier of the message, being based on Three kinds of feature flow algorithms of system intialization select a kind of feature flow algorithm to generate according to different network environments and equipment form The distribution of traffic flows mode of the message carries out the processing of the message based on the distribution of traffic flows mode;
Wherein, feature flow algorithm includes algorithm 1:The source IP address and layer protocols No. three for extracting message carry out Hash operation;Algorithm 2:The source IP address, source port number and layer protocols No. three for extracting message carry out Hash operation;Algorithm 3:Extract the source purpose of message IP address, source purpose Port and layer protocols No. three carry out Hash operation.
9. device as claimed in claim 8, which is characterized in that judge whether the type of the message is the message for needing order-preserving When, the judging unit is used for:
Obtain the attribute information of the message, however, it is determined that the message is the message of TCP or UDP types, then judges the message To need the message of order-preserving;If it is determined that the message is other kinds of message, then judge that the message is the message without order-preserving.
10. device as claimed in claim 9, which is characterized in that determine the message be without the message of order-preserving after, it is described Dispatching Unit is further used for:
The message without order-preserving is selected into corresponding processor in the way of round robin schedule, by the report without order-preserving Text is sent to the processing that the message without order-preserving is carried out on corresponding processor.
11. device as claimed in claim 10, which is characterized in that the message without order-preserving is sent to corresponding processing When carrying out the processing of the message for being not necessarily to order-preserving on device, the Dispatching Unit is specifically used for:
If the performance indicator of corresponding processor reaches preset threshold value, discarding is sent to described without protecting on the processor The message of sequence;
If the performance indicator of corresponding processor does not reach preset threshold value, the message without order-preserving is sent to institute State the processing that the message without order-preserving is carried out on corresponding processor.
12. device as claimed in claim 8, which is characterized in that the business for the message that the Dispatching Unit obtains is failed to be sold at auction Know the source IP address for message, source purpose IP address, layer protocols No. three, source port number, source destination slogan.
13. such as claim 8-12 any one of them devices, which is characterized in that determine that the message is the message for needing order-preserving When, the traffic stream identifier of the message is obtained, three based on system intialization kind feature flow algorithm randomly chooses a kind of feature stream calculation Method generates the distribution of traffic flows mode of the message, when carrying out the processing of the message based on the distribution of traffic flows mode, institute Dispatching Unit is stated to be specifically used for:
When determining that the message is the message for needing order-preserving, the source IP address and layer protocols No. three of the message are obtained, Kazakhstan is utilized Uncommon algorithm carries out the major key mark that Hash operation generates 4 bits, it is corresponding to send the messages to the major key mark The processing of the message is carried out on processor;Alternatively,
When determining that the message is the message for needing order-preserving, the source IP address, layer protocols No. three and source port of the message are obtained Number, using hash algorithm, the major key mark that Hash operation generates 4 bits is carried out, the major key is sent the messages to Identify the processing that the message is carried out on corresponding processor;Alternatively,
When determining that the message is the message for needing order-preserving, source purpose IP address, layer protocols No. three and the source of the message are obtained Destination slogan carries out the major key mark that Hash operation generates 4 bits, sends the messages to using hash algorithm The major key identifies the processing that the message is carried out on corresponding processor.
14. device as claimed in claim 13, which is characterized in that send the messages to the major key and identify corresponding place When carrying out the processing of the message on reason device, the Dispatching Unit is specifically used for:
If the performance indicator that the major key identifies corresponding processor reaches preset threshold value, discarding is sent to the major key mark The message on corresponding processor;
If the performance indicator that the major key identifies corresponding processor does not reach preset threshold value, send the messages to The major key identifies the processing that the message is carried out on corresponding processor.
CN201510032868.4A 2015-01-22 2015-01-22 A kind of transmitting message treating method and apparatus of dynamic change Active CN104618253B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510032868.4A CN104618253B (en) 2015-01-22 2015-01-22 A kind of transmitting message treating method and apparatus of dynamic change

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510032868.4A CN104618253B (en) 2015-01-22 2015-01-22 A kind of transmitting message treating method and apparatus of dynamic change

Publications (2)

Publication Number Publication Date
CN104618253A CN104618253A (en) 2015-05-13
CN104618253B true CN104618253B (en) 2018-08-07

Family

ID=53152539

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510032868.4A Active CN104618253B (en) 2015-01-22 2015-01-22 A kind of transmitting message treating method and apparatus of dynamic change

Country Status (1)

Country Link
CN (1) CN104618253B (en)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108718259B (en) * 2018-05-30 2020-07-03 新华三信息安全技术有限公司 Message processing method and multi-core processor
CN111262792B (en) * 2020-01-17 2022-04-01 新华三信息安全技术有限公司 Message forwarding method, device, network equipment and storage medium
WO2021159478A1 (en) * 2020-02-14 2021-08-19 华为技术有限公司 Message order preservation method and apparatus
CN111628941A (en) * 2020-05-27 2020-09-04 广东浪潮大数据研究有限公司 Network traffic classification processing method, device, equipment and medium
CN112965824B (en) * 2021-03-31 2024-04-09 北京金山云网络技术有限公司 Message forwarding method and device, storage medium and electronic equipment
CN114553774B (en) * 2021-12-24 2023-06-16 锐捷网络股份有限公司 Message forwarding method, device, equipment and medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102664815A (en) * 2012-05-21 2012-09-12 华为技术有限公司 Load sharing method, device and system for message traffic
CN103384221A (en) * 2013-06-26 2013-11-06 汉柏科技有限公司 Method for optimizing service precedence message fast forwarding
CN103457868A (en) * 2013-08-15 2013-12-18 北京华为数字技术有限公司 Load sharing method and device

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4919608B2 (en) * 2005-03-02 2012-04-18 株式会社日立製作所 Packet transfer device
US7668107B2 (en) * 2006-03-22 2010-02-23 Marvell Israel (M.I.S.L.) Ltd. Hardware implementation of network testing and performance monitoring in a network device
CN101072176A (en) * 2007-04-02 2007-11-14 华为技术有限公司 Report processing method and system
CN102055657B (en) * 2009-11-02 2013-03-13 杭州华三通信技术有限公司 Load distributing method of fiber channel (FC) data message and FC exchanger system
EP2395710B1 (en) * 2010-06-08 2013-11-06 Alcatel Lucent Device and method for data load balancing
CN101986627B (en) * 2010-11-25 2012-09-05 北京星网锐捷网络技术有限公司 Method, device and equipment for balancing loads
CN103731307B (en) * 2013-12-30 2017-01-04 浙江大学 A kind of for multiple services standardized data face dynamic reconfiguration method

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102664815A (en) * 2012-05-21 2012-09-12 华为技术有限公司 Load sharing method, device and system for message traffic
CN103384221A (en) * 2013-06-26 2013-11-06 汉柏科技有限公司 Method for optimizing service precedence message fast forwarding
CN103457868A (en) * 2013-08-15 2013-12-18 北京华为数字技术有限公司 Load sharing method and device

Also Published As

Publication number Publication date
CN104618253A (en) 2015-05-13

Similar Documents

Publication Publication Date Title
CN104618253B (en) A kind of transmitting message treating method and apparatus of dynamic change
CN105743822B (en) A kind of method and device handling message
CN104954274B (en) Generate method, controller and the business Delivery Function of forwarding information
CN104982006B (en) For providing the system and method for software definition protocol stack
US10313233B2 (en) Method for routing data, computer program, network controller and network associated therewith
CN104734872B (en) A kind of industrial backhaul network implementation method and system based on software defined network
CN101094185A (en) Method and device for forwarding message based on multilink
CN106170024A (en) A kind of system, method and node processed based on data in software defined network
CN101997826A (en) Routing methods of control net element, forwarding net element and internet protocol network
CN104469845B (en) A kind of message processing method, system and equipment
CN106375214A (en) SDN-based tiered routing path determination method and device
CN104660507B (en) The control method and device of forwarding data flow routing
CN106603550B (en) A kind of Network Isolation method and device
CN104320358A (en) QoS (Quality of Service) business control method in power telecommunication net
CN105556916B (en) The information statistical method and device of network flow
CN101789949B (en) Method and router equipment for realizing load sharing
CN110365589A (en) A kind of routing of electric power optical transport and frequency spectrum distributing method based on elastic optical network
CN105391651B (en) Virtual optical network multi-layer resource convergence method and system
CN103023804A (en) Method, device and network equipment for polymerization chain self-adaption flow load balance
CN110519302A (en) A kind of method and apparatus of anti-message aggression
CN106572009A (en) Method and device for forwarding massages under multi-operator link environment
KR101841026B1 (en) Service function chaining network system for path optimization
EP3253007A1 (en) Data message transmission method and edge routing bridge device
CN107846341A (en) Method, relevant apparatus and the system of schedules message
US10666545B2 (en) Shaping outgoing traffic of network packets in a network management system

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant