CN117527933A - Service processing method, device, electronic equipment and medium - Google Patents

Service processing method, device, electronic equipment and medium Download PDF

Info

Publication number
CN117527933A
CN117527933A CN202311518663.8A CN202311518663A CN117527933A CN 117527933 A CN117527933 A CN 117527933A CN 202311518663 A CN202311518663 A CN 202311518663A CN 117527933 A CN117527933 A CN 117527933A
Authority
CN
China
Prior art keywords
target
link
message
flow
stream
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
CN202311518663.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.)
New H3C Technologies Co Ltd
Original Assignee
New H3C Technologies 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 New H3C Technologies Co Ltd filed Critical New H3C Technologies Co Ltd
Priority to CN202311518663.8A priority Critical patent/CN117527933A/en
Publication of CN117527933A publication Critical patent/CN117527933A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/22Parsing or analysis of headers
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/08Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
    • H04L43/0876Network utilisation, e.g. volume of load or congestion level
    • H04L43/0894Packet rate
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/56Provisioning of proxy services
    • H04L67/568Storing data temporarily at an intermediate stage, e.g. caching
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/10Streamlined, light-weight or high-speed protocols, e.g. express transfer protocol [XTP] or byte stream

Abstract

The application discloses a business processing method, a business processing device, electronic equipment and a medium. By applying the technical scheme, after the chip receives the message stream, on one hand, one network board link is responsible for transmitting the message stream to the destination end, so that the problem of data disorder caused by different arrival time of each sub-stream at the opposite end due to splitting the message stream into a plurality of sub-streams and transmitting the sub-streams by different network board links is avoided. On the other hand, when the chip detects that the total bandwidth of the mesh board link cannot independently support the transmission of the message stream, after the mesh board link finishes transmitting part of the data of the message stream, other mesh board links are selected to transmit other part of the data of the message stream. Therefore, the technical scheme for prohibiting the simultaneous transmission of the same message stream by the multi-network-board link is realized, so that the time for each sub-stream of the message stream to reach the opposite end is ensured not to be disordered, and the problem of disordered data of the message stream is further avoided.

Description

Service processing method, device, electronic equipment and medium
Technical Field
The present application relates to data processing technologies, and in particular, to a method, an apparatus, an electronic device, and a medium for service processing.
Background
With the advent of the chip age, schemes for performing service processing by using chips are increasingly applied to various service scenarios.
Under the related art, a chip generally includes a line card LC for performing service processing on a message and a network board SFC for forwarding the message. Because the number of the mesh plates is large, the number of the mesh plate links for carrying out service transmission on the message is large. This also results in a situation that a chip forwards a received packet stream to a line card board through a mesh board link, where a plurality of mesh board links together forward a packet stream to a mesh board link of a destination.
However, the above situation also causes a problem that the message flows reaching the destination end are out of order due to the different communication states of the network links.
Disclosure of Invention
The embodiment of the application provides a service processing method, a device, electronic equipment and a medium. Thus, the problem that the message flow reaching the line card board is out of order in the related technology is solved.
According to one aspect of the embodiment of the present application, a method for processing a service is provided, and the method is applied to a chip, and includes:
When the line card board is determined to receive the message flow, distributing one message flow to a corresponding network board link by utilizing a preset distribution strategy;
if the total bandwidth flow of the target mesh board link is determined to be incapable of supporting the distributed target message flow, selecting other mesh board links for the target message flow after detecting that the first partial data of the target message flow is transmitted by using the target mesh board link, wherein the target mesh board link is any mesh board link in the chip;
and transmitting second partial data of the target message stream by using the other network board links until all data of the target message stream are determined to be transmitted, wherein the second partial data are adjacent to the first partial data and are not transmitted in the target message stream.
Optionally, in another embodiment of the method according to the present application, the determining that the total bandwidth traffic of the target mesh board link cannot support the allocated target packet flow includes:
and when the total bandwidth flow of the target mesh board link is detected to be lower than the flow rate corresponding to the target message flow, determining that the target mesh board link cannot support the target message flow.
Optionally, in another embodiment of the foregoing method according to the present application, the detecting that the total bandwidth traffic of the target mesh board link is lower than the flow rate corresponding to the target packet flow includes:
obtaining a buffer occupancy index belonging to a corresponding port of the target network board link, wherein the buffer occupancy index corresponds to the buffer quantity of the message stream and/or the buffer data size of the message stream;
and if the buffer occupancy index is detected to be higher than a first threshold value, determining that the total bandwidth flow of the target network board link is lower than the flow rate corresponding to the target message flow.
Optionally, in another embodiment based on the above method of the present application, the method further includes:
and if the buffer occupancy index is detected to be higher than a limit threshold value, indicating the target network board link to discard the target message flow, wherein the limit threshold value is higher than the first threshold value.
Optionally, in another embodiment of the method according to the present application, the transmitting, by using the other mesh link, the second portion of data of the target packet flow includes:
detecting whether other message flows are transmitted by the links of the other network boards currently;
If yes, after determining that the other network board links have transmitted the other message flows, transmitting second partial data of the target message flows by using the other network board links;
if not, directly transmitting the second part of data of the target message flow by using the other network board links.
Optionally, in another embodiment based on the above method of the present application, determining that the other mesh board link has completed transmitting the other packet stream includes:
calculating the transmission delay of the other network board links for transmitting the other message streams based on the buffer occupancy indexes of the other network board links; acquiring an initial time point of the other network board links for transmitting the other message streams last time;
and when the current time point is detected to be later than the transmission finishing time point, determining that the other network plate links are transmitted to finish the other message flows, wherein the transmission finishing time point is the time point after the transmission delay from the initial time point.
Optionally, in another embodiment of the method according to the present application, before the transmitting the second portion of data of the target packet stream by using the other mesh link, the method further includes:
Obtaining buffer occupancy indexes of all the corresponding ports of the screen plate links in the chip;
and taking the network board links lower than the second threshold value in all the buffer occupancy indexes as the other network board links.
Optionally, in another embodiment based on the above method of the present application, the method further includes:
and if the total bandwidth flow of the target mesh board link is determined to be capable of supporting the allocated target message flow, completing all data transmission of the target message flow by utilizing the target mesh board link.
Optionally, in another embodiment of the method according to the present application, the allocating a packet flow to a corresponding network board link by using a preset allocation policy includes:
sequentially generating matching identifiers for each message stream based on stream data information corresponding to each message stream, wherein one matching identifier corresponds to one network board link;
each message flow is allocated to a network link corresponding to the matching identifier.
Optionally, in another embodiment based on the above method of the present application, the matching identifier is a hash value.
According to still another aspect of the embodiments of the present application, a device for processing a service is provided, where the device is applied to a chip, and the device includes:
The distribution module is configured to distribute one message stream to a corresponding network board link by utilizing a preset distribution strategy when the line card board is determined to receive the message stream;
the detection module is configured to select other mesh board links for the target message stream after detecting that the first partial data of the target message stream is transmitted by using the target mesh board link if the total bandwidth flow of the target mesh board link cannot support the allocated target message stream, wherein the target mesh board link is any one mesh board link in the chip;
and the transmission module is configured to transmit second partial data of the target message stream by using the other network board links until all data of the target message stream are determined to be transmitted, wherein the second partial data is adjacent to the first partial data and is not transmitted in the target message stream.
According to still another aspect of the embodiments of the present application, there is provided an electronic device including:
a memory for storing executable instructions; and
and the display is used for executing the executable instructions with the memory so as to finish the operation of the business processing method.
According to yet another aspect of the embodiments of the present application, there is provided a computer-readable storage medium storing computer-readable instructions that, when executed, perform the operations of the method of any one of the above-described business processes.
In the application, when the line card board is determined to receive the message flow, a preset allocation strategy is utilized to allocate one message flow to a corresponding network board link; if the total bandwidth flow of the target mesh board link is determined to be incapable of supporting the distributed target message flow, selecting other mesh board links for the target message flow after detecting that the first partial data of the target message flow is transmitted by the target mesh board link, wherein the target mesh board link is any mesh board link in a chip; and transmitting second partial data of the target message stream by using other network plate links until all data of the target message stream are determined to be transmitted, wherein the second partial data are adjacent to the first partial data in the target message stream and are not transmitted.
By applying the technical scheme, after the chip receives the message stream, on one hand, one network board link is responsible for transmitting the message stream to the destination end, so that the problem of data disorder caused by different arrival time of each sub-stream at the opposite end due to splitting the message stream into a plurality of sub-streams and transmitting the sub-streams by different network board links is avoided. On the other hand, when the chip detects that the total bandwidth of the mesh board link cannot independently support the transmission of the message stream, after the mesh board link finishes transmitting part of the data of the message stream, other mesh board links are selected to transmit other part of the data of the message stream. Therefore, the technical scheme for prohibiting the simultaneous transmission of the same message stream by the multi-network-board link is realized, so that the time for each sub-stream of the message stream to reach the opposite end is ensured not to be disordered, and the problem of disordered data of the message stream is further avoided.
The technical scheme of the present application is described in further detail below through the accompanying drawings and examples.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments of the application and, together with the description, serve to explain the principles of the application.
The present application will be more clearly understood from the following detailed description with reference to the accompanying drawings, in which:
fig. 1 is a schematic diagram of a method for performing service processing on a packet flow in a related art provided in the present application;
FIG. 2 is a schematic diagram of a method for performing service processing on a message flow according to another related art provided in the present application;
FIG. 3 is a schematic diagram of a method for service processing according to the present application;
fig. 4 is a schematic diagram of a service processing for a packet flow according to the present application;
fig. 5 is an overall flow diagram of a method for service processing according to the present application;
fig. 6 is a schematic structural diagram of an electronic device according to the present application;
fig. 7 is a schematic structural diagram of an electronic device according to the present application.
Detailed Description
Various exemplary embodiments of the present application will now be described in detail with reference to the accompanying drawings. It should be noted that: the relative arrangement of the components and steps, numerical expressions and numerical values set forth in these embodiments do not limit the scope of the present application unless it is specifically stated otherwise.
Meanwhile, it should be understood that the sizes of the respective parts shown in the drawings are not drawn in actual scale for convenience of description.
The following description of at least one exemplary embodiment is merely exemplary in nature and is in no way intended to limit the application, its application, or uses.
Techniques, methods, and apparatus known to one of ordinary skill in the relevant art may not be discussed in detail, but are intended to be part of the specification where appropriate.
It should be noted that: like reference numerals and letters denote like items in the following figures, and thus once an item is defined in one figure, no further discussion thereof is necessary in subsequent figures.
In addition, the technical solutions of the embodiments of the present application may be combined with each other, but it is necessary to be based on the fact that those skilled in the art can implement the technical solutions, and when the technical solutions are contradictory or cannot be implemented, the combination of the technical solutions should be considered to be absent, and is not within the scope of protection claimed in the present application.
It should be noted that all directional indicators (such as up, down, left, right, front, and rear … …) in the embodiments of the present application are merely used to explain the relative positional relationship, movement conditions, and the like between the components in a specific posture (as shown in the drawings), and if the specific posture is changed, the directional indicator is correspondingly changed.
A method for performing service processing according to an exemplary embodiment of the present application is described below with reference to fig. 1 to 5. It should be noted that the following application scenario is only shown for the convenience of understanding the spirit and principles of the present application, and embodiments of the present application are not limited in any way in this respect. Rather, embodiments of the present application may be applied to any scenario where applicable.
The application also provides a service processing method, a device, electronic equipment and a medium.
Under the related art, a chip generally includes a line card LC for performing service processing on a message and a network board SFC for forwarding the message. Because the number of the mesh plates is large, the number of the mesh plate links for carrying out service transmission on the message is large.
For example, as shown in fig. 1, the chip includes a wired card LC0, a wired card net LC1, and 3 net SFCs SFC0, SFC1, SF2, and the total bandwidth flow of each net link is 40G.
When the chip receives 1 message flow and the flow rate of the message flow is 33G, the message flow is first received by LC0 and retransmitted to LC1 through a plurality of network links (two or three of which may be) in the middle, for example, SFC0, SFC1, SF2 in the middle.
It can be understood that if each message flow can each self-travel one mesh board link, the message flows will not be disordered, but in the related art, the message flows are actually transmitted by each mesh board link in a packet-by-packet split manner, that is, one message flow will pass through a plurality of mesh board links, so that the message flows reaching the destination end will be disordered.
In another way, as shown in fig. 2, for example, the chip includes a wired card LC0, a wired card net LC1, and 3 net SFCs SFC0, SFC1, SF2, and the total bandwidth flow of each net link is 40G.
When the chip receives 1 message stream and the stream rate of the message stream is 100G, the stream rate of the message stream is 100G greater than the total bandwidth flow of the network link 40G. The message stream is thus first received by LC0 and must be split up into 3 sub-streams (33.3G per sub-stream) by intermediately passing through a number of mesh links, where it is transmitted by SFC0, SFC1, SF2 to LC1.
It can be understood that, since the flow rate of the packet stream is greater than the total bandwidth flow of the mesh board link, the mesh board link cannot support the packet stream independently, so that in the related art, it is also required to split each packet stream packet by packet to transmit each mesh board link, that is, one packet stream will pass through multiple mesh board links, which will cause the packet stream reaching the destination end to be out of order.
Based on the above-mentioned problems in the related art, the present application proposes a flow chart of a method for service processing. As shown in fig. 3, the method is applied to a chip, and includes:
s101, when the line card board is determined to receive the message flow, distributing the message flow to a corresponding network board link by utilizing a preset distribution strategy.
In one manner, the embodiment of the application is different from the technical scheme in the related art that one message stream is distributed to a plurality of network board links for transmission, so that data disorder occurs due to different arrival time of each sub-stream at the opposite end. And distributing a message stream to a corresponding one of the network board links according to a preset distribution strategy so that the network board link is responsible for transmitting the message stream. Thus, the purpose of multi-object transmission of the message stream is avoided.
As an example, the embodiment of the present application does not specifically limit the preset allocation policy, and may be, for example, a random allocation policy, a sequential allocation policy or a cyclic allocation policy, a low-load priority allocation policy, or the like.
For example, when the number of packet flows is one, it may be allocated to the mesh link a using a random allocation policy, a sequential allocation policy, a low-load priority allocation policy, or the like.
As yet another example, when the number of packet flows is plural, it may be sequentially allocated to the mesh link a, the mesh link B, the mesh link C using a random allocation policy, a sequential allocation policy, a low-load priority allocation policy, or the like.
As another example, when the number of message flows is greater than the total number of mesh links within the current chip, then a round robin allocation policy may be selected. For example, when the number of message flows is three and the total number of the mesh links is 2, the first mesh link in the two mesh links can be used for transmitting the third message flow after the two mesh links are allocated.
S102, if it is determined that the total bandwidth flow of the target mesh board link cannot support the allocated target message flow, selecting other mesh board links for the target message flow after detecting that the first partial data of the target message flow is transmitted by using the target mesh board link, wherein the target mesh board link is any one mesh board link in the chip.
In one manner, if the total bandwidth flow of each mesh link is higher than the flow rate of the message stream to which it is assigned (e.g., the total bandwidth flow of the target mesh link is 40G and the flow rate of the target message stream is 10G), it represents that it is capable of independently transmitting the message stream to the designated line card. So that all data transmission of the responsible message stream can be independently completed by the same.
Alternatively, if the total bandwidth flow of each mesh link is lower than the flow rate of the packet stream allocated to it (e.g., the total bandwidth flow of the target mesh link is 40G and the flow rate of the target packet stream is 100G), then it represents that the independently transmitted target packet stream has exceeded the bandwidth bearing range of the target mesh link, and then one or more other mesh links must be selected to co-assist the mesh links for transmission.
And S103, transmitting second partial data of the target message stream by utilizing other network board links until all data of the target message stream are determined to be transmitted, wherein the second partial data are adjacent to the first partial data and are not transmitted in the target message stream.
For example, when the chip receives a target packet stream with a flow rate of 100G, the flow rate of 100G is greater than the total bandwidth traffic of 40G of the target mesh board link. It is therefore necessary to first transmit the first part of the data (i.e. the data of 0-first 40G) of the target packet stream by the target mesh board link.
It will be appreciated that the step of selecting the other mesh link (e.g., mesh link B, and the total bandwidth traffic is 40G) is initiated after determining that the transmission of the 40G data of the target packet stream using the target mesh link a is completed. And continues to transmit the secondary 40G data (i.e. 40G-80G data) of the target packet stream by the mesh link B at a later time,
It should be noted that, in the embodiment of the present application, the step of selecting the other mesh link must be started after the first portion of the data of the target packet stream is transmitted by the target mesh link a. This is because it must be ensured that the first mesh link transmits its responsible stream data after the end of its responsible stream data transmission, and the second mesh link transmits its responsible stream data. This ensures that each sub-stream (i.e., each portion of data) received by the opposite end is received in byte order of the original message stream.
Further, in the embodiment of the present application, after determining that the transmission of the 40G data of the target message stream by using the mesh link B is completed, if the target message stream is not completely transmitted at this time, the step of selecting another mesh link (for example, the mesh link C is required to be started again, and the total bandwidth flow is also 40G). And continues to transmit the next 20G data (i.e., 80G-100G data) of the target packet stream by the mesh board link C at a later time. Until all data transmission of the target message stream is detected.
It should also be noted that, in the embodiment of the present application, the step of selecting the other mesh link must be started after the second portion of the data of the target packet stream is transmitted by the mesh link N. This is because it must be ensured that the second mesh link transmits its responsible stream data after the end of its responsible stream data transmission, and the third mesh link transmits its responsible stream data. This ensures that each sub-stream (i.e., each portion of data) received by the opposite end is received in byte order of the original message stream.
By applying the technical scheme, after the chip receives the message stream, on one hand, one network board link is responsible for transmitting the message stream to the destination end, so that the problem of data disorder caused by different arrival time of each sub-stream at the opposite end due to splitting the message stream into a plurality of sub-streams and transmitting the sub-streams by different network board links is avoided. On the other hand, when the chip detects that the total bandwidth of the mesh board link cannot independently support the transmission of the message stream, after the mesh board link finishes transmitting part of the data of the message stream, other mesh board links are selected to transmit other part of the data of the message stream. Therefore, the technical scheme for prohibiting the simultaneous transmission of the same message stream by the multi-network-board link is realized, so that the time for each sub-stream of the message stream to reach the opposite end is ensured not to be disordered, and the problem of disordered data of the message stream is further avoided. The method has the defect of slower recovery time of the storage system.
Optionally, in another embodiment based on the method described in the present application, determining that the total bandwidth traffic of the target mesh board link cannot support the allocated target packet flow includes:
and when the total bandwidth flow of the target mesh board link is detected to be lower than the flow rate corresponding to the target message flow, determining that the target mesh board link cannot support the target message flow.
Optionally, in another embodiment based on the method described above, detecting that the total bandwidth traffic of the target mesh board link is lower than the corresponding flow rate of the target packet flow includes:
obtaining a buffer occupancy index of a corresponding port of a target network board link, wherein the buffer occupancy index corresponds to the buffer quantity of a message stream and/or the buffer data size of the message stream;
if the buffer occupancy index is detected to be higher than the first threshold value, determining that the total bandwidth flow of the target network board link is lower than the flow rate corresponding to the target message flow.
In one manner, if the total bandwidth flow of the target mesh link is lower than the flow rate of the target packet stream allocated to the target mesh link (e.g., the total bandwidth flow of the target mesh link is 30G and the flow rate of the target packet stream is 60G), it is determined that the target mesh link cannot support the target packet stream transmission if the independently transmitted target packet stream has exceeded the bandwidth bearing range of the target mesh link.
For example, in order to identify whether the mesh link can support the target packet streaming in the embodiment of the present application, the determination may be based on the buffer occupancy of the corresponding port, that is, based on the comparison between the buffer occupancy indicator and the first threshold value.
It will be appreciated that since a plurality of ports (e.g., including at least one egress port and at least one ingress port) are configured in each mesh plate link. In one approach, a port may be used to buffer a message stream for subsequent transmission. That is, if the ports of the mesh link exceed the bandwidth, the corresponding buffer index is always increased (e.g., the buffer number may be increased, and/or the buffer data size may be increased).
Based on this, in the embodiment of the present application, a threshold (i.e., a first threshold) may be configured, and when the buffer index exceeds the first threshold, the port is considered to exceed the bandwidth bearing range (i.e., it is determined that the total bandwidth flow of the target mesh board link is lower than the flow rate corresponding to the target packet flow). It can be appreciated that the embodiment of the present application may further configure a low threshold, that is, if the buffer index is below the low threshold, the port is considered not to exceed the bandwidth bearing range.
As an example, the first threshold may be 100 buffers of the packet stream, and/or 100G buffers of data, etc. The present application is not limited in this regard.
Optionally, in another embodiment based on the above method of the present application, the method further comprises:
and if the buffer occupancy index is detected to be higher than a limit threshold value, indicating the target network board link to discard the target message flow, wherein the limit threshold value is higher than a first threshold value.
In one approach, if the number of message stream buffers for the target mesh plate link has been above a certain level and/or the buffered data size has been above a certain level. It may be determined that the current buffer occupancy index of the mesh link is above the limit threshold. In order to avoid the defect of overload, the embodiment of the application can instruct the device to return the received message stream to the corresponding LC uplink board, so that the uplink board LC discards the message stream and does not process the message stream.
Optionally, in another embodiment based on the above method of the present application, transmitting the second portion of the data of the target packet stream by using the other network link includes:
detecting whether other message flows are transmitted by other network board links currently;
if yes, after determining that the other network board links have transmitted other message flows, transmitting second partial data of the target message flow by using the other network board links;
if not, directly using other network links to transmit the second part of data of the target message flow.
In one manner, in the process of controlling the target mesh board link to transmit the first portion of data of the target packet stream, the embodiment of the present application may transmit the first portion of data according to a certain period (a period may be a fixed time interval, for example, 10 ms, or a fixed number of packets, for example, 100 packet streams, etc.).
Further, in the embodiment of the present application, if it is detected that the other mesh board links are parameter other message flows in the current period, it is required to transmit the second portion of data of the target message flow by the mesh board links after the current message flow is transmitted first, and then to the next transmission period.
For example, in the embodiment of the present application, the network board link a with the smallest port buffer may be selected first for transmission, then the other network board links B with the smallest port buffer may be selected again for transmission in the next period, if the port is the same as the previous one, the other streams are directly transmitted, if the port is different, the other streams are transmitted first, and when the next period is reached, the other network board links B transmit until it is determined that all the target message streams are transmitted completely.
In one manner, the embodiment of the application may calculate the transmission delay of the last packet stream based on the buffer depth of the current SFC, so as to calculate the transmission completion time point of the packet stream packet reaching the destination (the transmission completion time point is calculated by the sum of the initial time point and the transmission delay). And after the transmission is finished, the message stream is sent. Or when the SFC buffer depth of the current message is larger than that of the previous message, the current message is sent.
As an example, the transmission completion time point may be calculated and added by the source end of the packet stream sender. As another example, the source also needs to add a flow ID field for each packet flow.
Optionally, in another embodiment based on the method described above, before transmitting the second portion of data of the target packet stream by using the other network link, the method further includes:
obtaining buffer occupancy indexes of all the corresponding ports of the screen plate links in the chip;
and taking the network board links lower than the second threshold value in all the buffer occupancy indexes as other network board links.
Optionally, in another embodiment based on the above method of the present application, the method further comprises:
if the total bandwidth flow of the target mesh board link is determined to be capable of supporting the distributed target message flow, the target mesh board link is utilized to complete all data transmission of the target message flow.
Optionally, in another embodiment of the method according to the present application, the allocating a packet flow to a corresponding one of the mesh links by using a preset allocation policy includes:
sequentially generating matching identifiers for each message stream based on stream data information corresponding to each message stream, wherein one matching identifier corresponds to one network board link;
Each message flow is allocated to a network link corresponding to the matching identifier.
Optionally, in another embodiment based on the above method of the present application, the matching identifier is a hash value.
In one manner, in order to allocate different message flows to corresponding mesh board links, the embodiment of the present application may generate a matching identifier for each message flow based on the flow data information of the message. It will be appreciated that the matching identification is used for the selection of network links.
As an example, the stream data information may be 5-tuple information of the message stream, and the matching identification may be a hash value.
In one manner, the embodiment of the present application may obtain 5-tuple information (including, for example, source IP, destination IP, source port, destination port, protocol number) of each packet flow or other fields of the packet flow to distinguish, and assign 1 hash value to each flow after identifying each flow, for selecting a network link. For example as shown in table 1 below:
table 1:
it can be appreciated that since the hash value of each message stream is different, it can be shared to different mesh links. In one mode, if the number of message flows is increased again, the cyclic allocation based on the number of network links can be continued.
For example as shown in table 2 below:
table 2:
stream identification Flow rate Hash value
Stream 1 33G 0
Stream 2 33G 1
Stream 3 33G 2
Stream 4 5G 0
Stream 5 5G 1
Further, as shown in fig. 4, the chip includes a wired card LC0, a wired card net LC1, and 3 net SFC0, SFC1, SF2, and the total bandwidth flow of each net link is 40G.
When the chip receives 3 message flows and the flow rate of each message flow is 33G, then according to the above allocation policy, flow 1 may be allocated to SFC0, flow 2 may be allocated to SFC1, flow 3 may be allocated to SFC2, so that the 3 message flows are received by LC0 first, and each of the 3 message flows is transmitted to LC1 through its allocated network links, such as the middle passes through SFC0, SFC1, SF 2.
In another manner, as shown in fig. 5, a flow chart of a method for service processing according to an embodiment of the present application is shown, where the method includes:
and step 1, when the line card board is determined to receive the message flows, sequentially generating a matching identifier for each message flow based on the flow data information corresponding to each message flow.
Wherein a matching identity corresponds to a mesh link. As an example, the matching identifier may be a hash value.
And step 2, detecting whether the total bandwidth flow of the target mesh board link is lower than the flow rate corresponding to the target message flow, and determining whether the target mesh board link supports the target message flow. Then, step 3a and step 3b are performed.
And 3a, detecting that the total bandwidth flow of the target mesh board link is higher than the flow rate corresponding to the target message flow, determining that the total bandwidth flow of the target mesh board link can support the allocated target message flow, and completing all data transmission of the target message flow by utilizing the target mesh board link.
And 3b, when the total bandwidth flow of the target mesh board link is detected to be lower than the flow rate corresponding to the target message flow, determining that the target mesh board link cannot support the target message flow.
Obtaining a buffer occupancy index of a corresponding port of a target network board link, wherein the buffer occupancy index corresponds to the buffer quantity of a message stream and/or the buffer data size of the message stream;
if the buffer occupancy index is detected to be higher than the first threshold value, determining that the total bandwidth flow of the target network board link is lower than the flow rate corresponding to the target message flow.
In an optional manner, if the buffer occupancy index is detected to be higher than a limit threshold value, the target network board link is instructed to discard the target message flow, wherein the limit threshold value is higher than the first threshold value.
And 4b, selecting other network plate links for the target message flow after detecting that the first partial data of the target message flow is transmitted by using the target network plate links.
Wherein the target mesh board link is any one mesh board link in the chip.
In one manner, in the process of selecting other network board links, the embodiments of the present application may execute the following steps:
obtaining buffer occupancy indexes of all the corresponding ports of the screen plate links in the chip;
and taking the network board links lower than the second threshold value in all the buffer occupancy indexes as other network board links.
And 5b, detecting whether other network board links currently transmit other message flows. And then enters 6b1 or 6b2.
And step 6b1, if yes, after determining that the other network board links have transmitted other message flows, transmitting second part of data of the target message flow by using the other network board links. Step 7b is then performed.
And step 6b2, if not, directly transmitting the second partial data of the target message flow by using other network plate links. Step 7b is then performed.
And 7b, if all the data of the target message stream are not transmitted, continuing to execute the step of selecting other network plate links until all the data of the target message stream are determined to be transmitted.
By applying the technical scheme, after the chip receives the message stream, on one hand, one network board link is responsible for transmitting the message stream to the destination end, so that the problem of data disorder caused by different arrival time of each sub-stream at the opposite end due to splitting the message stream into a plurality of sub-streams and transmitting the sub-streams by different network board links is avoided. On the other hand, when the chip detects that the total bandwidth of the mesh board link cannot independently support the transmission of the message stream, after the mesh board link finishes transmitting part of the data of the message stream, other mesh board links are selected to transmit other part of the data of the message stream. Therefore, the technical scheme for prohibiting the simultaneous transmission of the same message stream by the multi-network-board link is realized, so that the time for each sub-stream of the message stream to reach the opposite end is ensured not to be disordered, and the problem of disordered data of the message stream is further avoided.
Optionally, in another embodiment of the present application, as shown in fig. 6, the present application further provides a service processing apparatus. Applied to a chip, comprising:
the allocation module 201 is configured to allocate a message flow to a corresponding network board link by using a preset allocation policy when it is determined that the line card board receives the message flow;
a detection module 202, configured to select other mesh board links for the target message stream after detecting that the total bandwidth flow of the target mesh board links cannot support the allocated target message stream and that the target mesh board links are used for transmitting the first part of data of the target message stream, where the target mesh board links are any one mesh board link in the chip;
and the transmission module 203 is configured to transmit a second portion of data of the target packet stream by using the other mesh board links until it is determined that all data of the target packet stream are transmitted, where the second portion of data is data adjacent to the first portion of data and not transmitted in the target packet stream.
By applying the technical scheme, after the chip receives the message stream, on one hand, one network board link is responsible for transmitting the message stream to the destination end, so that the problem of data disorder caused by different arrival time of each sub-stream at the opposite end due to splitting the message stream into a plurality of sub-streams and transmitting the sub-streams by different network board links is avoided. On the other hand, when the chip detects that the total bandwidth of the mesh board link cannot independently support the transmission of the message stream, after the mesh board link finishes transmitting part of the data of the message stream, other mesh board links are selected to transmit other part of the data of the message stream. Therefore, the technical scheme for prohibiting the simultaneous transmission of the same message stream by the multi-network-board link is realized, so that the time for each sub-stream of the message stream to reach the opposite end is ensured not to be disordered, and the problem of disordered data of the message stream is further avoided. The method has the defect of slower recovery time of the storage system.
In another embodiment of the present application, the detection module 202 is configured to:
and when the total bandwidth flow of the target mesh board link is detected to be lower than the flow rate corresponding to the target message flow, determining that the target mesh board link cannot support the target message flow.
In another embodiment of the present application, the detection module 202 is configured to:
obtaining a buffer occupancy index belonging to a corresponding port of the target network board link, wherein the buffer occupancy index corresponds to the buffer quantity of the message stream and/or the buffer data size of the message stream;
and if the buffer occupancy index is detected to be higher than a first threshold value, determining that the total bandwidth flow of the target network board link is lower than the flow rate corresponding to the target message flow.
In another embodiment of the present application, the detection module 202 is configured to:
and if the buffer occupancy index is detected to be higher than a limit threshold value, indicating the target network board link to discard the target message flow, wherein the limit threshold value is higher than the first threshold value.
In another embodiment of the present application, the detection module 202 is configured to:
detecting whether other message flows are transmitted by the links of the other network boards currently;
If yes, after determining that the other network board links have transmitted the other message flows, transmitting second partial data of the target message flows by using the other network board links;
if not, directly transmitting the second part of data of the target message flow by using the other network board links.
In another embodiment of the present application, the detection module 202 is configured to:
obtaining buffer occupancy indexes of all the corresponding ports of the screen plate links in the chip;
and taking the network board links lower than the second threshold value in all the buffer occupancy indexes as the other network board links.
In another embodiment of the present application, the detection module 202 is configured to:
and if the total bandwidth flow of the target mesh board link is determined to be capable of supporting the allocated target message flow, completing all data transmission of the target message flow by utilizing the target mesh board link.
In another embodiment of the present application, the detection module 202 is configured to:
sequentially generating matching identifiers for each message stream based on stream data information corresponding to each message stream, wherein one matching identifier corresponds to one network board link;
each message flow is allocated to a network link corresponding to the matching identifier.
In another embodiment of the present application, the detection module 202 is configured to:
the matching identifier is a hash value.
The embodiment of the application also provides electronic equipment for executing the business processing method. Referring to fig. 7, a schematic diagram of an electronic device according to some embodiments of the present application is shown. As shown in fig. 7, the electronic apparatus 3 includes: a processor 300, a memory 301, a bus 302 and a communication interface 303, the processor 300, the communication interface 303 and the memory 301 being connected by the bus 302; the memory 301 stores a computer program executable on the processor 300, and the processor 300 executes the method for processing services provided in any of the foregoing embodiments of the present application when the computer program is executed.
The memory 301 may include a high-speed random access memory (RAM: random Access Memory), and may further include a non-volatile memory (non-volatile memory), such as at least one magnetic disk memory. The communication connection between the device network element and at least one other network element is achieved through at least one communication interface 303 (which may be wired or wireless), the internet, a wide area network, a local network, a metropolitan area network, etc. may be used.
Bus 302 may be an ISA bus, a PCI bus, an EISA bus, or the like. The buses may be classified as address buses, data buses, control buses, etc. The memory 301 is configured to store a program, and the processor 300 executes the program after receiving an execution instruction, and the video transmission method disclosed in any of the foregoing embodiments of the present application may be applied to the processor 300 or implemented by the processor 300.
The processor 300 may be an integrated circuit chip having signal processing capabilities. In implementation, the steps of the above method may be performed by integrated logic circuits of hardware in the processor 300 or by instructions in the form of software. The processor 300 may be a general-purpose processor, including a processor (Central Processing Unit, CPU for short), a network processor (Network Processor, NP for short), etc.; but may also be a Digital Signal Processor (DSP), application Specific Integrated Circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware components. The disclosed methods, steps, and logic blocks in the embodiments of the present application may be implemented or performed. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The steps of a method disclosed in connection with the embodiments of the present application may be embodied directly in hardware, in a decoded processor, or in a combination of hardware and software modules in a decoded processor. The software modules may be located in a random access memory, flash memory, read only memory, programmable read only memory, or electrically erasable programmable memory, registers, etc. as well known in the art. The storage medium is located in the memory 301, and the processor 300 reads the information in the memory 301, and in combination with its hardware, performs the steps of the above method.
The electronic device provided by the embodiment of the application and the method for processing the service provided by the embodiment of the application are the same in the invention conception, and have the same beneficial effects as the method adopted, operated or implemented by the electronic device.
It is to be understood that the present application is not limited to the precise arrangements and instrumentalities shown in the drawings, which have been described above, and that various modifications and changes may be effected without departing from the scope thereof. The scope of the application is limited only by the appended claims.

Claims (13)

1. A method for processing services, applied to a chip, comprising:
when the line card board is determined to receive the message flow, distributing one message flow to a corresponding network board link by utilizing a preset distribution strategy;
if the total bandwidth flow of the target mesh board link is determined to be incapable of supporting the distributed target message flow, selecting other mesh board links for the target message flow after detecting that the first partial data of the target message flow is transmitted by using the target mesh board link, wherein the target mesh board link is any mesh board link in the chip;
and transmitting second partial data of the target message stream by using the other network board links until all data of the target message stream are determined to be transmitted, wherein the second partial data are adjacent to the first partial data and are not transmitted in the target message stream.
2. The method of claim 1, wherein determining that the total bandwidth traffic of the target mesh plate link cannot support the allocated target packet flow comprises:
and when the total bandwidth flow of the target mesh board link is detected to be lower than the flow rate corresponding to the target message flow, determining that the target mesh board link cannot support the target message flow.
3. The method of claim 2, wherein the detecting that the total bandwidth traffic of the target mesh board link is lower than the corresponding flow rate of the target packet flow comprises:
obtaining a buffer occupancy index belonging to a corresponding port of the target network board link, wherein the buffer occupancy index corresponds to the buffer quantity of the message stream and/or the buffer data size of the message stream;
and if the buffer occupancy index is detected to be higher than a first threshold value, determining that the total bandwidth flow of the target network board link is lower than the flow rate corresponding to the target message flow.
4. A method as claimed in claim 3, wherein the method further comprises:
and if the buffer occupancy index is detected to be higher than a limit threshold value, indicating the target network board link to discard the target message flow, wherein the limit threshold value is higher than the first threshold value.
5. The method of claim 1, wherein transmitting the second portion of the data of the target message stream using the other mesh link comprises:
detecting whether other message flows are transmitted by the links of the other network boards currently;
if yes, after determining that the other network board links have transmitted the other message flows, transmitting second partial data of the target message flows by using the other network board links;
if not, directly transmitting the second part of data of the target message flow by using the other network board links.
6. The method of claim 5, wherein the determining that the other mesh link has completed transmitting the other message stream comprises:
calculating the transmission delay of the other network board links for transmitting the other message streams based on the buffer occupancy indexes of the other network board links; acquiring an initial time point of the other network board links for transmitting the other message streams last time;
and when the current time point is detected to be later than the transmission finishing time point, determining that the other network plate links are transmitted to finish the other message flows, wherein the transmission finishing time point is the time point after the transmission delay from the initial time point.
7. The method of claim 1 or 5, further comprising, prior to said transmitting the second portion of the data of the target message stream using the other mesh link:
obtaining buffer occupancy indexes of all the corresponding ports of the screen plate links in the chip;
and taking the network board links lower than the second threshold value in all the buffer occupancy indexes as the other network board links.
8. The method of claim 1, wherein the method further comprises:
and if the total bandwidth flow of the target mesh board link is determined to be capable of supporting the allocated target message flow, completing all data transmission of the target message flow by utilizing the target mesh board link.
9. The method of claim 1, wherein the allocating a packet flow to a corresponding one of the mesh links using a preset allocation policy comprises:
sequentially generating matching identifiers for each message stream based on stream data information corresponding to each message stream, wherein one matching identifier corresponds to one network board link;
each message flow is allocated to a network link corresponding to the matching identifier.
10. The method of claim 9, wherein the match identification is a hash value.
11. A device for processing services, applied to a chip, comprising:
the distribution module is configured to distribute one message stream to a corresponding network board link by utilizing a preset distribution strategy when the line card board is determined to receive the message stream;
the detection module is configured to select other mesh board links for the target message stream after detecting that the first partial data of the target message stream is transmitted by using the target mesh board link if the total bandwidth flow of the target mesh board link cannot support the allocated target message stream, wherein the target mesh board link is any one mesh board link in the chip;
and the transmission module is configured to transmit second partial data of the target message stream by using the other network board links until all data of the target message stream are determined to be transmitted, wherein the second partial data is adjacent to the first partial data and is not transmitted in the target message stream.
12. An electronic device, comprising:
a memory for storing executable instructions; the method comprises the steps of,
a processor for executing the executable instructions with the memory to perform the operations of the method of business processing of any of claims 1-10.
13. A computer readable storage medium storing computer readable instructions which, when executed, perform the operations of the method of business processing of any of claims 1-10.
CN202311518663.8A 2023-11-13 2023-11-13 Service processing method, device, electronic equipment and medium Pending CN117527933A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311518663.8A CN117527933A (en) 2023-11-13 2023-11-13 Service processing method, device, electronic equipment and medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311518663.8A CN117527933A (en) 2023-11-13 2023-11-13 Service processing method, device, electronic equipment and medium

Publications (1)

Publication Number Publication Date
CN117527933A true CN117527933A (en) 2024-02-06

Family

ID=89743333

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311518663.8A Pending CN117527933A (en) 2023-11-13 2023-11-13 Service processing method, device, electronic equipment and medium

Country Status (1)

Country Link
CN (1) CN117527933A (en)

Similar Documents

Publication Publication Date Title
US11799764B2 (en) System and method for facilitating efficient packet injection into an output buffer in a network interface controller (NIC)
US7257633B2 (en) Dynamic allocation of a pool of threads
US20070053294A1 (en) Network load balancing apparatus, systems, and methods
CN108432194B (en) Congestion processing method, host and system
US10545896B2 (en) Service acceleration method and apparatus
CN112753198B (en) Load balancing and message reordering method and device in network
CN107015942B (en) Method and device for multi-core CPU (Central processing Unit) packet sending
KR101609288B1 (en) Data processing method of noc without buffer and noc electronic element
WO2016206513A1 (en) Method of boosting data processing, and assignment device and switch utilizing same
US10291540B2 (en) Method and apparatus for performing a weighted queue scheduling using a set of fairness factors
CN110768976B (en) Message processing method, device and network equipment
US20200127936A1 (en) Dynamic scheduling method, apparatus, and system
CN110602001A (en) Far-end loopback testing device and method
CN107896196B (en) Method and device for distributing messages
CN117459462A (en) Network load balancing method and device
CN109714269B (en) Data processing method and network equipment
CN117527933A (en) Service processing method, device, electronic equipment and medium
CN110336759B (en) RDMA (remote direct memory Access) -based protocol message forwarding method and device
CN110808909B (en) Message processing method and device across virtual systems
CN112131154A (en) DMA transmission control method for dynamically matching channel and service
CN113691459A (en) Data transmission method and device based on identification message
US20190356404A1 (en) Relay device
CN108123990B (en) Data storage method, data storage system and data processing equipment
WO2022147762A1 (en) Data packet sequencing method and apparatus
US20220103250A1 (en) Fault protection method, device, and system for optical network

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination