Cloud edge asynchronous communication method and system oriented to weak network environment
By introducing sequence number allocation, selective acknowledgment, and dynamic timeout mechanisms into cloud-edge communication, the throughput bottleneck and resource consumption issues in weak network environments are resolved, achieving efficient network bandwidth utilization and system scalability.
Patent Information
- Application Number
- CN202511743723.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-25
- Publication Date
- 2026-02-27
AI Technical Summary
Existing technologies suffer from throughput bottlenecks, head-of-line congestion, low network bandwidth utilization, and huge system resource overhead in cloud-edge communication under weak network conditions, making it difficult to support large-scale expansion.
The system employs a sequence number allocation and transmission buffer mechanism. The receiving end performs ordering judgment and sequence number reorganization to generate selective acknowledgment information. The sending end only retransmits lost messages and adjusts the timeout period through a dynamic timeout algorithm to achieve a non-blocking processing mode.
It significantly improves network bandwidth utilization and communication throughput, supports high-concurrency access of large-scale edge nodes, reduces system resource consumption, and improves system scalability and resource utilization.
Smart Images

Figure CN121585331A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of cloud-edge asynchronous communication technology, and in particular to a cloud-edge asynchronous communication method and apparatus for weak network environments. Background Technology
[0002] In cloud-edge collaborative computing architectures, reliable cloud-edge communication is the core foundation for ensuring system functionality. Currently, in typical implementations such as KubeEdge, the cloud communication hub CloudHub is responsible for message forwarding. Its downlink message processing flow is typically as follows: the message distributor routes messages from the controller to the corresponding node message queues of each edge node; for critical messages that require reliable transmission, the system adopts a synchronous acknowledgment mechanism, that is, after the cloud sends a single message, it enters a blocking waiting state. Only after receiving an acknowledgment signal from the corresponding edge node can the next message be retrieved from the queue for transmission. If the wait times out, a limited number of retransmissions are triggered. This mechanism is essentially a "stop-and-wait" protocol applied at the application layer, aiming to ensure reliability through at least one delivery.
[0003] However, the aforementioned synchronous stop-and-wait mechanism exhibits significant drawbacks in weak network environments characterized by poor network quality, high latency, large jitter, and frequent packet loss. This leads to a substantial decline in system performance, causing severe throughput bottlenecks and head-of-line congestion. Since each message transmission requires at least one complete network round-trip delay, theoretical throughput is strictly limited by the round-trip time, resulting in extremely low network bandwidth utilization—potentially less than one percent in typical weak network scenarios. Furthermore, fixed timeout settings cannot adapt to dynamically changing network conditions; setting them too short can lead to misjudgments and invalid retransmissions due to momentary jitter, while setting them too long delays fault recovery. Finally, this model maintains an independent blocking processing queue for each edge node. As the node scale increases significantly, the cloud needs to maintain a massive number of synchronous waiting threads or coroutines, resulting in huge system resource overhead and severely restricting the system's horizontal scalability and high-concurrency processing capabilities.
[0004] Therefore, there is an urgent need for a reliable cloud-edge communication solution that can significantly improve throughput, reduce latency, and support large-scale expansion in weak network environments. Summary of the Invention
[0005] To address the aforementioned issues, this invention provides a cloud-edge asynchronous communication method and apparatus for weak network environments. This invention offers a technical solution that retransmits only truly lost messages, significantly reducing the transmission gap caused by head-of-line congestion and improving network bandwidth utilization and overall communication throughput.
[0006] The sending end assigns sequence numbers to the application layer messages that need to be transmitted; Establish a sending buffer, and continuously send application layer messages to the receiving end based on the sequence number. At the same time, store copies of the sent application layer messages as unacknowledged messages in the sending buffer. The receiving end performs order determination and sequence number reassembly on the received application layer messages based on their sequence numbers. The receiving end generates selective acknowledgment information based on the application layer message after sequence number reassembly and sends it to the sending end; Based on the received selective acknowledgment information, successfully received application layer messages are identified in the send buffer, and lost application layer messages are inferred accordingly. The sending end treats successfully received application messages as acknowledged messages, removes the acknowledged messages from the pending acknowledgment messages in the sending buffer, and resends the application layer messages marked as lost to the receiving end.
[0007] Furthermore, it also includes: After the sending end removes the successfully received application layer message from the sending buffer, the space occupied by the application layer message in the application layer sending window is cleared. Update the application layer sending window corresponding to the removed application layer message; When a successfully received application-layer message is removed from the send buffer, the sender continues to send subsequent application-layer messages based on the updated application-layer send window and in sequence number order.
[0008] Furthermore, the orderliness judgment includes: Compare the sequence number of the received application layer message with the maximum sequence number of the currently received application layer messages; If the sequence number is consecutive to the maximum sequence number of the received application layer messages, it is determined to be an ordered message; If the sequence number is greater than the maximum sequence number that has been received consecutively but is not consecutive, it is determined to be an out-of-order message.
[0009] Furthermore, the sequence number reorganization process includes: For application layer messages that are determined to be ordered, the receiving end transmits them to the application corresponding to the application layer message and updates the maximum sequence number of the continuously received application layer information. Set up a receive buffer; for application layer messages that are determined to be out of order or lost, store them in the receive buffer. After updating the maximum sequence number of continuously received application layer messages, check the receive buffer and determine in real time whether there are consecutive sequence number application layer messages that have been added back to the receive buffer starting from the maximum sequence number application layer message. If they exist, the application layer messages with consecutive sequence numbers are retrieved from the receive buffer and sent to the application in sequence by the receiver. The maximum consecutive sequence number received is updated again. This process is repeated until there are no consecutive application layer messages in the receive buffer. If it does not exist, then the current sequence number reorganization process ends.
[0010] Furthermore, the generation of application-layer selective confirmation information includes: The maximum sequence number of the currently continuously received application layer messages obtained through sequence number reorganization is used as the cumulative confirmation point. Scan the receive buffer and organize all successfully received messages with non-contiguous sequence numbers into at least one selective acknowledgment block. Each selective acknowledgment block is used to describe a contiguous range of message sequence numbers. The cumulative confirmation points and all selective confirmation blocks are encapsulated to form application-layer selective confirmation information, which is then sent to the sending end.
[0011] Furthermore, the sending end determines the application layer messages that the receiving end has successfully received as: application layer messages with sequence numbers less than or equal to the cumulative acknowledgment point, and application layer messages in the non-contiguous application layer message sequence number range. Otherwise, it indicates that the application layer message was not successfully received.
[0012] Furthermore, it also includes: Based on real-time collected network status parameters, a dynamic timeout algorithm is used to set an adaptive timeout for each message to be confirmed. The collected network status parameters include at least the smooth round-trip time, round-trip time variance, and packet loss rate of the current network. Monitor the confirmation status of pending messages; If any pending confirmation message is not acknowledged within a timeout period, the pending confirmation message will be resent to the receiving end from the sending buffer.
[0013] Furthermore, the dynamic timeout algorithm calculation formula is as follows:
[0014] in, For adaptive timeout; α is the base delay weighting coefficient; This represents the smooth round-trip time of the current network. β is the network jitter sensitivity coefficient; This represents the current round-trip time variance of the network. Where C(ρ) is the congestion penalty function with the current network packet loss rate ρ as the variable, and the calculation formula is as follows:
[0015] Furthermore, when calculating the adaptive timeout, the adaptive timeout is extended according to the preset priority using the following formula:
[0016] in, The scaling factor is based on the business priority P, and its value is determined by the following rule: higher priority corresponds to... <1, medium priority corresponds to =1, low priority corresponds to Greater than 1.
[0017] Furthermore, when extending the adaptive timeout period, a minimum timeout protection time is added. The formula for calculating the minimum timeout protection time is as follows:
[0018] in The minimum timeout protection time is determined by the following rules:
[0019] in, This represents the minimum round-trip time value sampled within a unit time window. This is the preset lower limit time value.
[0020] This application also provides a cloud-edge asynchronous communication system for weak network environments. The system includes a transmitter, a receiver, and a dynamic timeout retransmission module. The transmitter includes a message serialization module, a windowed asynchronous transmission module, and an analysis module. The receiver includes an acknowledgment processing and retransmission module, a buffering and reassembly module, and a selective acknowledgment information generation module.
[0021] The message serialization module is used to assign sequence numbers to application layer messages that need to be transmitted; The windowed asynchronous transmission module is used to establish a sending buffer, continuously send application layer messages to the acknowledgment and retransmission module based on the sequence number, and store copies of the sent application layer messages as messages to be acknowledged in the sending buffer. The confirmation and retransmission module is used to determine the order of received application layer messages based on their sequence numbers and to reassemble the sequence numbers. The selective confirmation information generation module is used to generate selective confirmation information based on the application layer message after sequence number reorganization and send it to the sending end. The analysis module is used to identify successfully received application layer messages in the sending buffer based on the received selective acknowledgment information, and infer the lost application layer messages. The windowed asynchronous transmission module then removes the successfully received application layer messages as acknowledgment messages from the pending acknowledgment messages in the sending buffer, and resends the application layer messages marked as lost to the acknowledgment processing and retransmission module. The dynamic timeout retransmission module is used to set an adaptive timeout for each message to be acknowledged based on real-time collected network status parameters and a dynamic timeout algorithm. The collected network status parameters include at least the smooth round-trip time, round-trip time variance, and packet loss rate of the current network. It monitors the acknowledgment status of messages to be acknowledged. If any message to be acknowledged is not acknowledged within the timeout period, it is retransmitted to the receiving end from the sending buffer.
[0022] This application also provides an electronic device, which includes at least one processor and at least one memory, the memory being data-connected to the processor, wherein the memory stores instructions executable by at least one processor, the instructions being executed by at least one processor to enable at least one processor to perform any of the methods described above.
[0023] This application also provides a computer-storeable medium storing computer instructions, which, when executed by a processor, specifically perform the steps of any of the methods described above.
[0024] The technical effects and advantages of this invention are as follows: This invention assigns sequence numbers to messages and establishes a sending buffer, enabling the sender to continuously send multiple messages based on a sliding window without waiting for individual acknowledgments. Meanwhile, the receiver provides precise feedback on message reception status through selective acknowledgment information, allowing the sender to retransmit only truly lost messages. This reduces the transmission window caused by head-of-line congestion, thereby improving network bandwidth utilization and overall communication throughput.
[0025] To address the issue of poor adaptability of fixed timeout mechanisms in dynamic network environments, this invention collects network status parameters in real time and employs a dynamic timeout algorithm. It comprehensively considers network latency, jitter, and congestion conditions, and innovatively introduces a service priority adjustment mechanism and a minimum timeout protection strategy. This allows the timeout period to be dynamically adjusted according to network conditions, avoiding false retransmissions caused by excessively short timeout settings and preventing time-sensitive fault recovery from being affected by excessively long timeout settings.
[0026] Furthermore, this invention fundamentally solves the limitations of system horizontal scalability through a fully asynchronous, non-blocking processing mode. The sending end can immediately process other tasks after completing message transmission, without needing to maintain an independent blocking waiting thread for each edge node. The receiving end ensures orderly message delivery through an intelligent sequence number reassembly mechanism. This design decouples system resource consumption from the number of edge nodes, thereby supporting high-concurrency access from a large number of edge nodes and significantly improving system scalability and resource utilization.
[0027] Other features and advantages of the invention will be set forth in the following description, and will be apparent in part from the description, or may be learned by practicing the invention. The objects and other advantages of the invention may be realized and obtained by means of the structures pointed out in the description and the drawings. Attached Figure Description
[0028] Figure 1 This is a flowchart of the cloud-edge asynchronous communication method for weak network environments provided in Embodiment 1 of this application; Figure 2 This is a model architecture diagram of the cloud-edge asynchronous communication method for weak network environments provided in Embodiment 1 of this application; Figure 3 This is a system block diagram of the cloud-edge asynchronous communication method for weak network environments provided in Embodiment 2 of this application; Detailed Implementation The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0029] Example 1 To address the shortcomings of existing technologies, please refer to Figure 1 This invention discloses a cloud-edge asynchronous communication method for weak network environments, the method comprising: S1, Sending end (cloud), Figure 1 In the cloud, sequence numbers are assigned to application layer messages that need to be transmitted. These sequence numbers are continuous and unique, aiming to provide a unique identity for each message so as to facilitate subsequent orderly transmission and confirmation mechanisms. S2. Establish a sending buffer and continuously send application layer messages to the receiving end (edge node) based on sequence number order. Figure 1 (edge in the middle), and at the same time, store the copy of the sent application layer message as the message to be confirmed in the sending buffer; S3. The receiving end performs ordering and sequence number reassembly on the received application layer messages based on their sequence numbers. This processing mechanism can effectively deal with the common message out-of-order problem in weak network environments and ensure that the business layer can ultimately process messages in order. The orderliness determination includes the following steps: S3-1. Compare the sequence number of the received application layer message with the maximum sequence number of the currently received application layer messages; If the sequence number is consecutive to the maximum sequence number of the received application layer messages, it is determined to be an ordered message; If the sequence number is greater than the maximum sequence number that has been received consecutively but is not consecutive, it is determined to be an out-of-order message.
[0030] The serial number reorganization includes the following steps: S3-2. For application layer messages that are determined to be ordered, the receiving end transmits them to the application corresponding to the application layer message and updates the maximum sequence number of the continuously received application layer information. S3-3. Set up a receive buffer. For application layer messages that are judged to be out of order or lost, store them in the receive buffer. S3-4. After updating the maximum sequence number of continuously received application layer messages, check the receive buffer and determine in real time whether there are consecutive sequence number application layer messages that have been added back to the receive buffer starting from the maximum sequence number application layer message. If it exists, the application layer messages with consecutive sequence numbers are retrieved from the receive buffer and sent to the application in sequence by the receiver. The maximum consecutive sequence number received is updated again. This process is repeated until no next consecutive message is found in the receive buffer. If it does not exist, then the current sequence number reorganization process ends.
[0031] S4. The receiving end generates selective acknowledgment information based on the application layer message after sequence number reassembly. Figure 1 The structured acknowledgment information (SACK packet in the message) is sent to the sender. This structured acknowledgment information can accurately reflect the message reception status and provide a reliable basis for the sender's intelligent retransmission decision. Specifically, the generation of selective confirmation information at the application layer includes the following steps: S4-1. Use the maximum sequence number of the currently continuously received application layer messages obtained by sequence number recombination as the cumulative confirmation point; S4-2. Scan the receive buffer and organize all successfully received messages with non-contiguous sequence numbers into at least one selective acknowledgment block. Each selective acknowledgment block is used to describe a contiguous range of message sequence numbers. S4-3. Encapsulate the cumulative confirmation points and all selective confirmation blocks to form the application layer selective confirmation information, and send it to the sending end.
[0032] To achieve end-to-end flow control, the module that performs the above functions dynamically calculates an application layer receive window (rwnd) value based on its internal application load (such as message processing queue length, available memory, CPU load, etc.) and attaches it to the generated SACK packet to notify the sender, i.e., the cloud.
[0033] S5. Based on the received selective acknowledgment information, identify the successfully received application layer messages in the transmission buffer, and infer the lost application layer messages accordingly. The sending end determines whether the receiving end has successfully received the application layer message by: Application layer messages with sequence numbers less than or equal to the cumulative confirmation point; application layer messages within the sequence number range that are not consecutive. Otherwise, it is a lost application layer message.
[0034] S6. The sending end treats the successfully received application message as an acknowledged message, removes the acknowledged message from the pending message in the sending buffer, and resends the application layer message marked as lost to the receiving end. S7. After the sending end removes the successfully received application layer message from the sending buffer, the position occupied by the application layer message in the application layer sending window is cleared. S8. Update the application layer sending window corresponding to the removed application layer message; S9. When a successfully received application layer message is removed from the sending buffer, the sending end continues to send subsequent application layer messages based on the updated application layer sending window and the sequence number order. By maintaining the sending buffer and adopting a continuous sending mechanism, the system realizes the transformation from stop-and-wait mode to pipeline mode, so that the sending end does not need to wait for the confirmation of a single message to continue sending subsequent messages, thereby greatly improving the network bandwidth utilization. Among them, ordered messages and out-of-order messages are received application layer messages, while those that do not belong to the application layer messages in the sending buffer are lost application layer messages. S10. Based on the real-time collected network status parameters, a dynamic timeout algorithm is used to set an adaptive timeout for each message to be confirmed. The collected network status parameters include at least the smooth round-trip time, round-trip time variance, and packet loss rate of the current network. The formula for calculating the dynamic timeout algorithm is:
[0035] in, For adaptive timeout; α is the base delay weighting coefficient; This represents the smooth round-trip time of the current network. β is the network jitter sensitivity coefficient, which is obtained from the current network round-trip time. It is a dimensional quantity, and its unit is time, such as ms. This represents the current round-trip time variance of the network. C(ρ) is the congestion penalty function with the current network packet loss rate ρ as the variable, and the calculation formula is as follows:
[0036] S11. Monitor the confirmation status of pending messages; S12. If any pending confirmation message is not confirmed within the timeout period, the pending confirmation message shall be resent to the receiving end from the sending buffer.
[0037] S13, Continue executing S1.
[0038] Furthermore, when calculating the adaptive timeout, the adaptive timeout is extended according to the preset priority using the following formula:
[0039] The scaling factor is based on the business priority P, and its value is determined by the following rule: higher priority corresponds to... <1, medium priority corresponds to =1, low priority corresponds to If the priority is greater than 1, specifically, when performing this operation, the priority identifier P of the message is first input. The system enters the corresponding processing branch according to the value of P. If P is the highest priority, a scaling factor such as 0.8 is assigned, reducing the basic timeout to 80% of the original, thereby achieving rapid detection and response. If P is a medium priority, a standard factor of 1.0 is used, keeping the basic timeout unchanged. If P is the lowest priority, a factor such as 1.5 is assigned, extending the basic timeout to 150%, thereby tolerating greater latency and avoiding non-critical messages consuming bandwidth.
[0040] Furthermore, when calculating the adaptive timeout time, the minimum timeout protection time is included, and its calculation formula is as follows:
[0041] in The minimum timeout protection time is calculated using the following formula:
[0042] in, This represents the minimum round-trip time value sampled within a unit time window, with 50ms being the recommended lower limit.
[0043] Example 2 This embodiment demonstrates the specific implementation process of a cloud-edge asynchronous communication method for weak network environments. The two communicating parties are the cloud (sender) and the edge node (receiver). The cloud needs to send 10 consecutive business messages to the edge node, each message being 2KB in size, and assigning application layer sequence numbers 1 to 10 to these messages.
[0044] The simulated weak network environment parameters are as follows: average round-trip time is 200ms, network jitter is large, which may cause messages to arrive out of order, and the packet loss rate is 10%.
[0045] The system parameters are set as follows: the initial sending window size in the cloud is 5, and the initial application layer receiving window in the edge node is 15, indicating that the edge application can currently cache a maximum of 15 unprocessed messages. The retransmission timeout is set to 500ms for comparison.
[0046] At T=0ms, the cloud asynchronous sending module checks that the sending window size is 5, and immediately pushes five messages with sequence numbers (Seq) 1, 2, 3, 4, and 5 consecutively to the network, while storing copies in the sending buffer to await confirmation. At this time, the cloud status is: messages {1, 2, 3, 4, 5} have been sent and are awaiting confirmation, and the available space in the sending window is 0.
[0047] During network transmission over a period of approximately 100ms (T≈100ms), message Seq=3 is lost. Due to network jitter, the message arrival order becomes Seq=1, Seq=2, Seq=5, and Seq=4. The edge node performs intelligent acknowledgment and reassembly processing between T≈100ms and 110ms. Upon receiving Seq=1 and Seq=2, since they are consecutive and expected messages, they are immediately delivered to the upper-layer business application for processing. Upon receiving Seq=5, it detects that the expected Seq=3 has not arrived and stores it in the out-of-order buffer. Similarly, Seq=4 is stored in the out-of-order buffer and sorted. At this point, the edge node's status is: successfully processed and delivered {1, 2}, out-of-order buffer {4, 5}, waiting to receive {3}.
[0048] At T≈115ms, the edge node generates a structured application layer SACK packet containing cumulative acknowledgment point 2, selective acknowledgment block [{4, 5}], and receive window announcement 15. This SACK packet is sent back to the cloud. The cloud receives the SACK packet at T≈215ms, parses it, confirms that Seq=1 and 2 have been successfully delivered and cleared from the sending buffer, and also learns that Seq=4 and 5 have been delivered ahead of schedule. By comparing the sent pending acknowledgment list {3, 4, 5} with the SACK information, it is precisely deduced that only Seq=3 is the truly lost message.
[0049] The cloud immediately triggers a precise retransmission, resending Seq=3 while simultaneously sliding the sending window forward. The new sent pending acknowledgment list is {3 (retransmitting), 6, 7, 8, 9}, and the cloud continues sending Seq=6, 7, 8, 9. At T≈315ms, the edge node receives the retransmitted Seq=3, reassembles it with {4, 5} from the out-of-order buffer to form a continuous sequence {3, 4, 5}, and delivers it sequentially to the upper-layer business application. Subsequent messages {6, 7, 8, 9...} are also successfully processed.
[0050] Please see Figure 1 and Figure 3 The present invention also provides a cloud-edge asynchronous communication system for weak network environments. The system includes a transmitter, a receiver, and a dynamic timeout retransmission module. The transmitter includes a message serialization module, a windowed asynchronous transmission module, and an analysis module. The receiver includes an acknowledgment processing and retransmission module, a buffering and reassembly module, and a selective acknowledgment information generation module.
[0051] The message serialization module is used to assign sequence numbers to application layer messages that need to be transmitted; The windowed asynchronous transmission module is used to establish a sending buffer, continuously send application layer messages to the acknowledgment and retransmission module based on the sequence number, and store copies of the sent application layer messages as messages to be acknowledged in the sending buffer. The confirmation and retransmission module is used to determine the order of received application layer messages based on their sequence numbers and to reassemble the sequence numbers. The selective confirmation information generation module is used to generate selective confirmation information based on the application layer message after sequence number reorganization and send it to the sending end. Analysis module (cloud core) Figure 2 The Cloudcore module is used to identify successfully received application layer messages in the sending buffer based on the received selective acknowledgment information, and infer the lost application layer messages. The windowed asynchronous transmission module then removes the successfully received application layer messages from the pending acknowledgment messages in the sending buffer as acknowledgment messages, and resends the application layer messages marked as lost to the acknowledgment processing and retransmission module.
[0052] The dynamic timeout retransmission module is used to set an adaptive timeout for each message to be confirmed based on real-time collected network status parameters and a dynamic timeout algorithm. The collected network status parameters include at least the smooth round-trip time, round-trip time variance, and packet loss rate of the current network. The module monitors the confirmation status of messages to be confirmed. If any message to be confirmed is not confirmed within the timeout period, it is retransmitted to the receiving end from the sending buffer.
[0053] in, Figure 1The EdgeCore consists of an acknowledgment processing and retransmission module, a caching and reassembly module, and a selective acknowledgment information generation module.
[0054] like Figure 2 As described above, the cloud core of the sending end of this application includes a cloud-edge gateway (CloudHub) and controllers. Control commands or configuration information are issued through the K8SAPI server (K8SAPIServer, the standard unified management entry point for Kubernetes clusters), and are logically processed by the controllers in the cloud core to generate specific refactoring commands or routing strategies, which are then sent to the message serialization module via the cloud-edge gateway.
[0055] Subsequently, the above information is serialized by the message serialization module and sent to the edge via the windowed asynchronous transmission module. On the edge side, the receiving end includes the EdgeHub and the MetaManager. The EdgeHub receives the data, caches and reassembles it, and the EdgeCore performs the final operation. At the same time, the confirmation information or status is fed back to the cloud through the Selective Acknowledgment Connection and Feedback (SACK(QUIC)) mechanism, forming a complete control and data exchange closed loop. The MetaManager is responsible for the synchronization and management of metadata throughout the process.
[0056] Regarding the apparatus in the above embodiments, the specific manner in which each unit performs its operation has been described in detail in the embodiments related to the method, and will not be elaborated upon here.
[0057] Based on the above disclosure, the present invention also provides an electronic device. The electronic device of the present disclosure includes at least one processor electrically connected to the processor and at least one memory electrically connected to the processor. The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method steps as executed by the controller above.
[0058] An embodiment of the present invention also provides a storable medium storing computer instructions, which, when executed by a processor, are specifically executed according to the steps in the method described in the above embodiment.
[0059] Finally, it should be noted that the above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing embodiments or make equivalent substitutions for some of the technical features. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.
Claims
1. A cloud-edge asynchronous communication method for a weak network environment, characterized in that, The method comprises: The sending end assigns a serial number to an application layer message to be transmitted; A sending buffer is established, and the application layer messages are sent to the receiving end in sequence based on the serial numbers, and the copies of the sent application layer messages are stored in the sending buffer as to-be-confirmed messages; The receiving end judges the order and reorganizes the serial numbers of the received application layer messages; The receiving end generates selective confirmation information based on the reorganized application layer messages and sends the information to the sending end; Based on the received selective confirmation information, the successfully received application layer messages are identified in the sending buffer, and the lost application layer messages are inferred; The sending end removes the successfully received application layer messages from the sending buffer, removes the confirmed messages from the to-be-confirmed messages in the sending buffer, and re-sends the marked lost application layer messages to the receiving end. 2.The cloud-edge asynchronous communication method for a weak network environment according to claim 1, wherein, Further comprising: After the successfully received application layer messages are removed from the sending buffer at the sending end, the positions of the application layer messages in the application layer sending window are cleared; The application layer sending window corresponding to the removed application layer messages is updated; When the successfully received application layer messages are removed from the sending buffer, the sending end continues to send subsequent application layer messages based on the updated application layer sending window and the serial numbers. 3.The cloud-edge asynchronous communication method for a weak network environment of claim 1, wherein, The order judgment comprises: The serial number of the received application layer message is compared with the maximum serial number of the currently received application layer messages; If the serial number is continuous with the maximum serial number of the received application layer messages, it is determined as an ordered message; If the serial number is greater than the maximum serial number of the continuously received application layer messages but not continuous, it is determined as an out-of-order message.
4. The cloud-edge asynchronous communication method for a weak network environment according to claim 3, characterized in that, The serial number reorganization processing comprises: For the application layer messages determined as ordered, the receiving end transmits them to the application program corresponding to the application layer messages and updates the maximum serial number of the continuously received application layer messages; A receiving buffer is set, and for the application layer messages determined as out-of-order and lost, they are stored in the receiving buffer; After updating the maximum serial number of the continuously received application layer messages, the receiving buffer is checked to determine whether there are continuous serial number application layer messages starting from the maximum serial number application layer message re-entered into the receiving buffer; If there are, the continuous serial number application layer messages are taken out from the receiving buffer, sent to the application program in sequence by the receiving end, and the maximum serial number of the continuously received messages is updated again, and the process is iterated until there are no continuous application layer messages in the receiving buffer; If there are not, the serial number reorganization processing is ended.
5. The cloud-edge asynchronous communication method for a weak network environment according to claim 4, characterized in that, The generation of the application layer selective confirmation information comprises: The maximum serial number of the continuously received application layer messages obtained by the serial number reorganization processing is taken as a cumulative confirmation point; The receiving buffer is scanned, and all the successfully received but non-continuous serial number messages are organized into at least one selective confirmation block, and each selective confirmation block is used to describe a continuous message serial number interval; The cumulative confirmation point and all the selective confirmation blocks are encapsulated to form the application layer selective confirmation information, and the information is sent to the sending end.
6. The cloud-edge asynchronous communication method for a weak network environment according to claim 5, characterized in that, The sending end judges the application layer messages successfully received by the receiving end as the application layer messages with sequence numbers less than or equal to the cumulative confirmation point and the application layer messages in the non-continuous sequence number interval of the application layer messages; Otherwise, the application layer messages are unsuccessfully received.
7. The cloud-edge asynchronous communication method for a weak network environment according to claim 1, wherein, Further comprising: Based on the real-time collected network state parameters, a dynamic timeout algorithm is used to set adaptive timeout time for each to-be-confirmed message, and the collected network state parameters at least include the smooth round-trip time, the round-trip time variance and the packet loss rate of the current network; The confirmation state of the to-be-confirmed message is monitored; If any to-be-confirmed message is not confirmed within the timeout, the to-be-confirmed message is re-sent to the receiving end from the sending buffer area.
8. The cloud-edge asynchronous communication method for a weak network environment according to claim 7, characterized in that, The calculation formula of the dynamic timeout algorithm is: wherein, is an adaptive timeout; Alpha is the basic delay weight coefficient; smooth round trip time for the current network; Beta is the network jitter sensitivity coefficient; Round trip time variance for the current network; Wherein, C(p) is the congestion penalty function with current network packet loss rate p as variable, and the calculation formula is as follows: .
9. The cloud-edge asynchronous communication method for a weak network environment according to claim 8, characterized in that, When calculating the adaptive timeout time, the adaptive timeout time is extended according to the preset priority as follows: wherein, is a scaling factor based on the service priority P, the value rule is: high priority corresponds to <1, medium priority corresponds to =1, low priority corresponds to >
1.
10. The cloud-edge asynchronous communication method for a weak network environment according to claim 9, wherein, When the adaptive timeout time is extended, the minimum timeout protection time is added, and the calculation formula of the minimum timeout protection time is as follows: wherein is the minimum timeout protection time, which has the value rule: wherein, is a minimum round trip time value sampled within a unit time window, is a preset lower limit time value.
11. A cloud-edge asynchronous communication system for a weak network environment, characterized in that, The system comprises a sending end, a receiving end and a dynamic timeout retransmission module, the sending end comprises a message serialization module, a windowed asynchronous transmission module and an analysis module, and the receiving end comprises a confirmation processing and retransmission module, a buffer and recombination module and a selective confirmation information generation module. The message serialization module is used for assigning sequence numbers to the application layer messages to be transmitted; The windowed asynchronous transmission module is used for establishing a sending buffer area, continuously sending the application layer messages to the confirmation processing and retransmission module based on the sequence number order, and storing the copies of the sent application layer messages as to-be-confirmed messages in the sending buffer area; The confirmation processing and retransmission module is used for performing order judgment and sequence number recombination processing on the received application layer messages according to the sequence numbers; The selective confirmation information generation module is used for generating selective confirmation information based on the application layer messages after the sequence number recombination processing and sending the selective confirmation information to the sending end; The analysis module is used for identifying the successfully received application layer messages in the sending buffer area based on the received selective confirmation information, inferring the lost application layer messages, removing the confirmed messages from the to-be-confirmed messages in the sending buffer area by the windowed asynchronous transmission module, and re-sending the marked lost application layer messages to the confirmation processing and retransmission module; The dynamic timeout retransmission module is used for setting adaptive timeout time for each to-be-confirmed message based on the real-time collected network state parameters by using a dynamic timeout algorithm, monitoring the confirmation state of the to-be-confirmed message, and re-sending the to-be-confirmed message to the receiving end from the sending buffer area if any to-be-confirmed message is not confirmed within the timeout.
12. An electronic device, comprising: The electronic device comprises at least one processor and at least one memory, the memory being in data connection with the processor, wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method of any one of claims 1-10.
13. A computer storable medium, characterized by The computer instructions are stored on the storage medium, and when the computer instructions are executed by the processor, the steps in the method of any one of claims 1-10 are specifically executed.