CN104065465A - Message retransmitting method, request end, response end and system - Google Patents

Message retransmitting method, request end, response end and system Download PDF

Info

Publication number
CN104065465A
CN104065465A CN201410250643.1A CN201410250643A CN104065465A CN 104065465 A CN104065465 A CN 104065465A CN 201410250643 A CN201410250643 A CN 201410250643A CN 104065465 A CN104065465 A CN 104065465A
Authority
CN
China
Prior art keywords
message
error message
sequence number
described error
under
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201410250643.1A
Other languages
Chinese (zh)
Other versions
CN104065465B (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.)
Huawei Technologies Co Ltd
Original Assignee
Huawei 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 Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN201410250643.1A priority Critical patent/CN104065465B/en
Publication of CN104065465A publication Critical patent/CN104065465A/en
Application granted granted Critical
Publication of CN104065465B publication Critical patent/CN104065465B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Abstract

The invention discloses a message retransmitting method, a request end, a response end and a system. The message retransmitting method comprises the steps that a plurality of data queues are sent to the response end, each data queue comprises at least one piece of information, and the information comprises at least one message; error reporting information sent by the response end is obtained; deviation values are obtained according to the error reporting information, and a deviation address of an initial message, relative to the information which the error messages belong to, of the error messages is obtained according to the deviation values; an initial storing address of the error messages is located according to queue numbers of the data queues and serial numbers of the information which the error messages belong to; the initial storing address of the error messages is located according to the deviation address and the initial storing address of the information which the error messages belong to, and the messages are retransmitted to the response end from the initial storing address of the error messages. The message retransmitting method, the request end, the response end and the system are used when message transmission goes wrong and the error messages are retransmitted and have the advantages of being short in time delay and easy to operate.

Description

Method, request end, responder and system that a kind of message retransmits
Technical field
The present invention relates to the communications field, relate in particular to method, request end, responder and system that a kind of message retransmits.
Background technology
RDMA (Remote Direct Memory Access, the access of far-end immediate data) technology is for the transfer of data between network server, in data transmission procedure, the network interface card with RDMA function of request end server is directly transferred to data the memory block of responder server through network by zero reproduction technology.In concrete implementation procedure, responder server may receive because of a variety of causes error in data or overtime reception data.In this case, need request end server again to transmit data to responder server, i.e. data re-transmission, because data are transmitted with message form, retransmits therefore data re-transmission is called again message.
The method that message retransmits is at present, request end server need to be report for the first time civilian sequence number be kept at list item of each each Message Record for the data queue of transmitting, in the time that sending error messages, reads responder server the civilian sequence number of reporting for the first time from list item, by the sequence number of the error message in civilian sequence number and error messages of reporting for the first time is contrasted, obtain the offset address of error message memory address, and then the position of definite message re-transmission beginning, carry out message re-transmission.But, for example, support when larger (256K~1M) of data queue and each data queue concurrent message more (for example 16K) time, described list item will expend huge storage resources (being 16K*256K~16K*1M bits).Obviously, large like this list item hardware storage device is difficult to bear, and be placed on hardware storage device and be unfavorable for expansion, therefore the method is put into above-mentioned list item in the internal memory of host server conventionally, need request end server in above-mentioned internal memory, to increase this contents in table while sending a message at every turn like this, while receiving the error messages that responder server sends, need to from above-mentioned internal memory, read this contents in table, increase the complexity of time delay and operation.
Summary of the invention
Method, request end, responder and system that the embodiment of the present invention provides a kind of message to retransmit, while retransmitting error message, reduce time delay and improve ease-to-operate for makeing mistakes in message transmission.
In order to solve the problems of the technologies described above, a kind of method that embodiment of the present invention first aspect provides message to retransmit, comprising:
Send multiple data queues to responder, described data queue comprises at least one message, and described message comprises at least one message, and the length of described message is fixed, and all messages that described data queue comprises are all serial numbers;
Obtain the error messages that described responder sends, described error messages comprises sequence number for the obtaining described error message sequence number with respect to message under the queue number of the data queue of message under the information of the deviant of the civilian sequence number of reporting for the first time of message under described error message, described error message and described error message;
According to described for obtaining the sequence number of described error message with respect to deviant described in the information acquisition of the deviant of the civilian sequence number of reporting for the first time of message under described error message, and according to the product of the length of described deviant and described message, obtain the report for the first time civilian offset address of described error message with respect to message under described error message;
According to the sequence number of message under the queue number of described data queue and described error message, orient the initial memory address of the affiliated message of described error message, wherein, under the queue number of described data queue and described error message, under the sequence number of message and described error message, between the initial memory address of message, there is corresponding relation;
Initial memory address according to described error message with respect to message under report for the first time civilian offset address and the described error message of message under described error message, orient the initial memory address of described error message, and retransmit message from the initial memory address of described error message to described responder, wherein, the initial memory address of the affiliated message of described error message is the civilian initial memory address of reporting for the first time of the affiliated message of described error message.
In the one possibility implementation of first aspect, described for obtaining the information of the sequence number of described error message with respect to the deviant of the civilian sequence number of reporting for the first time of message under described error message, specifically comprise:
The civilian sequence number of reporting for the first time of message under the sequence number of described error message and described error message;
Described in described basis, for obtaining the sequence number of described error message with respect to deviant described in the information acquisition of the deviant of the civilian sequence number of reporting for the first time of message under described error message, specifically comprise:
According to the civilian sequence number of reporting for the first time of message under the sequence number of described error message and described error message, calculate the sequence number of described error message with respect to the deviant of the civilian sequence number of reporting for the first time of message under described error message, the sequence number of described error message be the civilian sequence number of reporting for the first time taking message under described error message as radix, the numerical value counting to get according to a definite sequence.
A kind of method that embodiment of the present invention second aspect provides message to retransmit, comprising:
Receive multiple data queues that request end sends, described data queue comprises at least one message, and described message comprises at least one message, and the length of described message is fixed, and all messages that described data queue comprises are all serial numbers;
Error message detected the message comprising from described data queue time, generate error messages and described error messages is sent to described request end, described error messages comprises sequence number for the obtaining described error message information with respect to the deviant of the civilian sequence number of reporting for the first time of message under described error message, the sequence number of message under the queue number of the data queue of message and described error message under described error message, wherein, under the queue number of described data queue and described error message, under the sequence number of message and described error message, between the initial memory address of message, there is corresponding relation, so that described request end calculates the report for the first time civilian offset address of described error message with respect to message under described error message according to the product of the length of described deviant and described message, and orient the initial memory address of message under described error message according to the sequence number of message under the queue number of described data queue and described error message, thereby orient the initial memory address of described error message according to the initial memory address of described offset address and described error message, and then start to retransmit message from the initial memory address of described error message.
In the one possibility implementation of second aspect, while error message being detected the described message comprising from described data queue, generate error messages and described error messages is sent to described request end, described error messages comprises sequence number for the obtaining described error message information with respect to the deviant of the civilian sequence number of reporting for the first time of message under described error message, comprising:
If error message detected the message comprising from described data queue, generate error messages and described error messages is sent to described request end, described error messages comprises the sequence number of described error message and the civilian sequence number of reporting for the first time of the affiliated message of described error message, so that described request end calculates described deviant according to the civilian sequence number of reporting for the first time of message under the sequence number of described error message and described error message, the sequence number of described error message is that the civilian sequence number of reporting for the first time taking message under described error message is as radix, the numerical value counting to get according to a definite sequence.
The embodiment of the present invention third aspect provide a kind of message retransmit request end, comprising:
Sending module, for send multiple data queues to responder, described data queue comprises at least one message, and described message comprises at least one message, and the length of described message is fixed, and all messages that described data queue comprises are all serial numbers;
Acquisition module, for obtaining the error messages that described responder sends, described error messages comprises sequence number for the obtaining described error message sequence number with respect to message under the queue number of the data queue of message under the information of the deviant of the civilian sequence number of reporting for the first time of message under described error message, described error message and described error message;
Described acquisition module also for according to described for obtaining the sequence number of described error message with respect to deviant described in the information acquisition of the deviant of the civilian sequence number of reporting for the first time of message under described error message, and according to the product of the length of described deviant and described message, obtain the report for the first time civilian offset address of described error message with respect to message under described error message;
Locating module, be used for according to the sequence number of message under the queue number of described data queue and described error message, orient the initial memory address of the affiliated message of described error message, wherein, under the queue number of described data queue and described error message, under the sequence number of message and described error message, between the initial memory address of message, there is corresponding relation;
Described locating module is also for the initial memory address with respect to message under report for the first time civilian offset address and the described error message of message under described error message according to described error message, orient the initial memory address of described error message, and retransmit message from the initial memory address of described error message to described responder, wherein, the initial memory address of the affiliated message of described error message is the civilian initial memory address of reporting for the first time of the affiliated message of described error message.
In the one possibility implementation of the third aspect, described for obtaining the information of the sequence number of described error message with respect to the deviant of the civilian sequence number of reporting for the first time of message under described error message, specifically comprise:
The civilian sequence number of reporting for the first time of message under the sequence number of described error message and described error message;
Described acquisition module for according to described for obtaining the sequence number of described error message with respect to described in the information acquisition of the deviant of the civilian sequence number of reporting for the first time of message under described error message when deviant, specifically for according to the civilian sequence number of reporting for the first time of message under the sequence number of described error message and described error message, calculate the sequence number of described error message with respect to the deviant of the civilian sequence number of reporting for the first time of message under described error message, the sequence number of described error message is that the civilian sequence number of reporting for the first time taking message under described error message is as radix, the numerical value counting to get according to a definite sequence.
The responder that embodiment of the present invention fourth aspect provides a kind of message to retransmit, comprising:
Receiver module, the multiple data queues that send for receiving request end, described data queue comprises at least one message, described message comprises at least one message, the length of described message is fixed, and all messages that described data queue comprises are all serial numbers;
Message transmission module, for in the time that the message comprising from described data queue detects error message, generate error messages and described error messages is sent to described request end, described error messages comprises sequence number for the obtaining described error message message with respect to the deviant of the civilian sequence number of reporting for the first time of message under described error message, the sequence number of message under the queue number of the data queue of message and described error message under described error message, wherein, under the queue number of described data queue and described error message, under the sequence number of message and described error message, between the initial memory address of message, there is corresponding relation, so that described request end according to described for obtaining the sequence number of described error message with respect to deviant described in the information acquisition of the deviant of the civilian sequence number of reporting for the first time of message under described error message, and calculate the report for the first time civilian offset address of described error message with respect to message under described error message according to the product of the length of described deviant and described message, described request end is oriented the initial memory address of message under described error message according to the sequence number of message under the queue number of described data queue and described error message, and then orient the initial memory address of described error message according to the initial memory address of message under described offset address and described error message, start to retransmit message from described initial memory address.
In the one possibility implementation of fourth aspect, described message transmission module is in the time that the message comprising from described data queue detects error message, generate error messages and described error messages is sent to described request end, described error messages comprises the sequence number of described error message and the civilian sequence number of reporting for the first time of the affiliated message of described error message, so that described request end calculates described deviant according to the civilian sequence number of reporting for the first time of message under the sequence number of described error message and described error message, the sequence number of described error message is that the civilian sequence number of reporting for the first time taking message under described error message is as radix, the numerical value counting to get according to a definite sequence.
The system that the embodiment of the present invention the 5th aspect provides a kind of message to retransmit, described system comprise that the third aspect provides request end, and fourth aspect provide responder, wherein:
Described request end is for sending multiple data queues to described responder, described data queue comprises at least one message, described message comprises at least one message, and the length of described message is fixed, and all messages that described data queue comprises are all serial numbers;
Multiple data queues that described responder sends for receiving described request end, and detect described data queue; While error message being detected the message comprising from described data queue, generate error messages;
Described request end is oriented the initial memory address of described error message according to described error messages, and retransmits message from the initial memory address of described error message to described responder.
Implement the embodiment of the present invention, there is following beneficial effect: if error message detected in the message of the data queue that the responder of the embodiment of the present invention sends in request end, generate error messages and error messages is sent to request end, request end obtains deviant from error messages, and obtain the error message offset address civilian with respect to reporting for the first time of message under error message according to deviant, and from error messages, obtain the sequence number of message under the queue number of data queue and error message, and orient the initial memory address of message under error message according to the sequence number of message under the queue number of data queue and error message, request end and then orient the initial memory address of error message according to the initial memory address of message under offset address and error message, and retransmit message from initial memory address to responder, realize sending out to stagger the time at message and retransmit the function of error message, when the technical scheme that adopts inventive embodiments to provide is carried out error message re-transmission, there is time delay feature little and simple to operate.
Brief description of the drawings
In order to be illustrated more clearly in the embodiment of the present invention or technical scheme of the prior art, to the accompanying drawing of required use in embodiment or description of the Prior Art be briefly described below, apparently, accompanying drawing in the following describes is only some embodiments of the present invention, for those of ordinary skill in the art, do not paying under the prerequisite of creative work, can also obtain according to these accompanying drawings other accompanying drawing.
Fig. 1 is the schematic flow sheet of the method that retransmits of a kind of message that the embodiment of the present invention provides;
Fig. 2 is the schematic flow sheet of the method that retransmits of another kind of message that the embodiment of the present invention provides;
Fig. 3 is the schematic flow sheet of the method that retransmits of another message that the embodiment of the present invention provides;
Fig. 4 is the structural representation of the request end that retransmits of a kind of message that the embodiment of the present invention provides;
Fig. 5 is the structural representation of the responder that retransmits of a kind of message that the embodiment of the present invention provides;
Fig. 6 is the structural representation of the system that retransmits of a kind of message that the embodiment of the present invention provides;
Fig. 7 is the schematic diagram of the RDMA transmission network of a kind of simplification of providing of the embodiment of the present invention;
Fig. 8 is a kind of message of providing of the embodiment of the present invention and the schematic diagram of corresponding message;
Fig. 9 is the schematic diagram of a kind of error messages of providing of the embodiment of the present invention;
Figure 10 is the schematic diagram of the another kind of error messages that provides of the embodiment of the present invention;
Figure 11 is the another kind of message that provides of the embodiment of the present invention and the schematic diagram of corresponding message;
Figure 12 is the schematic diagram of a kind of error messages containing message number and queue number of providing of the embodiment of the present invention;
Figure 13 is the schematic diagram of the another kind that provides of the embodiment of the present invention containing the error messages of message number and queue number;
Figure 14 is the structural representation of the request end that retransmits of another kind of message that the embodiment of the present invention provides;
Figure 15 is the structural representation of the responder that retransmits of another kind of message that the embodiment of the present invention provides.
Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is clearly and completely described, obviously, described embodiment is only the present invention's part embodiment, instead of whole embodiment.Based on the embodiment in the present invention, those of ordinary skill in the art, not making the every other embodiment obtaining under creative work prerequisite, belong to the scope of protection of the invention.
The method that a kind of message that the embodiment of the present invention provides retransmits, can be applied to the message transmission between server in network, particularly for the message transmission between server under RDMA (Remote Direct Memory Access, the access of far-end immediate data) technology.Wherein, described RDMA technology is a kind of zero reproduction technology that by network, data is directly transferred to the memory block of destination server.Thereby RDMA technology has reduced the operation copying with text exchange, liberate the internal memory of current server and the load of CPU (Central ProcessingUnit, CPU), reduce the delay of data processing between server.
Fig. 1 is the schematic flow sheet of a kind of method that in the embodiment of the present invention, message retransmits.The flow process of the method that the message in the present embodiment retransmits as shown in the figure can comprise:
S101, sends multiple data queues to responder, and described data queue comprises at least one message, and described message comprises at least one message, and the length of described message is fixed, and all messages that described data queue comprises are all serial numbers.
Refer to the schematic diagram of the RDMA transmission network of a kind of simplification as shown in Figure 7, the RDMA transmission network of simplification at least comprises CPU, HCA (Host Direct Memory Access, host side channel adapter) and memory bar.CPU is for issuing dispatching command to HCA, and HCA is for sending message by network to opposite end HCA, and memory bar is for storing message.In whole message transmitting process, CPU can not carry out the operation of copy message, only needs to control HCA and directly sends a message to opposite end HCA, and then message is deposited in to the memory space of opposite end memory bar.
Described responder is responder server, the message sending for receiving request end (being request end server).Whether identically it is pointed out that RDMA transmission network can be prejudged mechanism and the agreement of HCA of request end and responder, if identical, just carry out following steps.
Concrete, request end sends multiple data queues through network to responder, and described data queue comprises at least one message, and described message comprises at least one message.Wherein, described data queue is shown in QP in Fig. 7 (Queue Pair, queue to), and QP0 and QP1 are respectively and send out, receive data queue, and QP0 and QP1 form a data queue pair, and data queue is set up at two ends can send message after to data queue.It is to be noted, in process of transmitting, message is split as at least one message, the length of described message is fixed, and is MTU (Maximum Transmission Unit, MTU) value, and all messages that described data queue comprises are all serial numbers, the frame head of each message records its corresponding sequence number, i.e. PSN (Packet Sequence Number, sequence of message number).
S102, obtains the error messages that described responder sends, and described error messages comprises sequence number for the obtaining described error message information with respect to the deviant of the civilian sequence number of reporting for the first time of message under described error message.
Described error message at least comprises following three kinds: packet loss or send the message of overtime message, unexpected message and unripe memory address, wherein packet loss or send overtime message and unexpected message is common error message.Optionally, for these two kinds of common error messages, the detection method of responder can be: the sequence number that judges the message in the message whether sequence number of more previous message increases progressively by default queueing discipline, if not, judge that message is as error message.For example: suppose that described default queueing discipline is for increasing progressively successively 1, refer to the schematic diagram of a kind of message as shown in Figure 8 and corresponding message, if the PSN=13 of current message expection, but PSN ≠ 13 of the actual message receiving (as:=25), do not increase progressively compared with the PSN (=12) of previous message, judge that current message is as error message, and the PSN=13 of error message, the PSN that is error message be the civilian sequence number of reporting for the first time taking message under error message as radix, the numerical value counting to get according to a definite sequence.
Further, if responder detects error message, send NAK (NegativeAcknowledge to request end, error messages), otherwise, receiving after one or more correct messages, send ACK (Acknowledge, correct response message) to request end.Wherein, in the time error message being detected, responder can (be after message cutting is message according to the literary composition of reporting for the first time of message under the PSN of error message and error message, first message of message queue) PSN send NAK, the information of the deviant that NAK comprises sequence number for the obtaining error message sequence number civilian with respect to reporting for the first time of message under error message.For example, as shown in Figure 8, responder detects after error message, records the PSN (as:=13) of error message and the civilian PSN (as:=10) that reports for the first time, and sends NAK in wherein a kind of mode of two kinds of execution modes below:
Mode one, directly the PSN of error message (=13) and the civilian PSN (=10) that reports for the first time are recorded in NAK, it is the civilian sequence number of reporting for the first time of message under the NAK sequence number that comprises error message and error message, the schematic diagram of a kind of error messages as shown in Figure 9, wherein, PSNe is the PSN of error message, the PSN of message headed by PSNf;
Mode two, calculate the deviant △ PSN (as: △ PSN=13-10=3) of the PSN of error message and the civilian PSN that reports for the first time, again △ PSN is recorded in NAK, be the deviant of the NAK sequence number that the comprises error message sequence number civilian with respect to reporting for the first time of message under error message, the schematic diagram of another kind of error messages as shown in figure 10.
Further, in both implementation procedures of mode one and mode two, responder can carry the PSN of error message in the consensus standard form PSN territory of NAK, in the reservation territory of NAK, carry the civilian PSN that reports for the first time of message under error message simultaneously, on the contrary, responder also can carry the civilian PSN that reports for the first time of message under error message in the consensus standard form PSN territory of NAK, carries the PSN of error message simultaneously in the reservation territory of NAK.It is pointed out that above-mentioned implementation procedure all can with traditional scheme compatibility, when simultaneously privately owned docking, also can improve accuracy.
Especially, responder also records the sequence number of message under error message, i.e. MSN (Message Sequence Number, message SN), and the queue number of data queue, No. QP in NAK.For example, refer to the schematic diagram of another kind of message as shown in figure 11 and corresponding message, responder is found, after error message, QP0 and MSN=3 to be also recorded in NAK.Accordingly, the content of NAK can be as shown in Figure 12 or Figure 13.Concrete, request end obtains the NAK that responder sends.
S103, according to described for obtaining the sequence number of described error message with respect to deviant described in the information acquisition of the deviant of the civilian sequence number of reporting for the first time of message under described error message, and according to the product of the length of described deviant and described message, obtain the report for the first time civilian offset address of described error message with respect to message under described error message.
Concrete, on the one hand, if NAK only carries the PSN of error message and the civilian PSN that reports for the first time, request end obtains the deviant △ PSN of the PSN of error message and the civilian PSN that reports for the first time by calculatings so, wherein the PSN-of the △ PSN=error message civilian PSN that reports for the first time.On the other hand, if NAK has carried the deviant △ PSN of the PSN of error message and the civilian PSN that reports for the first time, request end directly obtains this △ PSN value.
Described memory address is the physical address of packet storage at the memory bar of request end.Concrete, request end can obtain according to the product of the length of deviant △ PSN and message (being preset MTU value) offset address of error message.It is offset address=△ PSN*MTU value.
S104, according to the sequence number of message under the queue number of described data queue and described error message, orients the initial memory address of the affiliated message of described error message.
Concrete, the NAK that directly send from responder request end, obtain the sequence number that comprises message under the queue number of the data queue of message under error message and error message, between initial memory address due to message under the sequence number of message under the queue number of data queue and error message and error message, there is corresponding relation, the initial memory address of message under error message can be oriented according to the sequence number of message under the queue number of data queue and error message in request end, and specific implementation process repeats no more here.
S105, initial memory address according to described error message with respect to message under report for the first time civilian offset address and the described error message of message under described error message, orient the initial memory address of described error message, and retransmit message from the initial memory address of described error message to described responder, wherein, the initial memory address of the affiliated message of described error message is the civilian initial memory address of reporting for the first time of the affiliated message of described error message.
Concrete, because the initial memory address of message under error message is the civilian initial memory address of reporting for the first time of message under error message, request end can be according to the initial memory address of message under offset address and error message and initial memory address alignment error message, be the initial memory address+offset address of the affiliated message of initial memory address=error message of error message, and retransmit message from the initial memory address of error message to responder.
If error message detected in the message of the data queue that the responder of the embodiment of the present invention sends in request end, generate error messages and error messages is sent to request end, request end obtains deviant from error messages, and obtain the error message offset address civilian with respect to reporting for the first time of message under error message according to deviant, and from error messages, obtain the sequence number of message under the queue number of data queue and error message, and orient the initial memory address of message under error message according to the sequence number of message under the queue number of data queue and error message, request end and then orient the initial memory address of error message according to the initial memory address of message under offset address and error message, and retransmit message from the initial memory address of error message to responder, compared to existing technology, request end not be used in this locality and sets up any list item and deposit the message information having sent, also saved the process of inquiry and contrast message information simultaneously, under the condition that ensures accuracy, improve efficiency, reduce the time delay of request end.
Fig. 2 is the schematic flow sheet of the method that in the embodiment of the present invention, another kind of message retransmits, and can comprise:
S201, request end sends multiple data queues to responder, and described data queue comprises at least one message, and described message comprises at least one message.
Refer to the schematic diagram of the RDMA transmission network of a kind of simplification as shown in Figure 7, the RDMA transmission network of simplification at least comprises CPU, HCA (Host Direct Memory Access, host side channel adapter) and memory bar.CPU is for issuing dispatching command to HCA, and HCA is for sending message by network to opposite end HCA, and memory bar is for storing message.In whole message transmitting process, CPU can not carry out the operation of copy message, only needs to control HCA and directly sends a message to opposite end HCA, and then message is deposited in to the memory space of opposite end memory bar.
Described responder is responder server, the message sending for receiving request end (being request end server).Whether identically it is pointed out that RDMA transmission network can be prejudged mechanism and the agreement of HCA of request end and responder, if identical, just carry out following steps.
Concrete, request end sends multiple data queues through network to responder, and described data queue comprises at least one message, and described message comprises at least one message.Wherein, described data queue is shown in QP in Fig. 7 (Queue Pair, queue to), and QP0 and QP1 are respectively and send out, receive data queue, and QP0 and QP1 form a data queue pair, and data queue is set up at two ends can send message after to data queue.It is to be noted, in process of transmitting, message is split as at least one message, the length of described message is fixed, and is MTU (Maximum Transmission Unit, MTU) value, and all messages that described data queue comprises are all serial numbers, the frame head of each message records its corresponding sequence number, i.e. PSN (Packet Sequence Number, sequence of message number).
S202, when responder detects error message the message comprising from described data queue, generates error messages.
Concrete, when the message of responder in receipt message, detect and obtain error message.
It is to be noted, described error message at least comprises following three kinds: packet loss or send the message of overtime message, unexpected message and unripe memory address, wherein packet loss or send overtime message and unexpected message is common error message.Optionally, for these two kinds of common error messages, the detection method of responder can be: the sequence number that judges the message in the message whether sequence number of more previous message increases progressively by default queueing discipline, if not, judge that message is as error message.For example: suppose that described default queueing discipline is for increasing progressively successively 1, refer to the schematic diagram of a kind of message as shown in Figure 8 and corresponding message, if the PSN=13 of current message expection, but PSN ≠ 13 of the actual message receiving (as:=25), do not increase progressively compared with the PSN (=12) of previous message, judge that current message is as error message, and the PSN=13 of error message,, the PSN of error message be the civilian sequence number of reporting for the first time taking message under error message as radix, the numerical value counting to get according to a definite sequence.
Further, if responder detects error message, send NAK (NegativeAcknowledge to request end, error messages), otherwise, receiving after one or more correct messages, send ACK (Acknowledge, correct response message) to request end.Wherein, in the time error message being detected, responder can be recorded to the PSN of error message (as:=13) and the civilian PSN (as:=10) that reports for the first time in NAK, the schematic diagram of a kind of error messages as shown in Figure 9, wherein, PSNe is the PSN of error message, the PSN of message headed by PSNf.
Further, in implementation procedure, responder can carry the PSN of error message in the consensus standard form PSN territory of NAK, in the reservation territory of NAK, carry the civilian PSN that reports for the first time of message under error message simultaneously, on the contrary, responder also can carry the civilian PSN that reports for the first time of message under error message in the consensus standard form PSN territory of NAK, carries the PSN of error message simultaneously in the reservation territory of NAK.It is pointed out that above-mentioned implementation procedure all can with traditional scheme compatibility, when simultaneously privately owned docking, also can improve accuracy.
In addition, responder also need record the sequence number of message under error message, i.e. MSN (Message Sequence Number, message SN), and the queue number of data queue, No. QP in NAK.For example, refer to the schematic diagram of another kind of message as shown in figure 11 and corresponding message, wherein, responder is found, after error message, QP0 and MSN=3 to be also recorded in NAK, and the content of NAK as shown in figure 12.
S203, described error messages is sent to described request end by responder, and described error messages comprises the queue number of data queue and the sequence number of the affiliated message of described error message of the sequence number of described error message, the civilian sequence number of reporting for the first time of the affiliated message of described error message, the affiliated message of described error message.
Concrete, responder sends to request end by carrying MSN and the right NAK of No. QP of queue of message under the PSN of error message, report for the first time civilian PSN, error message.
S204, request end, according to the civilian sequence number of reporting for the first time of message under the sequence number of described error message and described error message, calculates the sequence number of described error message with respect to the deviant of the civilian sequence number of reporting for the first time of message under described error message.
Concrete, request end obtains the deviant △ PSN of the PSN of error message and the civilian PSN that reports for the first time by calculatings, wherein, and the PSN-of the △ PSN=error message civilian PSN that reports for the first time.
S205, request end, according to the product of the length of described deviant and described message, obtains the report for the first time civilian offset address of described error message with respect to message under described error message.
Described memory address is the physical address of packet storage at the memory bar of request end.Concrete, request end can obtain according to the product of the length of deviant △ PSN and message (being preset MTU value) offset address of error message.It is offset address=△ PSN*MTU value.
S206, request end obtains the sequence number of message under the queue number of the data queue of message under described error message and described error message from described error messages.
Concrete, the NAK that directly send from responder request end, obtain the sequence number that comprises message under the queue number of the data queue of message under error message and error message.
S207, the initial memory address of the affiliated message of described error message, according to the sequence number of message under the queue number of described data queue and described error message, is oriented in request end.
Concrete, between initial memory address due to message under the sequence number of message under the queue number of data queue and error message and error message, there is corresponding relation, the initial memory address of message under error message can be oriented according to the sequence number of message under the queue number of data queue and error message in request end, and specific implementation process repeats no more here.
S208, request end is the initial memory address with respect to message under report for the first time civilian offset address and the described error message of message under described error message according to described error message, orient the initial memory address of described error message, and retransmit message from the initial memory address of described error message to described responder.
Concrete, because the initial memory address of message under error message is the civilian initial memory address of reporting for the first time of message under error message, request end can be according to offset address and initial memory address and initial memory address alignment error message, be the initial memory address+offset address of the affiliated message of initial memory address=error message of error message, and retransmit message from the initial memory address of error message to responder.
If error message detected in the message of the data queue that the responder of the embodiment of the present invention sends in request end, generate error messages and error messages is sent to request end, request end calculates deviant according to the civilian sequence number of reporting for the first time of message under the sequence number of the error message in error message and error message, calculate the error message offset address civilian with respect to reporting for the first time of message under error message according to the product of the length of deviant and message again, and orient the initial memory address of message under error message according to the sequence number of message under the queue number of data queue and error message, and then orient the initial memory address of error message according to the initial memory address of message under offset address and error message, thereby start to retransmit message from the initial memory address of error message, realize sending out to stagger the time at message and retransmit the function of error message, and there is time delay feature little and simple to operate.
Fig. 3 is the schematic flow sheet of the method that in the embodiment of the present invention, another message retransmits, and can comprise:
S301, request end sends multiple data queues to responder, and described data queue comprises at least one message, and described message comprises at least one message.Step S301 is identical with the content of the step S201 in Fig. 2, repeats no more here.
S302, when responder detects error message the message comprising from described data queue, according to the civilian sequence number of reporting for the first time of message under the sequence number of described error message and described error message, calculate the sequence number of described error message with respect to the deviant of civilian sequence number of reporting for the first time of message under described error message, and generate error messages.
Concrete, when the message of responder in receipt message, detect and obtain error message.
It is to be noted, described error message at least comprises following three kinds: packet loss or send the message of overtime message, unexpected message and unripe memory address, wherein packet loss or send overtime message and unexpected message is common error message.Optionally, for these two kinds of common error messages, the detection method of responder can be: the sequence number that judges the message in the message whether sequence number of more previous message increases progressively by default queueing discipline, if not, judge that message is as error message.For example: suppose that described default queueing discipline is for increasing progressively successively 1, refer to the schematic diagram of a kind of message as shown in Figure 8 and corresponding message, if the PSN=13 of current message expection, but PSN ≠ 13 of the actual message receiving (as:=25), do not increase progressively compared with the PSN (=12) of previous message, judge that current message is as error message, and the PSN=13 of error message, the PSN that is error message be the civilian sequence number of reporting for the first time taking message under error message as radix, the numerical value counting to get according to a definite sequence.
If responder detects error message, send NAK (Negative Acknowledge, error messages) to request end, otherwise, receiving after one or more correct messages, sending ACK (Acknowledge, correct response message) to request end.
Concrete, in the time error message being detected, responder can calculate the PSN of error message and the deviant △ PSN (as: △ PSN=13-10=3) of civilian PSN that reports for the first time, then △ PSN is recorded in NAK to the schematic diagram of another kind of error messages as shown in figure 10.
In addition, responder also need record the sequence number of message under error message, i.e. MSN (Message Sequence Number, message SN), and the queue number of record data queue in NAK, No. QP in NAK.For example, refer to the schematic diagram of another kind of message as shown in figure 11 and corresponding message, wherein, responder is found, after error message, QP0 and MSN=3 to be also recorded in NAK, and the content of NAK as shown in figure 12.
Further, in implementation procedure, responder can carry the PSN of error message in the consensus standard form PSN territory of NAK, in the reservation territory of NAK, carry the civilian PSN that reports for the first time of message under error message simultaneously, on the contrary, responder also can carry the civilian PSN that reports for the first time of message under error message in the consensus standard form PSN territory of NAK, carries the PSN of error message simultaneously in the reservation territory of NAK.It is pointed out that above-mentioned implementation procedure all can with traditional scheme compatibility, when simultaneously privately owned docking, also can improve accuracy.
S303, described error messages is sent to described request end by responder, and the sequence number that described error messages comprises described error message is with respect to the sequence number of message under the queue number of the data queue of message under the deviant of the civilian sequence number of reporting for the first time of message under described error message, described error message and described error message.
Concrete, responder sends to request end by carrying MSN and the right NAK of No. QP of queue of message under deviant △ PSN, error message.
S304, request end is according to deviant described in described error messages information acquisition.
Concrete, request end directly obtains deviant △ PSN from NAK.
S305, request end, according to the product of the length of described deviant and described message, obtains the report for the first time civilian offset address of described error message with respect to message under described error message.
Described memory address is the physical address that error message is stored in the memory bar of request end.Concrete, request end can obtain according to the product of the length of deviant △ PSN and message (being preset MTU value) offset address of error message.It is offset address=△ PSN*MTU value.
S306, request end obtains the sequence number of message under the queue number of the data queue of message under described error message and described error message from described error messages.
Concrete, the NAK that directly send from responder request end, obtain the sequence number that comprises message under the queue number of the data queue of message under error message and error message.
S307, the initial memory address of the affiliated message of described error message, according to the sequence number of message under the queue number of described data queue and described error message, is oriented in request end.
Concrete, between initial memory address due to message under the sequence number of message under the queue number of data queue and error message and error message, there is corresponding relation, the initial memory address of message under error message can be oriented according to the sequence number of message under the queue number of data queue and error message in request end, and specific implementation process repeats no more here.
S308, request end is the initial memory address with respect to message under report for the first time civilian offset address and the described error message of message under described error message according to described error message, orient the initial memory address of described error message, and retransmit message from the initial memory address of described error message to described responder.
Concrete, because the initial memory address of message under error message is the civilian initial memory address of reporting for the first time of message under error message, request end can be according to the initial memory address of message under offset address and error message and initial memory address alignment error message, be the initial memory address+offset address of the affiliated message of initial memory address=error message of error message, and retransmit message from the initial memory address of error message to responder.
If error message detected in the message of the data queue that the responder of the embodiment of the present invention sends in request end, generate error messages and error messages is sent to request end, request end obtains the deviant in error message and calculates the error message offset address civilian with respect to reporting for the first time of message under error message according to the product of the length of deviant and message, orient again the initial memory address of message under error message according to the sequence number of message under the queue number of data queue and error message, and then orient the initial memory address of error message according to the initial memory address of message under offset address and error message, thereby start to retransmit message from the initial memory address of error message, realize sending out to stagger the time at message and retransmit the function of error message, and there is time delay feature little and simple to operate.
Fig. 4 is the request end that in the embodiment of the present invention, a kind of message retransmits.Request end in the embodiment of the present invention at least can comprise sending module 410, acquisition module 420 and locating module 430 as shown in the figure, wherein:
Sending module 410, for sending multiple data queues to responder, described data queue comprises at least one message, and described message comprises at least one message, the length of described message is fixed, and all messages that described data queue comprises are all serial numbers.
Refer to the schematic diagram of the RDMA transmission network of a kind of simplification as shown in Figure 7, the RDMA transmission network of simplification at least comprises CPU, HCA (Host Direct Memory Access, host side channel adapter) and memory bar.CPU is for issuing dispatching command to HCA, and HCA is for sending message by network to opposite end HCA, and memory bar is for storing message.In whole message transmitting process, CPU can not carry out the operation of copy message, only needs to control HCA and directly sends a message to opposite end HCA, and then message is deposited in to the memory space of opposite end memory bar.
Concrete, sending module 410 sends multiple data queues through network to responder, and described data queue comprises at least one message, and described message comprises at least one message.Wherein, described data queue shown in QP in Fig. 7 (Queue Pair, queue to), QP0 and a data queue of QP1 composition, two ends can send message after setting up data queue.It is to be noted, in process of transmitting, message is split as at least one message, the length of described message is fixed, and is MTU (Maximum Transmission Unit, MTU) value, and all messages that described data queue comprises are all serial numbers, the frame head of each message records its corresponding sequence number, i.e. PSN (Packet Sequence Number, sequence of message number).
Acquisition module 420, for obtaining the error messages that described responder sends, described error messages comprises sequence number for the obtaining described error message sequence number with respect to message under the queue number of the data queue of message under the information of the deviant of the civilian sequence number of reporting for the first time of message under described error message, described error message and described error message.
Described error message at least comprises following three kinds: packet loss or send the message of overtime message, unexpected message and unripe memory address, wherein packet loss or send overtime message and unexpected message is common error message.Optionally, for these two kinds of common error messages, the detection method of responder can be: the sequence number that judges the message in the message whether sequence number of more previous message increases progressively by default queueing discipline, if not, judge that message is as error message.For example: suppose that described default queueing discipline is for increasing progressively successively 1, refer to the schematic diagram of a kind of message as shown in Figure 8 and corresponding message, if the PSN=13 of current message expection, but PSN ≠ 13 of the actual message receiving (as:=25), do not increase progressively compared with the PSN (=12) of previous message, judge that current message is as error message, and the PSN=13 of error message, the PSN that is error message be the civilian sequence number of reporting for the first time taking message under error message as radix, the numerical value counting to get according to a definite sequence.
Further, if responder detects error message, send NAK (NegativeAcknowledge to request end, error messages), otherwise, receiving after one or more correct messages, send ACK (Acknowledge, correct response message) to request end.Wherein, in the time error message being detected, responder can (be after message cutting is message according to the literary composition of reporting for the first time of message under the PSN of error message and error message, first message of message queue) PSN send NAK, the information of the deviant that NAK comprises sequence number for the obtaining error message sequence number civilian with respect to reporting for the first time of message under error message.For example, as shown in Figure 8, responder detects after error message, records the PSN (as:=13) of error message and the civilian PSN (as:=10) that reports for the first time, and sends NAK in wherein a kind of mode of two kinds of execution modes below:
Mode one, is directly recorded to the PSN of error message (=13) and the civilian PSN (=10) that reports for the first time in NAK, the schematic diagram of a kind of error messages as shown in Figure 9, wherein, the PSN that PSNe is error message, the PSN of message headed by PSNf;
Mode two, calculates the PSN of error message and the deviant △ PSN (as: △ PSN=13-10=3) of civilian PSN that reports for the first time, then △ PSN is recorded in NAK to the schematic diagram of another kind of error messages as shown in figure 10.
Further, in both implementation procedures of mode one and mode two, responder can carry the PSN of error message in the consensus standard form PSN territory of NAK, in the reservation territory of NAK, carry the civilian PSN that reports for the first time of message under error message simultaneously, on the contrary, responder also can carry the civilian PSN that reports for the first time of message under error message in the consensus standard form PSN territory of NAK, carries the PSN of error message simultaneously in the reservation territory of NAK.It is pointed out that above-mentioned implementation procedure all can with traditional scheme compatibility, when simultaneously privately owned docking, also can improve accuracy.
Especially, responder also records the sequence number of message under error message, i.e. MSN (Message Sequence Number, message SN), and the queue number of data queue, No. QP in NAK.For example, refer to the schematic diagram of another kind of message as shown in figure 11 and corresponding message, responder is found, after error message, QP0 and MSN=3 to be also recorded in NAK.Accordingly, the content of NAK can be as shown in Figure 12 or Figure 13.
Concrete, acquisition module 420 obtains the NAK that responder sends according to the civilian PSN that reports for the first time of message under the PSN of error message and error message.
Described acquisition module 420 also for according to described for obtaining the sequence number of described error message with respect to deviant described in the information acquisition of the deviant of the civilian sequence number of reporting for the first time of message under described error message, and according to the product of the length of described deviant and described message, obtain the report for the first time civilian offset address of described error message with respect to message under described error message.
Concrete, on the one hand, if NAK has carried the deviant △ PSN of the PSN of error message and the civilian PSN that reports for the first time, acquisition module 420 is for obtaining △ PSN value from NAK.On the other hand, if NAK only carries the PSN of error message and the civilian PSN that reports for the first time, acquisition module 420 calculates deviant △ PSN for the civilian sequence number of reporting for the first time according to message under the sequence number of error message and error message so, wherein the PSN-of the △ PSN=error message civilian PSN that reports for the first time.
Described memory address is the physical address of packet storage at the memory bar of request end.Concrete, acquisition module 420 can obtain according to the product of the length of deviant △ PSN and message (being preset MTU value) offset address of error message.It is offset address=△ PSN*MTU value.
Locating module 430, be used for according to the sequence number of message under the queue number of described data queue and described error message, orient the initial memory address of the affiliated message of described error message, wherein, under the queue number of described data queue and described error message, under the sequence number of message and described error message, between the initial memory address of message, there is corresponding relation.
Concrete, the NAK that locating module 430 directly sends from responder, obtain the sequence number that comprises message under the queue number of the data queue of message under error message and error message, between initial memory address due to message under the sequence number of message under the queue number of data queue and error message and error message, there is corresponding relation, locating module 430 can be oriented according to the sequence number of message under the queue number of data queue and error message the initial memory address of message under error message, and specific implementation process repeats no more here.
Described locating module 430 is also for the initial memory address with respect to message under report for the first time civilian offset address and the described error message of message under described error message according to described error message, orient the initial memory address of described error message, and retransmit message from the initial memory address of described error message to described responder, wherein, the initial memory address of the affiliated message of described error message is the civilian initial memory address of reporting for the first time of the affiliated message of described error message.
Concrete, because the initial memory address of message under error message is the civilian initial memory address of reporting for the first time of message under error message, described locating module 430 can be according to the initial memory address of message under offset address and error message and initial memory address alignment error message, be the initial memory address+offset address of the affiliated message of initial memory address=error message of error message, and retransmit message from the initial memory address of error message to responder.
Fig. 5 is the responder that a kind of message that the embodiment of the present invention provides retransmits.Responder in the embodiment of the present invention at least can comprise data queue's receiver module 510 and message transmission module 520 as shown in the figure, wherein:
Receiver module 510, the multiple data queues that send for receiving request end, described data queue comprises at least one message, described message comprises at least one message, the length of described message is fixed, and all messages that described data queue comprises are all serial numbers.
Refer to the schematic diagram of the RDMA transmission network of a kind of simplification as shown in Figure 7, the RDMA transmission network of simplification at least comprises CPU, HCA (Host Direct Memory Access, host side channel adapter) and memory bar.CPU is for issuing dispatching command to HCA, and HCA is for sending message by network to opposite end HCA, and memory bar is for storing message.In whole message transmitting process, CPU can not carry out the operation of copy message, only needs to control HCA and directly sends a message to opposite end HCA, and then message is deposited in to the memory space of opposite end memory bar.
Concrete, receiver module 510 receives multiple data queues that send through network request end, and described data queue comprises at least one message, and described message comprises at least one message.Wherein, described data queue shown in QP in Fig. 7 (Queue Pair, queue to), QP0 and a data queue of QP1 composition, two ends can send message after setting up data queue.It is pointed out that in process of transmitting, message is split as at least one message, and the frame head of each message records its corresponding sequence number, i.e. PSN (PacketSequence Number, sequence of message number).
Message transmission module 520, for in the time that the message comprising from described data queue detects error message, generate error messages and described error messages is sent to described request end, described error messages comprises sequence number for the obtaining described error message message with respect to the deviant of the civilian sequence number of reporting for the first time of message under described error message, the sequence number of message under the queue number of the data queue of message and described error message under described error message, wherein, under the queue number of described data queue and described error message, under the sequence number of message and described error message, between the initial memory address of message, there is corresponding relation, so that described request end calculates the report for the first time civilian offset address of described error message with respect to message under described error message according to the product of the length of described deviant and described message, and orient the initial memory address of message under described error message according to the sequence number of message under the queue number of described data queue and described error message, and then orient the initial memory address of described error message according to the initial memory address of message under described offset address and described error message, thereby start to retransmit message from the initial memory address of described error message.
Described error message at least comprises following three kinds: packet loss or send the message of overtime message, unexpected message and unripe memory address, wherein packet loss or send overtime message and unexpected message is common error message.Concrete, for these two kinds of common error messages, the sequence number that message transmission module 520 judges the message in the message whether sequence number of more previous message increases progressively by default queueing discipline, if the sequence number that the sequence number of discovery message is not more previous message increases progressively by default queueing discipline, judge that this message is as described error message.For example: suppose that described default queueing discipline is for increasing progressively successively 1, refer to the schematic diagram of a kind of message as shown in Figure 8 and corresponding message, if the PSN=13 of current message expection, but PSN ≠ 13 of the actual message receiving (as:=25), do not increase progressively compared with the PSN (=12) of previous message, judge that current message is as error message, and the PSN=13 of error message, the PSN that is error message be the civilian sequence number of reporting for the first time taking message under error message as radix, the numerical value counting to get according to a definite sequence.
Further, in the time that message transmission module 520 is obtained error message, message transmission module 520 can (be after message cutting is message according to the literary composition of reporting for the first time of message under the PSN of error message and error message, first message of message queue) PSN send NAK (Negative Acknowledge, error messages).Optionally, message transmission module 520 sends NAK in wherein a kind of mode of two kinds of execution modes below:
Mode one, directly the PSN of error message (=13) and the civilian PSN (=10) that reports for the first time are recorded in NAK, it is the civilian sequence number of reporting for the first time of message under the NAK sequence number that comprises error message and error message, the schematic diagram of a kind of error messages as shown in Figure 9, wherein, PSNe is the PSN of error message, the PSN of message headed by PSNf;
Mode two, calculate the deviant △ PSN (as: △ PSN=13-10=3) of the PSN of error message and the civilian PSN that reports for the first time, again △ PSN is recorded in NAK, be the deviant of the NAK sequence number that the comprises error message sequence number civilian with respect to reporting for the first time of message under error message, the schematic diagram of another kind of error messages as shown in figure 10.
Further, request end obtains the initial memory address of error message according to NAK, and then starts to retransmit message from described initial memory address.Wherein, the method that request end obtains the initial memory address of error message according to NAK refers to the embodiment in Fig. 4, repeats no more here.
Fig. 6 is the structural representation of the system that in the embodiment of the present invention, a kind of message retransmits.The system that message in the embodiment of the present invention retransmits as shown in the figure at least can comprise request end 61 and responder 62, wherein:
Described request end 61 is as request end described in conjunction with Figure 4 above, for sending multiple data queues to responder 62, described data queue comprises at least one message, described message comprises at least one message, the length of described message is fixed, and all messages that described data queue comprises are all serial numbers;
Described responder 62 is as responder described in conjunction with Figure 6 above, the multiple data queues that send for receiving described request end 61, and detect described data queue; While error message being detected the message comprising from described data queue, generate error messages;
Described request end 61 is oriented the initial memory address of described error message according to described error messages, and retransmits message from the initial memory address of described error message to described responder 62.
Figure 14 is the structural representation of the request end of the another kind of message re-transmission in the embodiment of the present invention, as shown in figure 14, this request end can comprise: at least one processor 701, for example CPU, at least one communication bus 702, host side channel adapter 703 and memory 704.Wherein, communication bus 702 is for realizing the connection communication between these assemblies.Host side channel adapter 703 is for by request end access network.Memory 704 can be RAM (Random Access Memory, zero access) memory, can be also NVM (Non-Volatile Memory, non-volatile) memory, for example at least one magnetic disc store.Memory 704 can also be the storage device away from aforementioned processing device 701, for example at least one memory bar.In memory 704, stored batch processing code, and processor 701 is carried out following operation for the program code of storing according to memory:
Send multiple data queues to responder, described data queue comprises at least one message, and described message comprises at least one message, and the length of described message is fixed, and all messages that described data queue comprises are all serial numbers;
Obtain the error messages that described responder sends, described error messages comprises sequence number for the obtaining described error message sequence number with respect to message under the queue number of the data queue of message under the information of the deviant of the civilian sequence number of reporting for the first time of message under described error message, described error message and described error message;
According to described for obtaining the sequence number of described error message with respect to deviant described in the information acquisition of the deviant of the civilian sequence number of reporting for the first time of message under described error message, and according to the product of the length of described deviant and described message, obtain the report for the first time civilian offset address of described error message with respect to message under described error message;
According to the sequence number of message under the queue number of described data queue and described error message, orient the initial memory address of the affiliated message of described error message, wherein, under the queue number of described data queue and described error message, under the sequence number of message and described error message, between the initial memory address of message, there is corresponding relation;
Initial memory address according to described error message with respect to message under report for the first time civilian offset address and the described error message of message under described error message, orient the initial memory address of described error message, and retransmit message from the initial memory address of described error message to described responder, wherein, the initial memory address of the affiliated message of described error message is the civilian initial memory address of reporting for the first time of the affiliated message of described error message.
Optionally, if described error messages carries the sequence number of described error message and the civilian sequence number of reporting for the first time of the affiliated message of described error message, described processor 701 according to described for obtaining the sequence number of described error message with respect to the concrete operations of deviant described in the information acquisition of the deviant of the civilian sequence number of reporting for the first time of message under described error message can be:
According to the civilian sequence number of reporting for the first time of message under the sequence number of described error message and described error message, calculate the sequence number of described error message with respect to the deviant of the civilian sequence number of reporting for the first time of message under described error message, the sequence number of described error message be the civilian sequence number of reporting for the first time taking message under described error message as radix, the numerical value counting to get according to a definite sequence.
Figure 15 is the structural representation of the responder of the another kind of message re-transmission in the embodiment of the present invention, as shown in figure 15, this responder can comprise: at least one processor 801, for example CPU, at least one communication bus 802, host side channel adapter 803 and memory 804.Wherein, communication bus 802 is for realizing the connection communication between these assemblies.Host side channel adapter 803 is for by responder access network.Memory 804 can be RAM (Random Access Memory, zero access) memory, can be also NVM (Non-Volatile Memory, non-volatile) memory, for example at least one magnetic disc store.Memory 804 can also be the storage device away from aforementioned processing device 801, for example at least one memory bar.In memory 804, stored batch processing code, and processor 801 is carried out following operation for the program code of storing according to memory:
Receive multiple data queues that request end sends, described data queue comprises at least one message, and described message comprises at least one message, and the length of described message is fixed, and all messages that described data queue comprises are all serial numbers;
Error message detected the message comprising from described data queue time, generate error messages and described error messages is sent to described request end, described error messages comprises sequence number for the obtaining described error message information with respect to the deviant of the civilian sequence number of reporting for the first time of message under described error message, the sequence number of message under the queue number of the data queue of message and described error message under described error message, wherein, under the queue number of described data queue and described error message, under the sequence number of message and described error message, between the initial memory address of message, there is corresponding relation, so that described request end calculates the report for the first time civilian offset address of described error message with respect to message under described error message according to the product of the length of described deviant and described message, and orient the initial memory address of message under described error message according to the sequence number of message under the queue number of described data queue and described error message, thereby orient the initial memory address of described error message according to the initial memory address of message under described offset address and described error message, and then start to retransmit message from the initial memory address of described error message.
Optionally, the error messages that processor 801 sends can also comprise the sequence number of described error message and the civilian sequence number of reporting for the first time of the affiliated message of described error message, so that described request end calculates described deviant according to the civilian sequence number of reporting for the first time of message under the sequence number of described error message and described error message, the sequence number of described error message be the civilian sequence number of reporting for the first time taking message under described error message as radix, the numerical value counting to get according to a definite sequence.
The embodiment of the present invention has also proposed a kind of computer-readable storage medium, and described computer-readable storage medium has program stored therein, and described program comprises the part or all of step of the embodiment of the present invention in conjunction with the method for the described message re-transmission of Fig. 1~Fig. 3 while execution.
If error message detected in the message of the data queue that the responder of the embodiment of the present invention sends in request end, generate error messages and error messages is sent to request end, request end obtains deviant from error messages, and obtain the error message offset address civilian with respect to reporting for the first time of message under error message according to deviant, and from error messages, obtain the sequence number of message under the queue number of data queue and error message, and orient the initial memory address of message under error message according to the sequence number of message under the queue number of data queue and error message, request end and then orient the initial memory address of error message according to the initial memory address of message under offset address and error message, and retransmit message from initial memory address to responder, realize sending out to stagger the time at message and retransmit the function of error message, and there is time delay feature little and simple to operate.
One of ordinary skill in the art will appreciate that all or part of flow process realizing in above-described embodiment method, can carry out the hardware that instruction is relevant by computer program to complete, described program can be stored in a computer read/write memory medium, this program, in the time carrying out, can comprise as the flow process of the embodiment of above-mentioned each side method.Wherein, described storage medium can be magnetic disc, CD, read-only store-memory body (Read-Only Memory, ROM) or random store-memory body (Random Access Memory, RAM) etc.
Above disclosed is only preferred embodiment of the present invention, certainly can not limit with this interest field of the present invention, and the equivalent variations of therefore doing according to the claims in the present invention, still belongs to the scope that the present invention is contained.

Claims (9)

1. the method that message retransmits, is characterized in that, described method comprises:
Send multiple data queues to responder, described data queue comprises at least one message, and described message comprises at least one message, and the length of described message is fixed, and all messages that described data queue comprises are all serial numbers;
Obtain the error messages that described responder sends, described error messages comprises sequence number for the obtaining described error message sequence number with respect to message under the queue number of the data queue of message under the information of the deviant of the civilian sequence number of reporting for the first time of message under described error message, described error message and described error message;
According to described for obtaining the sequence number of described error message with respect to deviant described in the information acquisition of the deviant of the civilian sequence number of reporting for the first time of message under described error message, and according to the product of the length of described deviant and described message, obtain the report for the first time civilian offset address of described error message with respect to message under described error message;
According to the sequence number of message under the queue number of described data queue and described error message, orient the initial memory address of the affiliated message of described error message, wherein, under the queue number of described data queue and described error message, under the sequence number of message and described error message, between the initial memory address of message, there is corresponding relation;
Initial memory address according to described error message with respect to message under report for the first time civilian offset address and the described error message of message under described error message, orient the initial memory address of described error message, and retransmit message from the initial memory address of described error message to described responder, wherein, the initial memory address of the affiliated message of described error message is the civilian initial memory address of reporting for the first time of the affiliated message of described error message.
2. message retransmission method according to claim 1, is characterized in that, described for obtaining the information of the sequence number of described error message with respect to the deviant of the civilian sequence number of reporting for the first time of message under described error message, specifically comprises:
The civilian sequence number of reporting for the first time of message under the sequence number of described error message and described error message;
Described in described basis, for obtaining the sequence number of described error message with respect to deviant described in the information acquisition of the deviant of the civilian sequence number of reporting for the first time of message under described error message, specifically comprise:
According to the civilian sequence number of reporting for the first time of message under the sequence number of described error message and described error message, calculate the sequence number of described error message with respect to the deviant of the civilian sequence number of reporting for the first time of message under described error message, the sequence number of described error message be the civilian sequence number of reporting for the first time taking message under described error message as radix, the numerical value counting to get according to a definite sequence.
3. the method that message retransmits, is characterized in that, described method comprises:
Receive multiple data queues that request end sends, described data queue comprises at least one message, and described message comprises at least one message, and the length of described message is fixed, and all messages that described data queue comprises are all serial numbers;
Error message detected the message comprising from described data queue time, generate error messages and described error messages is sent to described request end, described error messages comprises sequence number for the obtaining described error message information with respect to the deviant of the civilian sequence number of reporting for the first time of message under described error message, the sequence number of message under the queue number of the data queue of message and described error message under described error message, wherein, under the queue number of described data queue and described error message, under the sequence number of message and described error message, between the initial memory address of message, there is corresponding relation, so that described request end calculates the report for the first time civilian offset address of described error message with respect to message under described error message according to the product of the length of described deviant and described message, and orient the initial memory address of message under described error message according to the sequence number of message under the queue number of described data queue and described error message, thereby orient the initial memory address of described error message according to the initial memory address of message under described offset address and described error message, and then start to retransmit message from the initial memory address of described error message.
4. the method that message according to claim 3 retransmits, it is characterized in that, while error message being detected the described message comprising from described data queue, generate error messages and described error messages is sent to described request end, described error messages comprises sequence number for the obtaining described error message information with respect to the deviant of the civilian sequence number of reporting for the first time of message under described error message, comprising:
If error message detected the message comprising from described data queue, generate error messages and described error messages is sent to described request end, described error messages comprises the sequence number of described error message and the civilian sequence number of reporting for the first time of the affiliated message of described error message, so that described request end calculates described deviant according to the civilian sequence number of reporting for the first time of message under the sequence number of described error message and described error message, the sequence number of described error message is that the civilian sequence number of reporting for the first time taking message under described error message is as radix, the numerical value counting to get according to a definite sequence.
5. the request end that message retransmits, is characterized in that, described request end comprises:
Sending module, for send multiple data queues to responder, described data queue comprises at least one message, and described message comprises at least one message, and the length of described message is fixed, and all messages that described data queue comprises are all serial numbers;
Acquisition module, for obtaining the error messages that described responder sends, described error messages comprises sequence number for the obtaining described error message sequence number with respect to message under the queue number of the data queue of message under the information of the deviant of the civilian sequence number of reporting for the first time of message under described error message, described error message and described error message;
Described acquisition module also for according to described for obtaining the sequence number of described error message with respect to deviant described in the information acquisition of the deviant of the civilian sequence number of reporting for the first time of message under described error message, and according to the product of the length of described deviant and described message, obtain the report for the first time civilian offset address of described error message with respect to message under described error message;
Locating module, be used for according to the sequence number of message under the queue number of described data queue and described error message, orient the initial memory address of the affiliated message of described error message, wherein, under the queue number of described data queue and described error message, under the sequence number of message and described error message, between the initial memory address of message, there is corresponding relation;
Described locating module is also for the initial memory address with respect to message under report for the first time civilian offset address and the described error message of message under described error message according to described error message, orient the initial memory address of described error message, and retransmit message from the initial memory address of described error message to described responder, wherein, the initial memory address of the affiliated message of described error message is the civilian initial memory address of reporting for the first time of the affiliated message of described error message.
6. request end according to claim 5, is characterized in that, described for obtaining the information of the sequence number of described error message with respect to the deviant of the civilian sequence number of reporting for the first time of message under described error message, specifically comprises:
The civilian sequence number of reporting for the first time of message under the sequence number of described error message and described error message;
Described acquisition module for according to described for obtaining the sequence number of described error message with respect to described in the information acquisition of the deviant of the civilian sequence number of reporting for the first time of message under described error message when deviant, specifically for according to the civilian sequence number of reporting for the first time of message under the sequence number of described error message and described error message, calculate the sequence number of described error message with respect to the deviant of the civilian sequence number of reporting for the first time of message under described error message, the sequence number of described error message is that the civilian sequence number of reporting for the first time taking message under described error message is as radix, the numerical value counting to get according to a definite sequence.
7. the responder that message retransmits, is characterized in that, described responder comprises:
Receiver module, the multiple data queues that send for receiving request end, described data queue comprises at least one message, described message comprises at least one message, the length of described message is fixed, and all messages that described data queue comprises are all serial numbers;
Message transmission module, for in the time that the message comprising from described data queue detects error message, generate error messages and described error messages is sent to described request end, described error messages comprises sequence number for the obtaining described error message message with respect to the deviant of the civilian sequence number of reporting for the first time of message under described error message, the sequence number of message under the queue number of the data queue of message and described error message under described error message, wherein, under the queue number of described data queue and described error message, under the sequence number of message and described error message, between the initial memory address of message, there is corresponding relation, so that described request end according to described for obtaining the sequence number of described error message with respect to deviant described in the information acquisition of the deviant of the civilian sequence number of reporting for the first time of message under described error message, and calculate the report for the first time civilian offset address of described error message with respect to message under described error message according to the product of the length of described deviant and described message, described request end is oriented the initial memory address of message under described error message according to the sequence number of message under the queue number of described data queue and described error message, and then orient the initial memory address of described error message according to the initial memory address of message under described offset address and described error message, start to retransmit message from the initial memory address of described error message.
8. responder according to claim 7, it is characterized in that, described message transmission module is in the time that the message comprising from described data queue detects error message, generate error messages and described error messages is sent to described request end, described error messages comprises the sequence number of described error message and the civilian sequence number of reporting for the first time of the affiliated message of described error message, so that described request end calculates described deviant according to the civilian sequence number of reporting for the first time of message under the sequence number of described error message and described error message, the sequence number of described error message is that the civilian sequence number of reporting for the first time taking message under described error message is as radix, the numerical value counting to get according to a definite sequence.
9. the system that message retransmits, is characterized in that, described system comprises request end as described in claim 5 or 6 and responder as claimed in claim 7 or 8, wherein:
Described request end is for sending multiple data queues to described responder, described data queue comprises at least one message, described message comprises at least one message, and the length of described message is fixed, and all messages that described data queue comprises are all serial numbers;
Multiple data queues that described responder sends for receiving described request end, and detect described data queue; While error message being detected the message comprising from described data queue, generate error messages;
Described request end is oriented the initial memory address of described error message according to described error messages, and retransmits message from the initial memory address of described error message to described responder.
CN201410250643.1A 2014-06-06 2014-06-06 A kind of method of message retransmission, request end, responder and system Active CN104065465B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410250643.1A CN104065465B (en) 2014-06-06 2014-06-06 A kind of method of message retransmission, request end, responder and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410250643.1A CN104065465B (en) 2014-06-06 2014-06-06 A kind of method of message retransmission, request end, responder and system

Publications (2)

Publication Number Publication Date
CN104065465A true CN104065465A (en) 2014-09-24
CN104065465B CN104065465B (en) 2018-03-16

Family

ID=51553013

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410250643.1A Active CN104065465B (en) 2014-06-06 2014-06-06 A kind of method of message retransmission, request end, responder and system

Country Status (1)

Country Link
CN (1) CN104065465B (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104394163A (en) * 2014-12-05 2015-03-04 浪潮电子信息产业股份有限公司 Security detection method based on Web application
CN111953655A (en) * 2017-02-28 2020-11-17 华为技术有限公司 Method and equipment for server to respond to request message in communication system
CN113055131A (en) * 2019-12-26 2021-06-29 阿里巴巴集团控股有限公司 Data processing method, data segmentation method, computing device and medium
CN113301103A (en) * 2021-02-05 2021-08-24 阿里巴巴集团控股有限公司 Data processing system, method and device
CN113300818A (en) * 2021-02-08 2021-08-24 阿里巴巴集团控股有限公司 Data transmission system and method
CN115296900A (en) * 2022-08-03 2022-11-04 北京天融信网络安全技术有限公司 Network message correction method and device, electronic equipment and storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050129045A1 (en) * 2003-12-11 2005-06-16 International Business Machines Corporation Limiting number of retransmission attempts for data transfer via network interface controller
US20060230119A1 (en) * 2005-04-08 2006-10-12 Neteffect, Inc. Apparatus and method for packet transmission over a high speed network supporting remote direct memory access operations
US20060274748A1 (en) * 2005-03-24 2006-12-07 Fujitsu Limited Communication device, method, and program
CN1890657A (en) * 2003-12-02 2007-01-03 国际商业机器公司 RDMA completion and retransmit system and method
CN101091318A (en) * 2003-12-11 2007-12-19 国际商业机器公司 Data transfer error checking
US20130262613A1 (en) * 2012-03-30 2013-10-03 Mark S. Hefty Efficient distribution of subnet administration data over an rdma network

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1890657A (en) * 2003-12-02 2007-01-03 国际商业机器公司 RDMA completion and retransmit system and method
US20050129045A1 (en) * 2003-12-11 2005-06-16 International Business Machines Corporation Limiting number of retransmission attempts for data transfer via network interface controller
CN101091318A (en) * 2003-12-11 2007-12-19 国际商业机器公司 Data transfer error checking
US20060274748A1 (en) * 2005-03-24 2006-12-07 Fujitsu Limited Communication device, method, and program
US20060230119A1 (en) * 2005-04-08 2006-10-12 Neteffect, Inc. Apparatus and method for packet transmission over a high speed network supporting remote direct memory access operations
US20130262613A1 (en) * 2012-03-30 2013-10-03 Mark S. Hefty Efficient distribution of subnet administration data over an rdma network

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104394163A (en) * 2014-12-05 2015-03-04 浪潮电子信息产业股份有限公司 Security detection method based on Web application
CN111953655A (en) * 2017-02-28 2020-11-17 华为技术有限公司 Method and equipment for server to respond to request message in communication system
CN111953655B (en) * 2017-02-28 2023-03-10 华为云计算技术有限公司 Method and equipment for server to respond to request message in communication system
CN113055131A (en) * 2019-12-26 2021-06-29 阿里巴巴集团控股有限公司 Data processing method, data segmentation method, computing device and medium
CN113055131B (en) * 2019-12-26 2023-06-30 阿里巴巴集团控股有限公司 Data processing method, data segmentation method, computing device and medium
CN113301103A (en) * 2021-02-05 2021-08-24 阿里巴巴集团控股有限公司 Data processing system, method and device
CN113301103B (en) * 2021-02-05 2024-03-12 阿里巴巴集团控股有限公司 Data processing system, method and device
CN113300818A (en) * 2021-02-08 2021-08-24 阿里巴巴集团控股有限公司 Data transmission system and method
CN115296900A (en) * 2022-08-03 2022-11-04 北京天融信网络安全技术有限公司 Network message correction method and device, electronic equipment and storage medium
CN115296900B (en) * 2022-08-03 2024-01-23 北京天融信网络安全技术有限公司 Network message correction method and device, electronic equipment and storage medium

Also Published As

Publication number Publication date
CN104065465B (en) 2018-03-16

Similar Documents

Publication Publication Date Title
CN104065465A (en) Message retransmitting method, request end, response end and system
CN111786748B (en) Data retransmission method and system, network card, device, server and storage medium
US9875206B2 (en) Methods and devices for extending USB 3.0-compliant communication
CN1638319B (en) Retransmission system and method for a transport offload engine
CN1753351B (en) Apparatus and method for tracking packets in a reliably connected transmission system
CN101227388B (en) Computer system with network interface retransmit
US7436831B2 (en) Wireless network load generator dynamic MAC hardware address manipulation
US10178018B2 (en) Transmission and reception devices
US8065401B2 (en) Systems and methods for frame ordering in wide port SAS connections
CN101944983B (en) Method and system for transmitting and receiving management message in communication network
US9509623B2 (en) Information processing device, information processing system, and method for processing packets from transmitting devices
US11736567B2 (en) Data transmission and network interface controller
CN102685143B (en) Audio data transmission method, client side and server
CN203574673U (en) Message-processing system
CN102238206A (en) Image file packet retransmission method
CN103701865A (en) Data transmission method and system
US20150318958A1 (en) Communication apparatus and packet transfer method
KR20160052422A (en) Method for flow control in network
CN112351049B (en) Data transmission method, device, equipment and storage medium
KR20140125311A (en) Apparatus and method for processing traffic using network interface card with multi-core
WO2017063589A1 (en) Data transmission method and apparatus
JP6932961B2 (en) Telegram transmission / reception system, telegram transmission device, telegram transmission / reception method and program
JP4690271B2 (en) Data transfer buffer control device and data transfer control method
CN109586931A (en) Method of multicasting and terminal device
CN114928377B (en) Output transmission method, device and equipment for reducing transparent transmission bandwidth of USB data

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