Message transmission method and device, electronic equipment and storage medium
By sorting and modifying the message identification in the FTTR networking to resend messages according to the message type priority, the problem of retransmitting ordinary services first and then retransmitting important services in the prior art is solved, and the user experience and service timeliness are improved.
Patent Information
- Application Number
- CN202411423859.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-12
- Publication Date
- 2024-12-27
- Estimated Expiration
- 2044-10-12
AI Technical Summary
In fiber to room (FTTR) networking, existing message transmission methods may lead to retransmission of ordinary service messages first and then retransmitting important service messages, affecting the user's service experience.
In the retransmission queue, the priority of the message type is sorted from high to low, and it is determined whether the number of messages exceeds the set threshold. If it exceeds the message, the message identification will be modified and the message will be sent again to ensure the processing time of high-priority services.
By prioritizing the transmission of packets in the high-priority retransmission queue, the user's service experience is improved and the processing time of high-priority services is ensured.
Smart Images

Figure CN119211155A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of communication technology, and in particular to a message transmission method, device, electronic device and storage medium. Background Art
[0002] In Fiber To The Room (FTTR) networking, the master device and multiple slave devices are connected and interact with each other through the Easymesh protocol. When either the master device or the slave device acts as a sender, after sending an Easymesh protocol message of a specified message type to the other party as a receiver, the receiver needs to send a corresponding reply message to the sender (the message identifier (MID) carried by the message is the same as the MID carried in the Easymesh protocol message). When the sender does not receive the corresponding reply message sent by the receiver, it needs to resend the Easymesh protocol message.
[0003] At present, when the sender sends the Easymesh protocol message, it will copy a copy of the Easymesh protocol message and cache it at the end of the retransmission queue; if the sender receives the corresponding reply message within the retransmission period, it will delete the Easymesh protocol message whose MID is the same as the MID carried in the corresponding reply message from the retransmission queue; if the sender has not received the corresponding reply message after the retransmission period, when it is necessary to resend the Easymesh protocol message in the retransmission queue, it will copy a copy of the Easymesh protocol message and send it to the receiving end.
[0004] However, the above-mentioned message transmission mode may cause the problem of first retransmitting the Easymesh protocol message of the common service and then retransmitting the Easymesh protocol message of the important service, which affects the service experience of the user. Summary of the invention
[0005] In order to overcome the problems existing in the related art, the present application provides a message transmission method, device, electronic device and storage medium.
[0006] According to a first aspect of an embodiment of the present application, a message transmission method is provided, the method being applied to a sending end, the method comprising:
[0007] After the retransmission cycle is reached, for each retransmission queue in a plurality of retransmission queues arranged in descending order of priority according to corresponding message types, if a first Easymesh protocol message that is not marked as sent is cached in the retransmission queue, determine whether a first total quantity value of the first Easymesh protocol message is not greater than a set threshold set for the message type corresponding to the retransmission queue;
[0008] If the judgment result is no, an Easymesh protocol message that meets the preset condition is selected from the first Easymesh protocol message, and when it is determined that the message identifier (Message Identifier, MID) carried in the selected Easymesh protocol message needs to be modified, the MID carried in the selected Easymesh protocol message is modified, and the modified Easymesh protocol message is copied and sent to the corresponding receiving end, and the modified Easymesh protocol message in the retransmission queue is marked as sent;
[0009] Wherein, when the transmitting end is a master device in a fiber-to-the-room FTTR network, the corresponding receiving end is a slave device in the FTTR network that needs to receive the first Easymesh protocol message; or,
[0010] When the transmitting end is any slave device in the FTTR network, the corresponding receiving end is the master device in the FTTR network;
[0011] Any Easymesh protocol message in the retransmission queue is cached in the retransmission queue corresponding to the target message type when the sending end needs to send the Easymesh protocol message of the target message type to the corresponding receiving end;
[0012] The higher the priority corresponding to the message type corresponding to the retransmission queue, the higher the set threshold corresponding to the corresponding message type, and the larger the second total number value of the corresponding selected Easymesh protocol messages.
[0013] According to a second aspect of an embodiment of the present application, a message transmission device is provided, the device being applied to a sending end, the device comprising:
[0014] A judging module, configured to, after reaching a retransmission cycle, for each of a plurality of retransmission queues arranged in descending order of priorities corresponding to corresponding message types, if a first Easymesh protocol message that is not marked as sent is cached in the retransmission queue, judge whether a first total quantity value of the first Easymesh protocol message is not greater than a set threshold set for the message type corresponding to the retransmission queue;
[0015] A transmission module, for selecting an Easymesh protocol message that meets a preset condition from the first Easymesh protocol message if the judgment result of the judgment module is no, and when it is determined that the MID carried in the selected Easymesh protocol message needs to be modified, modifying the MID carried in the selected Easymesh protocol message, copying the modified Easymesh protocol message and sending it to the corresponding receiving end, and marking the modified Easymesh protocol message in the retransmission queue as sent;
[0016] Wherein, when the transmitting end is a master device in a fiber-to-the-room FTTR network, the corresponding receiving end is a slave device in the FTTR network that needs to receive the first Easymesh protocol message; or,
[0017] When the transmitting end is any slave device in the FTTR network, the corresponding receiving end is the master device in the FTTR network;
[0018] Any Easymesh protocol message in the retransmission queue is cached in the retransmission queue corresponding to the target message type when the sending end needs to send the Easymesh protocol message of the target message type to the corresponding receiving end;
[0019] The higher the priority corresponding to the message type corresponding to the retransmission queue, the higher the set threshold corresponding to the corresponding message type, and the larger the second total number value of the corresponding selected Easymesh protocol messages.
[0020] According to a third aspect of an embodiment of the present application, an electronic device is provided, comprising a processor and a machine-readable storage medium, wherein the machine-readable storage medium stores machine-executable instructions that can be executed by the processor, and the processor is prompted by the machine-executable instructions to implement the method steps of the above-mentioned message transmission method.
[0021] According to a fourth aspect of an embodiment of the present application, a computer-readable storage medium is provided, wherein a computer program is stored in the computer-readable storage medium, and when the computer program is executed by a processor, the method steps of the above-mentioned message transmission method are implemented.
[0022] The technical solution provided by the embodiments of the present application may have the following beneficial effects:
[0023] In an embodiment of the present application, the sending end can give priority to transmitting the relevant Easymesh protocol messages in the corresponding retransmission queue based on the priority corresponding to the relevant message type to ensure the processing timeliness of high-priority services, thereby improving the user's service experience.
[0024] It should be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present application. BRIEF DESCRIPTION OF THE DRAWINGS
[0025] The accompanying drawings, which are incorporated in the specification and constitute a part of this application, illustrate embodiments consistent with the application and, together with the description, serve to explain the principles of the application.
[0026] Figure 1 A schematic diagram of a flow chart of a message transmission method provided in an embodiment of the present application;
[0027] Figure 2 A schematic diagram of the architecture of the FTTR network provided in the embodiment of the present application;
[0028] Figure 3 A schematic diagram of the structure of a message transmission device provided in an embodiment of the present application;
[0029] Figure 4 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0030] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The implementations described in the following exemplary embodiments do not represent all implementations consistent with the present application. Instead, they are merely examples of devices and methods consistent with some aspects of the present application as detailed in the appended claims.
[0031] The terms used in this application are for the purpose of describing specific embodiments only and are not intended to limit this application. The singular forms of "a", "said" and "the" used in this application and the appended claims are also intended to include plural forms unless the context clearly indicates other meanings. It should also be understood that the term "and / or" used herein refers to and includes any or all possible combinations of one or more associated listed items.
[0032] It should be understood that, although the terms first, second, third, etc. may be used in the present application to describe various information, these information should not be limited to these terms. These terms are only used to distinguish the same type of information from each other. For example, without departing from the scope of the present application, the first information may also be referred to as the second information, and similarly, the second information may also be referred to as the first information. Depending on the context, the words "if" or "if" as used herein may be interpreted as "at the time of" or "when...".
[0033] Next, the embodiments of the present application are described in detail.
[0034] The present application embodiment provides a message transmission method, characterized in that the method is applied to a sending end, such as Figure 1 As shown, the method may include the following steps:
[0035] S11. After reaching the retransmission cycle, for each retransmission queue in a plurality of retransmission queues arranged in descending order of priority according to corresponding message types, if the retransmission queue has a first Easymesh protocol message cached therein that has not been marked as sent, determine whether the first total quantity value of the first Easymesh protocol message is not greater than a set threshold value set for the message type corresponding to the retransmission queue; if the determination result is yes, execute step S12; if the determination result is no, execute step S13.
[0036] S12. When it is determined that the MID carried in the first Easymesh protocol message needs to be modified, the MID carried in the first Easymesh protocol message is modified, and the modified Easymesh protocol message is copied and sent to the corresponding receiving end, and the modified Easymesh protocol message in the retransmission queue is marked as sent; or, when it is determined that the MID carried in the first Easymesh protocol message does not need to be modified, the first Easymesh protocol message is copied and sent to the corresponding receiving end, and the first Easymesh protocol message in the retransmission queue is marked as sent.
[0037] S13, selecting an Easymesh protocol message that meets a preset condition from the first Easymesh protocol message, and when it is determined that the message identifier MID carried in the selected Easymesh protocol message needs to be modified, modifying the MID carried in the selected Easymesh protocol message, copying the modified Easymesh protocol message and sending it to the corresponding receiving end, and marking the modified Easymesh protocol message in the retransmission queue as sent.
[0038] It should be noted that in the embodiment of the present application, when the transmitting end is the master device in the FTTR network, the corresponding receiving end is the slave device in the FTTR network that needs to receive the first Easymesh protocol message (it may be the same slave device or different slave devices).
[0039] Alternatively, when the transmitting end is any slave device in the FTTR network, the corresponding receiving end is the master device in the FTTR network.
[0040] Any Easymesh protocol message in the retransmission queue is cached in the retransmission queue corresponding to the target message type when the sending end needs to send the Easymesh protocol message of the target message type to the corresponding receiving end.
[0041] The higher the priority corresponding to the message type corresponding to the retransmission queue, the higher the set threshold corresponding to the corresponding message type, and the larger the second total number value of the corresponding selected Easymesh protocol messages.
[0042] That is, different message types corresponding to different retransmission queues have different priorities, and different thresholds are set for message types corresponding to different retransmission queues.
[0043] Here, the administrator of the FTTR network can set the thresholds corresponding to the message types corresponding to different retransmission queues in advance based on network experience, and configure them at the sending end.
[0044] In addition, the administrator can also set the above retransmission period in advance according to network experience and configure it at the sending end.
[0045] It should be further explained that in the embodiment of the present application, for the sending end, it can be determined based on the existing message processing mechanism whether it is necessary to modify the MID carried in the first Easymesh protocol message or the selected Easymesh protocol message. When it is determined that it is necessary to modify the MID carried in the first Easymesh protocol message or the selected Easymesh protocol message, the MID carried in the first Easymesh protocol message or the selected Easymesh protocol message is modified to a new MID.
[0046] In addition, in the embodiment of the present application, for each retransmission queue, if there is no first Easymesh protocol message that has not been marked as sent cached in the retransmission queue, then no operation is performed.
[0047] Specifically, in the above step S13, when the sending end performs the step of selecting an Easymesh protocol message that meets the preset condition from the first Easymesh protocol message, it can be implemented in the following manner:
[0048] The first way: according to the sequence of the first Easymesh protocol messages in the cache, a set threshold number of Easymesh protocol messages set for the message type corresponding to the retransmission queue are selected from the first Easymesh protocol messages.
[0049] The second method: selecting a set threshold number of Easymesh protocol messages from the first Easymesh protocol messages according to the sequence of the first Easymesh protocol messages in the cache.
[0050] If there is no target Easymesh protocol message whose cache duration is longer than the set duration set for the message type corresponding to the retransmission queue among the remaining first Easymesh protocol messages, the selected first Easymesh protocol message is determined as the Easymesh protocol message that meets the preset condition;
[0051] If there is a target Easymesh protocol message whose cache duration is longer than the set duration in the remaining first Easymesh protocol messages, the selected Easymesh protocol message and the target Easymesh protocol message are determined as Easymesh protocol messages that meet the preset conditions.
[0052] It should be noted that in the embodiment of the present application, different retransmission queues correspond to different message types and have different corresponding cache durations.
[0053] Here, the administrator of the FTTR network can set the cache time corresponding to the message type corresponding to different retransmission queues in advance based on network experience, and configure it at the sending end.
[0054] It should be further explained that, in an embodiment of the present application, the message types corresponding to multiple retransmission queues may include a configuration message type, a query message type, a notification message type, a report message type, and a measurement message type.
[0055] Of course, the message types corresponding to the multiple retransmission queues may also include other message types, which are not listed here one by one.
[0056] Furthermore, in the embodiment of the present application, the sending end may also perform the following operations:
[0057] If a reply message for the second Easymesh protocol message is received, the Easymesh protocol message carrying the same MID as the MID carried in the reply message is deleted from the retransmission queue corresponding to the message type of the second Easymesh protocol message.
[0058] The above message transmission method is described in detail below in conjunction with specific embodiments.
[0059] like Figure 2As shown, the master device and slave devices 1 to 5 can provide wireless access services for wireless terminals, and the master device also communicates with the outdoor network and slave devices 1 to 5. Assume that the retransmission queue corresponding to the configuration message type (referred to as retransmission queue 1), the retransmission queue corresponding to the query message type (referred to as retransmission queue 2), the retransmission queue corresponding to the notification message type (referred to as retransmission queue 3), the retransmission queue corresponding to the report message type (referred to as retransmission queue 4) and the retransmission queue corresponding to the measurement message type (referred to as retransmission queue 5) are configured on the master device side as the sending end.
[0060] Furthermore, it is assumed that the priority corresponding to the configuration message type is higher than the priority corresponding to the query message type, the priority corresponding to the query message type is higher than the priority corresponding to the notification message type, the priority corresponding to the notification message type is higher than the priority corresponding to the report message type, and the priority corresponding to the report message type is higher than the priority corresponding to the measurement message type.
[0061] Assume that the threshold value configured for the configuration message type on the master device is N1, the threshold value configured for the query message type is N2, the threshold value configured for the notification message type is N3, the threshold value configured for the report message type is N4, and the threshold value configured for the measurement message type is N5. Among them, N1>N2>N3>N4>N5.
[0062] Assume that the set duration configured for the configuration message type on the master device is time1, the set duration configured for the query message type is time2, the set duration configured for the notification message type is time3, the set duration configured for the report message type is time4, and the set threshold configured for the measurement message type is time5. Among them, time5>time4>time3>time2>time1.
[0063] Assume that at time 1, the master device needs to send Easymesh protocol message 1 of the configuration message type to slave device 1 (located in room 1) which is the receiving end in the FTTR network. The master device copies an Easymesh protocol message 1, sends an Easymesh protocol message 1 to slave device 1, and caches another Easymesh protocol message 1 in retransmission queue 1.
[0064] Assume that at time 2, the master device needs to send Easymesh protocol message 2 of query message type to slave device 1. The master device copies a copy of Easymesh protocol message 2, sends a copy of Easymesh protocol message 2 to slave device 1, and caches another copy of Easymesh protocol message 2 in retransmission queue 2.
[0065] Assume that at time 3, the master device needs to send Easymesh protocol message 3 of notification message type to slave device 1. The master device copies a copy of Easymesh protocol message 3, sends a copy of Easymesh protocol message 3 to slave device 1, and stores another copy of Easymesh protocol message 3 in retransmission queue 3.
[0066] Assume that at time 4, the master device needs to send Easymesh protocol message 4 of report message type to slave device 1. The master device copies an Easymesh protocol message 4, sends an Easymesh protocol message 4 to slave device 1, and caches another Easymesh protocol message 4 in retransmission queue 4.
[0067] Assume that at time 5, the master device needs to send Easymesh protocol message 5 of measurement message type to slave device 1. The master device copies one Easymesh protocol message 5, sends one Easymesh protocol message 5 to slave device 1, and caches another Easymesh protocol message 5 in retransmission queue 5.
[0068] Next, assuming that a certain retransmission cycle is reached, for retransmission queue 1, assuming that there are first Easymesh protocol messages that are not marked as sent cached in retransmission queue 1, at this time, the master device determines whether the total number of first Easymesh protocol messages is not greater than N1.
[0069] Assuming that the judgment result is no, then the master device selects an Easymesh protocol message that meets the preset conditions from these first Easymesh protocol messages, and when it is determined that the MID carried in the selected Easymesh protocol message needs to be modified, the MID carried in the selected Easymesh protocol message is modified, and the modified Easymesh protocol message is copied and sent to the corresponding receiving end (for example, slave device 1), and the modified Easymesh protocol message in the retransmission queue 1 is marked as sent.
[0070] Here, it is assumed that the second method mentioned above is used to select Easymesh protocol messages that meet the preset conditions. For example, the selected Easymesh protocol messages include N1 Easymesh protocol messages and M1 Easymesh protocol messages whose cache duration is greater than time1. These Easymesh protocol messages are arranged in the order of cache.
[0071] For the retransmission queue 2, assuming that there is no second Easymesh protocol message that is not marked as sent cached in the retransmission queue 2, at this time, the master device does not perform any operation.
[0072] For the retransmission queue 3, assuming that the retransmission queue 3 has the third Easymesh protocol message that is not marked as sent cached, at this time, the master device determines whether the total number of the third Easymesh protocol messages is not greater than N3.
[0073] Assume that the judgment result is yes and the third Easymesh protocol message does not need to be modified. In this case, the master device copies the third Easymesh protocol message and sends it to the corresponding receiving end (for example, slave device 1), and marks the third Easymesh protocol message in the retransmission queue 3 as sent.
[0074] For the retransmission queue 4, assuming that the retransmission queue 4 has the fourth Easymesh protocol message that is not marked as sent cached, at this time, the master device determines whether the total number of the fourth Easymesh protocol messages is not greater than N4.
[0075] Assuming that the judgment result is no, then the master device selects an Easymesh protocol message that meets the preset conditions from these fourth Easymesh protocol messages, and when it is determined that there is no need to modify the MID carried in the selected Easymesh protocol message, the master device copies the selected Easymesh protocol message and sends it to the corresponding receiving end (for example, from device 1), and marks the selected Easymesh protocol message in the retransmission queue 4 as sent.
[0076] For the retransmission queue 5, assuming that the retransmission queue 5 has the fifth Easymesh protocol message that is not marked as sent cached, at this time, the master device determines whether the total number of the fifth Easymesh protocol message is not greater than N5.
[0077] Assuming that the judgment result is no, then the master device selects an Easymesh protocol message that meets the preset conditions from these fifth Easymesh protocol messages, and when it is determined that the MID carried in the selected Easymesh protocol message needs to be modified, the MID carried in the selected Easymesh protocol message is modified, and the modified Easymesh protocol message is copied and sent to the corresponding receiving end (for example, from device 1), and the modified Easymesh protocol message in the retransmission queue 5 is marked as sent.
[0078] Here, it is assumed that the second method mentioned above is used to select Easymesh protocol messages that meet the preset conditions. For example, the selected Easymesh protocol messages include N5 fifth Easymesh protocol messages and M5 fifth Easymesh protocol messages whose cache duration is greater than time5. These fifth Easymesh protocol messages are arranged in the order of cache.
[0079] Subsequently, it is assumed that at time 6, the master device receives reply message 1 to Easymesh protocol message 1, and then deletes the Easymesh protocol message carrying the same MID as the MID carried in reply message 1 from retransmission queue 1.
[0080] It can be seen from the above technical solution that in an embodiment of the present application, the sending end can give priority to transmitting the relevant Easymesh protocol messages in the corresponding retransmission queue based on the priority corresponding to the relevant message type, so as to ensure the processing timeliness of high-priority services, thereby improving the user's service experience.
[0081] Based on the same inventive concept, the present application also provides a message transmission device, which is applied to the sending end, and its structural diagram is as follows: Figure 3 As shown, specifically including:
[0082] The judging module 31 is used for judging whether a first total quantity value of the first Easymesh protocol message is not greater than a set threshold value set for the message type corresponding to each retransmission queue in a plurality of retransmission queues arranged in descending order of priority according to the corresponding message type after the retransmission cycle is reached, if the retransmission queue has a first Easymesh protocol message that is not marked as sent cached therein;
[0083] The transmission module 32 is used for selecting an Easymesh protocol message that meets a preset condition from the first Easymesh protocol message if the judgment result of the judgment module 31 is no, and when it is determined that the message identifier MID carried in the selected Easymesh protocol message needs to be modified, modifying the MID carried in the selected Easymesh protocol message, copying the modified Easymesh protocol message and sending it to the corresponding receiving end, and marking the modified Easymesh protocol message in the retransmission queue as sent;
[0084] Wherein, when the transmitting end is a master device in a fiber-to-the-room FTTR network, the corresponding receiving end is a slave device in the FTTR network that needs to receive the first Easymesh protocol message; or,
[0085] When the transmitting end is any slave device in the FTTR network, the corresponding receiving end is the master device in the FTTR network;
[0086] Any Easymesh protocol message in the retransmission queue is cached in the retransmission queue corresponding to the target message type when the sending end needs to send the Easymesh protocol message of the target message type to the corresponding receiving end;
[0087] The higher the priority corresponding to the message type corresponding to the retransmission queue, the higher the set threshold corresponding to the corresponding message type, and the larger the second total number value of the corresponding selected Easymesh protocol messages.
[0088] Preferably, the transmission module 32 is further used for:
[0089] If the judgment result of the judgment module 31 is yes, when it is determined that the MID carried in the first Easymesh protocol message needs to be modified, the MID carried in the first Easymesh protocol message is modified, and the modified Easymesh protocol message is copied and sent to the corresponding receiving end, and the modified Easymesh protocol message in the retransmission queue is marked as sent; or,
[0090] When it is determined that the MID carried in the first Easymesh protocol message does not need to be modified, the first Easymesh protocol message is copied and sent to the corresponding receiving end, and the first Easymesh protocol message in the retransmission queue is marked as sent.
[0091] Preferably, the transmission module 32 is further used for:
[0092] After selecting an Easymesh protocol message that meets the preset conditions from the first Easymesh protocol message, if it is determined that the MID carried in the selected Easymesh protocol message does not need to be modified, the selected Easymesh protocol message is copied and sent to the corresponding receiving end, and the selected Easymesh protocol message in the retransmission queue is marked as sent.
[0093] Preferably, the device further comprises:
[0094] Delete module( Figure 3 ), if a reply message is received for a second Easymesh protocol message, then the Easymesh protocol message carrying the same MID as the MID carried in the reply message is deleted from the retransmission queue corresponding to the message type of the second Easymesh protocol message.
[0095] Preferably, the transmission module 32 is specifically used for:
[0096] selecting the set threshold number of Easymesh protocol messages from the first Easymesh protocol messages according to the sequence of the first Easymesh protocol messages cached; or,
[0097] Selecting the set threshold number of first Easymesh protocol messages from the first Easymesh protocol messages according to the sequence of the first Easymesh protocol messages cached;
[0098] If there is no target Easymesh protocol message whose cache duration is longer than the set duration set for the message type corresponding to the retransmission queue among the remaining first Easymesh protocol messages, the selected Easymesh protocol message is determined as the Easymesh protocol message that meets the preset condition;
[0099] If there is a target Easymesh protocol message whose cache duration is longer than the set duration in the remaining first Easymesh protocol message, the selected Easymesh protocol message and the target Easymesh protocol message are determined as Easymesh protocol messages that meet the preset conditions. It can be seen from the above technical scheme that in the embodiment of the present application, the sending end can preferentially transmit the relevant Easymesh protocol messages in the corresponding retransmission queue based on the priority corresponding to the relevant message type to ensure the processing timeliness of high-priority services, thereby improving the user's service experience.
[0100] The present application also provides an electronic device, such as Figure 4 As shown, it includes a processor 41 and a machine-readable storage medium 42, the machine-readable storage medium 42 stores machine-executable instructions that can be executed by the processor 41, and the processor 41 is prompted by the machine-executable instructions to implement the steps of the above-mentioned message transmission method.
[0101] The machine-readable storage medium may include a random access memory (RAM) or a non-volatile memory (NVM), such as at least one disk storage. Optionally, the machine-readable storage medium may also be at least one storage device located away from the processor.
[0102] The above-mentioned processor can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.
[0103] In another embodiment provided in the present application, a computer-readable storage medium is provided, in which a computer program is stored. When the computer program is executed by a processor, the steps of the above-mentioned message transmission method are implemented.
[0104] The above description is only a preferred embodiment of the present application and is not intended to limit the present application. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present application shall be included in the scope of protection of the present application.
Claims
1. A message transmission method, characterized in that: The method is applied to a transmitting end, and the method comprises: After the retransmission cycle is reached, for each retransmission queue in a plurality of retransmission queues arranged in descending order of priority according to corresponding message types, if a first Easymesh protocol message that is not marked as sent is cached in the retransmission queue, determine whether a first total quantity value of the first Easymesh protocol message is not greater than a set threshold set for the message type corresponding to the retransmission queue; If the judgment result is no, an Easymesh protocol message that meets the preset condition is selected from the first Easymesh protocol message, and when it is determined that the message identifier MID carried in the selected Easymesh protocol message needs to be modified, the MID carried in the selected Easymesh protocol message is modified, and the modified Easymesh protocol message is copied and sent to the corresponding receiving end, and the modified Easymesh protocol message in the retransmission queue is marked as sent; Wherein, when the transmitting end is a master device in a fiber-to-the-room FTTR network, the corresponding receiving end is a slave device in the FTTR network that needs to receive the first Easymesh protocol message; or, When the transmitting end is any slave device in the FTTR network, the corresponding receiving end is the master device in the FTTR network; Any Easymesh protocol message in the retransmission queue is cached in the retransmission queue corresponding to the target message type when the sending end needs to send the Easymesh protocol message of the target message type to the corresponding receiving end; The higher the priority corresponding to the message type corresponding to the retransmission queue, the higher the set threshold corresponding to the corresponding message type, and the larger the second total number value of the corresponding selected Easymesh protocol messages.
2. The method according to claim 1, characterized in that The method further comprises: If the judgment result is yes, when it is determined that the MID carried in the first Easymesh protocol message needs to be modified, the MID carried in the first Easymesh protocol message is modified, and the modified Easymesh protocol message is copied and sent to the corresponding receiving end, and the modified Easymesh protocol message in the retransmission queue is marked as sent; or, When it is determined that the MID carried in the first Easymesh protocol message does not need to be modified, the first Easymesh protocol message is copied and sent to the corresponding receiving end, and the first Easymesh protocol message in the retransmission queue is marked as sent.
3. The method according to claim 1, characterized in that The method further comprises: After selecting an Easymesh protocol message that meets the preset conditions from the first Easymesh protocol message, if it is determined that the MID carried in the selected Easymesh protocol message does not need to be modified, the selected Easymesh protocol message is copied and sent to the corresponding receiving end, and the selected Easymesh protocol message in the retransmission queue is marked as sent.
4. The method according to claim 1, characterized in that: The method further comprises: If a reply message to the second Easymesh protocol message is received, the Easymesh protocol message carrying the same MID as the MID carried in the reply message is deleted from the retransmission queue corresponding to the message type of the second Easymesh protocol message.
5. The method according to claim 1, characterized in that Selecting an Easymesh protocol message that meets a preset condition from the first Easymesh protocol message specifically includes: selecting the set threshold number of Easymesh protocol messages from the first Easymesh protocol messages according to the sequence of the first Easymesh protocol messages cached; or, Selecting the set threshold number of first Easymesh protocol messages from the first Easymesh protocol messages according to the sequence of the first Easymesh protocol messages cached; If there is no target Easymesh protocol message whose cache duration is longer than the set duration set for the message type corresponding to the retransmission queue among the remaining first Easymesh protocol messages, the selected Easymesh protocol message is determined as the Easymesh protocol message that meets the preset condition; If there is a target Easymesh protocol message whose cache duration is longer than the set duration in the remaining first Easymesh protocol messages, the selected Easymesh protocol message and the target Easymesh protocol message are determined as Easymesh protocol messages that meet the preset condition.
6. A message transmission device, characterized in that: The device is applied to a transmitting end, and the device includes: A judging module, configured to, after reaching a retransmission cycle, for each of a plurality of retransmission queues arranged in descending order of priorities corresponding to corresponding message types, if a first Easymesh protocol message that is not marked as sent is cached in the retransmission queue, judge whether a first total quantity value of the first Easymesh protocol message is not greater than a set threshold set for the message type corresponding to the retransmission queue; A transmission module, for selecting an Easymesh protocol message that meets a preset condition from the first Easymesh protocol message if the judgment result of the judgment module is no, and when it is determined that the message identifier MID carried in the selected Easymesh protocol message needs to be modified, modifying the MID carried in the selected Easymesh protocol message, copying the modified Easymesh protocol message and sending it to the corresponding receiving end, and marking the modified Easymesh protocol message in the retransmission queue as sent; Wherein, when the transmitting end is a master device in a fiber-to-the-room FTTR network, the corresponding receiving end is a slave device in the FTTR network that needs to receive the first Easymesh protocol message; or, When the transmitting end is any slave device in the FTTR network, the corresponding receiving end is the master device in the FTTR network; Any Easymesh protocol message in the retransmission queue is cached in the retransmission queue corresponding to the target message type when the sending end needs to send the Easymesh protocol message of the target message type to the corresponding receiving end; The higher the priority corresponding to the message type corresponding to the retransmission queue, the higher the set threshold corresponding to the corresponding message type, and the larger the second total number value of the corresponding selected Easymesh protocol messages.
7. The device according to claim 6, characterized in that The transmission module is further used for: If the judgment result of the judgment module is yes, when it is determined that the MID carried in the first Easymesh protocol message needs to be modified, the MID carried in the first Easymesh protocol message is modified, and the modified Easymesh protocol message is copied and sent to the corresponding receiving end, and the modified Easymesh protocol message in the retransmission queue is marked as sent; or, When it is determined that the MID carried in the first Easymesh protocol message does not need to be modified, the first Easymesh protocol message is copied and sent to the corresponding receiving end, and the first Easymesh protocol message in the retransmission queue is marked as sent.
8. The device according to claim 6, characterized in that The transmission module is further used for: After selecting an Easymesh protocol message that meets the preset conditions from the first Easymesh protocol message, if it is determined that the MID carried in the selected Easymesh protocol message does not need to be modified, the selected Easymesh protocol message is copied and sent to the corresponding receiving end, and the selected Easymesh protocol message in the retransmission queue is marked as sent.
9. The device according to claim 6, characterized in that The device also includes: The deleting module is used for deleting the Easymesh protocol message carrying the same MID as the MID carried in the reply message from the retransmission queue corresponding to the message type of the second Easymesh protocol message if a reply message to the second Easymesh protocol message is received.
10. The device according to claim 6, characterized in that The transmission module is specifically used for: selecting the set threshold number of Easymesh protocol messages from the first Easymesh protocol messages according to the sequence of the first Easymesh protocol messages cached; or, Selecting the set threshold number of first Easymesh protocol messages from the first Easymesh protocol messages according to the sequence of the first Easymesh protocol messages cached; If there is no target Easymesh protocol message whose cache duration is longer than the set duration set for the message type corresponding to the retransmission queue among the remaining first Easymesh protocol messages, the selected Easymesh protocol message is determined as the Easymesh protocol message that meets the preset condition; If there is a target Easymesh protocol message whose cache duration is longer than the set duration in the remaining first Easymesh protocol messages, the selected Easymesh protocol message and the target Easymesh protocol message are determined as Easymesh protocol messages that meet the preset condition.
11. An electronic device, characterized in that: The method comprises a processor and a machine-readable storage medium, wherein the machine-readable storage medium stores machine-executable instructions that can be executed by the processor, and the processor is prompted by the machine-executable instructions to implement the method steps described in any one of claims 1 to 5.
12. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method steps of any one of claims 1 to 5 are implemented.
Citation Information
Patent Citations
A retransfer scheduling method of the HARQ protocol based on the retransfer time
CN101018110A
Adaptive end-to-end network coding transmission method
CN107508655A
Message sending method and device, readable medium and electronic equipment
CN110662085A
Message transmission device, equipment, method and storage medium
CN111740939A
Multi-priority queue management method and device, and storage medium
CN112272148A