Data forwarding method and device, electronic equipment, storage medium and program product

By establishing a mapping relationship between forwarding priority and buffer area in the Ethernet switch, the problem of data lag under high bandwidth is solved, efficient data forwarding is achieved, and network congestion is avoided.

CN120692241APending Publication Date: 2025-09-23SHANGHAI LIXIANG AUTOMOBILE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410330881.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-03-21
Publication Date
2025-09-23

AI Technical Summary

Technical Problem

In Ethernet switches, when a large amount of data is input in high-bandwidth scenarios, existing technologies require re-ordering forwarding priorities, causing data with lower forwarding priorities to be forwarded later, leading to network congestion.

Method used

By establishing a mapping relationship between forwarding priorities and cache areas, the target cache area is determined and the data to be forwarded is stored and forwarded when the conditions are met, thus avoiding repeated sorting.

Benefits of technology

It improves data forwarding efficiency, solves network congestion problems in high-bandwidth scenarios, ensures that data with the same forwarding priority and the same destination address are forwarded together, and reduces data lag.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120692241A_ABST
    Figure CN120692241A_ABST
Patent Text Reader

Abstract

The invention discloses a data forwarding method and device, electronic equipment, a storage medium and a program product, and relates to the technical field of data processing, and the main technical scheme comprises the following steps: receiving first to-be-forwarded data; determining whether a cache region corresponding to the first forwarding priority exists or not according to a pre-established mapping relationship between forwarding priorities and cache regions; searching a target cache region corresponding to the first target address from the at least two cache regions; storing the first to-be-forwarded data in a target cache region; and when determining that the target cache region meets the target forwarding condition, forwarding all the to-be-forwarded data in the target cache region to the first target address. Compared with the prior art, the embodiment of the invention has the advantages that the to-be-forwarded data with the same forwarding priority and the same target address are forwarded together, the to-be-forwarded data do not need to be subjected to forwarding priority sorting, and the forwarding efficiency of the to-be-forwarded data is improved under the scene that a large amount of to-be-forwarded data needs to be subjected to data forwarding.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of data processing technology, and in particular to a method, device, electronic device, storage medium, and program product for data forwarding. Background Art

[0002] An Ethernet switch is a network device that forwards data based on the Ethernet protocol. It enables communication between different network devices by providing high-speed and reliable data forwarding services.

[0003] In the prior art, an Ethernet switch forwards data by sorting the data according to its forwarding priority, and then forwarding the data in the sorted order.

[0004] In high-bandwidth scenarios, data is continuously input into the Ethernet switch for data forwarding, which can easily cause network congestion. For example, when a large amount of data is transmitted to the Ethernet switch at the same time, the Ethernet switch's processing capacity cannot handle all the data at the same time. The data needs to be sorted by forwarding priority and forwarded in order of forwarding priority. Only when the data with higher priority is successfully sent can the next data be forwarded. When new data is input into the Ethernet switch, the forwarding priority needs to be re-sorted. In this sorting scenario, data with relatively low forwarding priority may always be forwarded with a delay. Summary of the Invention

[0005] The present disclosure provides a data forwarding method and apparatus, an electronic device, and a storage medium. The primary purpose of the present disclosure is to address the issue of re-prioritizing forwarding priorities when new data is input into an Ethernet switch, which can cause data with relatively low forwarding priorities to be consistently forwarded later.

[0006] According to a first aspect of the present disclosure, a method for forwarding data is provided, comprising:

[0007] Receive first data to be forwarded; the first data to be forwarded includes a first destination address and a first forwarding priority;

[0008] determining, based on a pre-established mapping relationship between forwarding priorities and cache areas, whether a cache area corresponding to the first forwarding priority exists;

[0009] In a case where there are at least two cache areas corresponding to the first forwarding priority, searching for a target cache area corresponding to the first target address from the at least two cache areas, where different cache areas corresponding to different priorities are used to store data to be forwarded corresponding to different target addresses;

[0010] Storing the first to-be-forwarded data in the target buffer area;

[0011] When it is determined that the target buffer area meets the target forwarding condition, all the to-be-forwarded data in the target buffer area are forwarded to the first target address.

[0012] Optionally, determining whether the target cache area meets the target forwarding condition includes:

[0013] If the target cache area has a corresponding fixed storage space and the free storage space of the target cache area is less than or equal to the storage space threshold, determining that the target cache area meets the target forwarding condition;

[0014] If a timer exists in the target buffer area and the timer of the target buffer area times out, determining that the target buffer area meets the target forwarding condition;

[0015] If the target cache area has a corresponding fixed storage space and a timer, and the free storage space of the target cache area is less than or equal to the storage space threshold or the timer of the target cache area times out, determining that the target cache area meets the target forwarding condition;

[0016] Different buffer areas have different timers, and different buffer areas have different fixed storage spaces.

[0017] Optionally, the cache area corresponds to a fixed storage space, and searching the at least two cache areas for a target cache area corresponding to the first target address includes:

[0018] A target cache area whose free storage space is larger than the first storage space required by the first data to be forwarded and whose corresponding target address is the same as the first target address is searched from the at least two cache areas.

[0019] Optionally, searching from the at least two cache areas for a target cache area whose free storage space is larger than the first storage space required by the first data to be forwarded and whose corresponding target address is the same as the first target address includes:

[0020] Traversing the free storage space and target address of the at least two buffer areas;

[0021] Determine the first cache area whose free storage space is greater than the storage space threshold and has the same address as the first target address as the target cache area;

[0022] If the unfinded free storage space is greater than the storage space threshold and is the same as the first target address of the cache area, determining the first unused cache area of ​​the at least two cache areas as the target cache area;

[0023] The target address corresponding to the target buffer area is set as a first target address, and when the target buffer area includes a timer, the timer of the target buffer area is started.

[0024] Optionally, after forwarding all the to-be-forwarded data in the target buffer area to the first target address, the method further includes:

[0025] The data to be forwarded in the target buffer area is cleared, the first target address of the target buffer area is deleted, and if a timer exists in the target buffer area, the timer of the target buffer area is turned off.

[0026] Optionally, after determining whether a cache area corresponding to the first forwarding priority exists, the method further includes:

[0027] If there is no cache area corresponding to the first forwarding priority, the first to-be-forwarded data is forwarded to the first target address.

[0028] Optionally, storing the first to-be-forwarded data in the target cache area includes:

[0029] The first to-be-forwarded data is spliced ​​behind the cached to-be-forwarded data in the target cache area for storage.

[0030] According to a second aspect of the present disclosure, a data forwarding device is provided, including:

[0031] A receiving unit, configured to receive first data to be forwarded; the first data to be forwarded includes a first destination address and a first forwarding priority;

[0032] a first determining unit, configured to determine whether a cache area corresponding to the first forwarding priority exists according to a pre-established mapping relationship between forwarding priorities and cache areas;

[0033] a search unit, configured to, when there are at least two cache areas corresponding to the first forwarding priority, search the at least two cache areas for a target cache area corresponding to the first target address, wherein different cache areas corresponding to different priorities are used to store data to be forwarded corresponding to different target addresses;

[0034] a storage unit, configured to store the first to-be-forwarded data in the target buffer area;

[0035] The forwarding unit is configured to forward all the to-be-forwarded data in the target buffer area to the first target address when it is determined that the target buffer area satisfies a target forwarding condition.

[0036] Optionally, the device further includes:

[0037] a second determining unit, configured to determine that the target cache area meets the target forwarding condition if there is a corresponding fixed storage space in the target cache area and the free storage space of the target cache area is less than or equal to a storage space threshold;

[0038] The second determining unit is further configured to, when a timer exists in the target buffer area and the timer of the target buffer area times out, determine that the target buffer area meets the target forwarding condition;

[0039] The second determining unit is further configured to determine that the target cache area meets the target forwarding condition if there is a corresponding fixed storage space and a timer in the target cache area, and the free storage space of the target cache area is less than or equal to the storage space threshold or the timer of the target cache area times out;

[0040] Different buffer areas have different timers, and different buffer areas have different fixed storage spaces.

[0041] Optionally, the cache area corresponds to a fixed storage space, and the search unit includes:

[0042] The search module is configured to search, from the at least two cache areas, for a target cache area whose free storage space is larger than the first storage space required by the first data to be forwarded and whose corresponding target address is the same as the first target address.

[0043] Optionally, the search module is further configured to:

[0044] Traversing the free storage space and target address of the at least two buffer areas;

[0045] Determine the first cache area whose free storage space is greater than the storage space threshold and has the same address as the first target address as the target cache area;

[0046] When the unfindable free storage space is greater than the storage space threshold and is the same as the first target address of the cache area, determining the first unused cache area of ​​the at least two cache areas as the target cache area;

[0047] The target address corresponding to the target buffer area is set as a first target address, and when the target buffer area includes a timer, the timer of the target buffer area is started.

[0048] Optionally, the device further includes:

[0049] A clearing unit is used to clear the data to be forwarded in the target cache area after forwarding all the data to be forwarded in the target cache area to the first target address, delete the first target address of the target cache area, and turn off the timer of the target cache area if there is a timer in the target cache area.

[0050] Optionally, the forwarding unit is further configured to, after determining whether there is a cache area corresponding to the first forwarding priority, forward the first to-be-forwarded data to the first target address if there is no cache area corresponding to the first forwarding priority.

[0051] Optionally, the storage unit further includes:

[0052] The storage module is used to splice the first data to be forwarded behind the cached data to be forwarded in the target buffer area for storage.

[0053] According to a third aspect of the present disclosure, there is provided an electronic device, including:

[0054] at least one processor; and

[0055] a memory communicatively connected to the at least one processor; wherein,

[0056] The memory stores instructions that can be executed by the at least one processor. The instructions are executed by the at least one processor to enable the at least one processor to perform the method described in the first aspect.

[0057] According to a fourth aspect of the present disclosure, a non-transitory computer-readable storage medium storing computer instructions is provided, wherein the computer instructions are used to enable the computer to execute the method described in the first aspect.

[0058] According to a fifth aspect of the present disclosure, a computer program product is provided, comprising a computer program, wherein when the computer program is executed by a processor, the computer program implements the method as described in the first aspect above.

[0059] The data forwarding method, device, electronic device, storage medium and program product provided by the present disclosure receive first data to be forwarded; the first data to be forwarded includes a first target address and a first forwarding priority; based on a pre-established mapping relationship between forwarding priorities and cache areas, determine whether there is a cache area corresponding to the first forwarding priority; when there are at least two cache areas corresponding to the first forwarding priority, search for a target cache area corresponding to the first target address from the at least two cache areas, and different cache areas corresponding to different priorities are used to store data to be forwarded corresponding to different target addresses; store the first data to be forwarded in the target cache area; when it is determined that the target cache area meets the target forwarding condition, forward all data to be forwarded in the target cache area to the first target address. Compared with the related art, the embodiment of the present disclosure determines whether there is a cache area corresponding to the first forwarding priority based on a pre-established mapping relationship between forwarding priorities and cache areas. When there are at least two cache areas corresponding to the first forwarding priority, the target cache area corresponding to the first target address is searched from the at least two cache areas, and the data to be forwarded is stored in the target cache area. When it is determined that the target cache area meets the target forwarding condition, all the data to be forwarded in the target cache area is forwarded to the first target address, thereby forwarding the data to be forwarded with the same forwarding priority and the same target address together, without the need to sort the forwarding priority of the data to be forwarded. In the scenario where a large amount of data to be forwarded needs to be forwarded, the forwarding efficiency of the data to be forwarded is improved.

[0060] It should be understood that the content described in this section is not intended to identify the key or important features of the embodiments of the present application, nor is it intended to limit the scope of the present application. Other features of the present application will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS

[0061] The accompanying drawings are provided to facilitate a better understanding of the present invention and do not constitute a limitation of the present disclosure.

[0062] Figure 1 A flowchart of a data forwarding method provided by an embodiment of the present disclosure;

[0063] Figure 2 A schematic diagram of a forwarding process of data to be forwarded provided in an embodiment of the present disclosure;

[0064] Figure 3 A flowchart of a method for searching a target cache area corresponding to a first target address provided by an embodiment of the present disclosure;

[0065] Figure 4 A schematic diagram of the structure of a data forwarding device provided by an embodiment of the present disclosure;

[0066] Figure 5 A schematic structural diagram of another data forwarding device provided by an embodiment of the present disclosure;

[0067] Figure 6 A schematic block diagram of an exemplary electronic device provided in an embodiment of the present disclosure. DETAILED DESCRIPTION

[0068] The following description of exemplary embodiments of the present disclosure is made in conjunction with the accompanying drawings, including various details of the embodiments of the present disclosure to facilitate understanding. These details should be considered as merely exemplary. Therefore, those skilled in the art will recognize that various changes and modifications may be made to the embodiments described herein without departing from the scope and spirit of the present disclosure. Similarly, for the sake of clarity and conciseness, descriptions of well-known functions and structures are omitted in the following description.

[0069] The following describes the data forwarding method and apparatus, electronic device, and storage medium according to the embodiments of the present disclosure with reference to the accompanying drawings.

[0070] Figure 1 A flowchart of a data forwarding method provided by an embodiment of the present disclosure.

[0071] like Figure 1 As shown, the method is applied to an Ethernet switch and includes the following steps:

[0072] Step 101: Receive first data to be forwarded; the first data to be forwarded includes a first target address and a first forwarding priority.

[0073] An Ethernet switch is a network device used to forward data in a local area network. Both the data receiver and the data sender are connected to the Ethernet switch. The Ethernet switch forwards the data sent by the data sender to the data receiver. The Ethernet switch identifies and forwards the data to be forwarded based on the first destination address in the data to be forwarded, allowing communication between the data sender and the data receiver.

[0074] Among them, the data to be forwarded includes but is not limited to the first target address, the forwarding priority and the target address of the data receiver. The first target address is the target address of the data receiver. The target address of the data sender is used by the data receiver to determine the sender of the data to be forwarded, so that the data receiver can process the data to be forwarded and forward the processed data to the data sender through the Ethernet switch. The data sender and the data receiver can both realize bidirectional data transmission, that is, the data sender can also serve as the data receiver, and the data receiver can also serve as the data sender. Common data senders or data receivers include but are not limited to computers, servers, printers, telephones and video conferencing equipment, network storage devices, and network cameras; the forwarding priority is a virtual local area network priority (VLAN) priority, which is used to prioritize and process the forwarded data in the VLAN. The forwarding priority is contained in the VLAN tag information of the data to be forwarded, occupies 3 bits, and indicates the priority of the data to be forwarded. The higher the forwarding priority, the higher the priority of the forwarded data.

[0075] To facilitate understanding of forwarding priority, an example is provided for illustration. Assume that there are two data to be forwarded, namely, data A to be forwarded and data B to be forwarded. The forwarding priority of data A to be forwarded is 7, and the forwarding priority of data B to be forwarded is 5. Since the forwarding priority of data A to be forwarded is higher than the forwarding priority of data B to be forwarded, the Ethernet switch will give priority to forwarding data A.

[0076] By receiving the data to be forwarded sent by the data sender, the Ethernet switch can forward the data to be forwarded to the data receiver corresponding to the first target address, thereby realizing communication between the data sender and the data receiver. The Ethernet switch can provide reliable and efficient data transmission for the forwarding of the forwarded data, while meeting the network policy and control requirements of the local area network, and improving the security of the forwarded data during the transmission process.

[0077] Step 102: Determine whether there is a cache area corresponding to the first forwarding priority based on a pre-established mapping relationship between forwarding priorities and cache areas.

[0078] The Ethernet switch has different forwarding requirements for data to be forwarded with different forwarding priorities. The data to be forwarded with a higher forwarding priority has a higher priority for forwarding. In order to facilitate the management of data to be forwarded with different forwarding priorities, the data to be forwarded with the same forwarding priority needs to be cached together for management. By assigning a corresponding cache sequence to the forwarding priority, a mapping relationship between the forwarding priority and the cache sequence can be established. The cache sequence contains at least two cache areas, and then a mapping relationship between the forwarding priority and the cache area is established. According to the pre-established mapping relationship between the forwarding priority and the cache area, it is determined whether there is a cache area corresponding to the first forwarding priority. Corresponding cache areas, wherein a cache area can only store data to be forwarded with the same priority and the same address target address. The amount of data to be forwarded stored in a cache area is related to the data volume of the data to be forwarded. For example, the storage space size of the cache area is 10, the data volume of the data to be forwarded A is 3, and the data volume of the data to be forwarded B is 4. The data to be forwarded A and the data to be forwarded B are stored in the cache area, and the remaining storage space of the cache area is 3. If the data volume of the data to be forwarded C is 5, the cache area cannot store the data to be forwarded C. If the data volume of the data to be forwarded C is 3, the cache area can store the data to be forwarded C.

[0079] Each cache sequence includes at least two cache areas. The number of cache areas in different cache sequences can be the same or different and can be set according to actual needs. The embodiment of the present disclosure does not limit the number of cache areas in the cache sequence.

[0080] To facilitate understanding of cache sequences, an example is provided for illustration. Assume that there are four cache sequences, namely, cache sequence a, cache sequence b, cache sequence c, and cache sequence d. The forwarding priority corresponding to cache sequence a is 1, the forwarding priority corresponding to cache sequence b is 2, the forwarding priority corresponding to cache sequence c is 3, and the forwarding priority corresponding to cache sequence d is 4. Generally, lower forwarding priorities result in a greater amount of data to be forwarded, while higher forwarding priorities result in a smaller amount of data to be forwarded. Therefore, cache sequences with lower forwarding priorities require a greater number of buffer zones, while cache sequences with higher forwarding priorities require a smaller number of buffer zones. For example, 20 buffer zones can be set for cache sequence a, 10 buffer zones can be set for cache sequence b, 5 buffer zones can be set for cache sequence c, and 1 buffer zone can be set for cache sequence d. Since the amount of data to be forwarded with higher forwarding priorities is smaller, corresponding cache sequences may not be assigned to higher forwarding priorities. When data to be forwarded with higher forwarding priorities is sent to the Ethernet switch, the data to be forwarded is directly forwarded. However, it should be understood that this statement does not limit the assignment of corresponding cache sequences to higher forwarding priorities. Alternatively, corresponding cache sequences may be assigned.

[0081] By searching the target cache sequence corresponding to the forwarding priority, the data to be forwarded with the same forwarding priority can be stored in the target cache sequence, thereby achieving independent management and processing of the data to be forwarded with different forwarding priorities and improving the processing efficiency of the data to be forwarded.

[0082] Step 103: When there are at least two cache areas corresponding to the first forwarding priority, search for the target cache area corresponding to the first target address from the at least two cache areas, and different cache areas corresponding to different priorities are used to store the data to be forwarded corresponding to different target addresses.

[0083] The first target addresses of the data to be forwarded of the same priority may be different. In order to facilitate the management of the data to be forwarded, it is necessary to search the target cache area corresponding to the first target address from the at least two cache areas. Different cache areas corresponding to different priorities are used to store the data to be forwarded corresponding to different target addresses, so that the data to be forwarded can be stored in the target cache area. All the data to be forwarded stored in the target cache area can be forwarded together to the data recipient corresponding to the first target address, thereby improving the forwarding efficiency of the data to be forwarded.

[0084] Step 104: Store the first data to be forwarded in the target buffer area.

[0085] Storing the data to be forwarded in the target buffer area can achieve cache management of the data to be forwarded, avoid loss or retransmission of the data to be forwarded, and improve the reliability and stability of the data transmission to be forwarded.

[0086] Step 105: When it is determined that the target buffer area meets the target forwarding condition, all the to-be-forwarded data in the target buffer area are forwarded to the first target address.

[0087] When it is determined that the target cache area meets the target forwarding condition, there are three situations in which all the data to be forwarded in the target cache area is forwarded to the first target address. One is that when there is a corresponding fixed storage space in the target cache area and the free storage space of the target cache area is less than or equal to the storage space threshold, it is determined that the target cache area meets the target forwarding condition, and all the data to be forwarded in the target cache area is forwarded to the data recipient through the port corresponding to the first target address. The free storage space is the unused storage space in the target cache area. The storage space threshold can be any value, which is not limited in the embodiment of the present disclosure.

[0088] In order to facilitate understanding that when the free storage space of the target cache area is less than or equal to the storage space threshold, all the data to be forwarded in the target cache area is forwarded to the first target address, an example is provided for illustration. Assuming that the storage space of the target cache area is 10, the free storage space is 10, and the storage space threshold is 2, the data to be forwarded A is stored in the target cache area, and the data size of the data to be forwarded A is 6, and the data to be forwarded B is stored in the target cache area, and the data size of the data to be forwarded B is 3. The sum of the data sizes of the data to be forwarded A and the data to be forwarded B is 9. At this time, the free storage space of the target cache area is updated to 1, and the free storage space is less than the storage space threshold. All the data to be forwarded in the target cache area needs to be forwarded to the first target address.

[0089] Another situation in which all the data to be forwarded in the target cache area is forwarded to the first target address when it is determined that the target cache area meets the target forwarding condition is that when there is a timer in the target cache area and the timer of the target cache area times out, it is determined that the target cache area meets the target forwarding condition, and all the data to be forwarded in the target cache area are forwarded to the data recipient through the port corresponding to the first target address, wherein the timing start time of the timer is the time when the first data to be forwarded is stored in the target cache area, wherein the timer timeout of the cache area in the cache sequence with different forwarding priorities may be different. Since the data to be forwarded with a higher forwarding priority needs to be forwarded faster, the timer timeout of the cache area in the cache sequence with a lower forwarding priority is smaller, and the timer timeout of the cache area in the cache sequence with a higher forwarding priority is larger. For example, the timer timeout of the cache area in the cache sequence with a forwarding priority of 1 is 1000us, the timer timeout of the cache area in the cache sequence with a forwarding priority of 2 is 500us, and the timer timeout of the cache area in the cache sequence with a forwarding priority of 3 is 100us.

[0090] Another situation in which all the data to be forwarded in the target cache area is forwarded to the first target address when it is determined that the target cache area meets the target forwarding condition is that when there is a corresponding fixed storage space and a timer in the target cache area, and the free storage space of the target cache area is less than or equal to the storage space threshold or the timer of the target cache area times out, it is determined that the target cache area meets the target forwarding condition, and all the data to be forwarded in the target cache area is forwarded to the data recipient through the port corresponding to the first target address.

[0091] In order to better understand the forwarding process of the forwarded data, Figure 2 As shown, Figure 2A schematic diagram of a forwarding process of data to be forwarded provided in an embodiment of the present disclosure, wherein the data to be forwarded is stored in a corresponding target cache area through the first target address and forwarding priority in the data to be forwarded, and when it is determined that the target cache area meets the target forwarding condition, all the data to be forwarded in the target cache area are forwarded to the first target address. Data transmission is divided into two types, one is unicast, which refers to sending data to a data receiving party in the data sending direction, that is, there is only one first target address in the data to be forwarded, and the other is broadcast, which refers to sending data to multiple data receiving parties in the data sending direction, that is, there are multiple first target addresses in the data to be forwarded.

[0092] The data forwarding method provided by the present disclosure receives first data to be forwarded; the first data to be forwarded includes a first target address and a first forwarding priority; based on a pre-established mapping relationship between forwarding priorities and cache areas, determines whether there is a cache area corresponding to the first forwarding priority; in the case where there are at least two cache areas corresponding to the first forwarding priority, searches for a target cache area corresponding to the first target address from the at least two cache areas, and different cache areas corresponding to different priorities are used to store data to be forwarded corresponding to different target addresses; stores the first data to be forwarded in the target cache area; when it is determined that the target cache area meets the target forwarding condition, forwards all data to be forwarded in the target cache area to the first target address. Compared with the related art, the embodiment of the present disclosure determines whether there is a cache area corresponding to the first forwarding priority based on a pre-established mapping relationship between forwarding priorities and cache areas. When there are at least two cache areas corresponding to the first forwarding priority, the target cache area corresponding to the first target address is searched from the at least two cache areas, and the data to be forwarded is stored in the target cache area. When it is determined that the target cache area meets the target forwarding condition, all the data to be forwarded in the target cache area is forwarded to the first target address, thereby forwarding the data to be forwarded with the same forwarding priority and the same target address together, without the need to sort the forwarding priority of the data to be forwarded. In the scenario where a large amount of data to be forwarded needs to be forwarded, the forwarding efficiency of the data to be forwarded is improved.

[0093] As a refinement of step 105, when the target cache area forwards the data to be forwarded, it is necessary to meet the target forwarding condition. When there is a corresponding fixed storage space in the target cache area and the free storage space of the target cache area is less than or equal to the storage space threshold, it is determined that the target cache area meets the target forwarding condition; when there is a timer in the target cache area and the timer of the target cache area times out, it is determined that the target cache area meets the target forwarding condition; when there is a corresponding fixed storage space and a timer in the target cache area, and the free storage space of the target cache area is less than or equal to the storage space threshold or the timer of the target cache area times out, it is determined that the target cache area meets the target forwarding condition; different cache areas have different timers and different cache areas have different fixed storage spaces; the embodiment of the present disclosure can release storage space and process the data to be forwarded in a timely manner at an appropriate time, and effectively manage the forwarding and storage of the data to be forwarded. At the same time, different cache areas can use different timer and storage space settings according to specific circumstances to meet their respective needs.

[0094] As a refinement of step 103, when executing the search for the target cache area corresponding to the first target address from the at least two cache areas, it can be implemented in but not limited to the following manner: searching from the at least two cache areas for a target cache area whose free storage space is greater than the first storage space required by the first data to be forwarded, and whose corresponding target address is the same as the first target address.

[0095] To facilitate understanding, an example is provided. Suppose there are two cache areas, namely a and b, the free storage space of a is 3, the free storage space of b is 1, the storage space threshold is 2, the target address of a is A, the target address of b is B, and the first target address of the first data to be forwarded is A, then the first data to be forwarded is stored in a.

[0096] By searching for a target cache area whose free storage space is greater than the storage space threshold and has the same target address as the first target, the utilization rate of the cache area is improved, and the data to be forwarded with the same target address is stored in the same cache area, so that all the data to be forwarded in the cache area can be forwarded to the same target address, thereby improving the efficiency of data forwarding.

[0097] As a refinement of the above embodiment, when searching for a target cache area whose free storage space is larger than the first storage space required by the first data to be forwarded and whose corresponding target address is the same as the first target address from the at least two cache areas, the following methods may be used but are not limited to achieve the above: Figure 3 As shown, Figure 3A flowchart of a method for searching a target cache area corresponding to a first target address provided in an embodiment of the present disclosure includes:

[0098] Step 201: traverse the free storage space and target addresses of the at least two cache areas.

[0099] By obtaining the free storage space of the cache area, we can understand the free storage space size of each cache area, and determine which cache areas have enough space to store the data to be forwarded. Selecting a cache area with sufficient space to store the data to be forwarded can ensure that the data can be stored completely and avoid data loss or damage. By obtaining the target address of the cache area, the data to be forwarded with the same target address can be stored in one cache area, thereby improving the efficiency of data storage and transmission and ensuring data reliability.

[0100] Step 202: Determine the first cache area found to have free storage space greater than the storage space threshold and the same as the first target address as the target cache area.

[0101] By searching for the first cache area whose free storage space is greater than the storage space threshold and is the same as the first target address, a cache area with sufficient free storage space can be found. This can ensure that the data to be forwarded can be completely stored in a certain cache area, avoiding data loss or truncation. By using the first cache area whose free storage space is greater than the storage space threshold and is the same as the first target address as the target cache area, the situation of scattered data storage can be reduced and the utilization rate of the storage space of the cache area can be improved.

[0102] Step 203: If the unfinded free storage space is greater than the storage space threshold and is the same as the first target address of the cache area, the first unused cache area among the at least two cache areas is determined as the target cache area.

[0103] After traversing the free storage space and target addresses of the at least two cache areas, there may be a cache area whose free storage space is greater than the storage space threshold and is the same as the first target address that has not been found. In order to store the first data to be forwarded in the cache area, if the free storage space of the at least two cache areas that is greater than the storage space threshold and is the same as the first target address that has not been found, the first unused cache area among the at least two cache areas is determined as the target cache area. By determining the first unused cache area among the at least two cache areas as the target cache area, a situation where there is no target cache area for the data to be forwarded can be avoided. For example, when the Ethernet switch is just running and receives the first data to be forwarded, all the cache areas in the Ethernet switch do not store the data to be forwarded. Therefore, the second target address cannot be set for the cache area, and the corresponding second target address cannot be matched for the first target address. It is necessary to use the first cache area in the cache sequence with the same forwarding priority as the data to be forwarded as the target cache area for the first target address so that the data to be forwarded can be stored in the target cache area.

[0104] Step 204 : Set the target address corresponding to the target buffer area as a first target address, and start the timer of the target buffer area if the target buffer area includes a timer.

[0105] Since the data to be forwarded is the first data to be cached in the target cache area, the first target address of the data to be cached needs to be set as the target address of the target cache area, and the timer of the target cache area starts timing.

[0106] In actual applications, after all the data to be forwarded in the target cache area are forwarded to the first target address, the target cache area still needs to continue to store other data to be cached. Since all the data to be forwarded in the target cache area have been forwarded to the first target address, the data to be forwarded in the target cache area needs to be cleared, and the first target address of the target cache area needs to be deleted. If there is a timer in the target cache area, the timer of the target cache area is turned off so as to reuse the target cache area and improve the utilization rate of the target cache area. For example, after all the data to be forwarded with the target address DEST1 stored in the target cache area is forwarded to DEST1, all the data in the target cache area is cleared and can be used to store the data to be forwarded with the target address DEST2.

[0107] In actual applications, after determining whether there is a cache area corresponding to the first forwarding priority, when the first forwarding priority is the highest forwarding priority, it means that the first data to be forwarded needs to be forwarded as soon as possible. At this time, there is no corresponding cache area for the first forwarding priority, and there is no timer. The first data to be forwarded is directly forwarded to the first target address, which can improve the forwarding efficiency of the first data to be forwarded corresponding to the highest forwarding priority.

[0108] As a refinement of step 104, the target cache area needs to meet the target forwarding condition when forwarding the data to be forwarded. When the free storage space of the target cache area after storage is less than or equal to the storage space threshold, it is determined that the target cache area after storage meets the target forwarding condition, or when the timer of the target cache area after storage times out, it is determined that the target cache area after storage meets the target forwarding condition, or when the free storage space of the target cache area after storage is less than or equal to the storage space threshold and the timer of the target cache area after storage times out, it is determined that the target cache area after storage meets the target forwarding condition. These three scenarios can all be used to determine that the target cache area after storage meets the target forwarding condition, different cache areas correspond to different timers, and different cache areas correspond to different forwarding conditions.

[0109] As a refinement of step 103, when executing the step of storing the data to be forwarded in the target cache area, it can be implemented in the following manner but is not limited to: splicing the first data to be forwarded behind the cached data to be forwarded in the target cache area for storage, which can prevent storage gaps from being generated in the table cache area and improve the utilization rate of the storage space of the target cache area, wherein the cached data is the data to be forwarded that has been stored in the target cache area; for example, assuming that some data to be forwarded, such as: A, B and C, has been stored in the target cache area, and now D needs to be stored in the target cache area, by splicing D behind A, B and C respectively, a new data sequence, namely A, B, C, D, is formed.

[0110] To facilitate a better understanding of the entire data forwarding process, an example is provided for illustration. When multiple data to be stored arrive at the Ethernet switch at the same time, the data to be stored with the same priority and the same first destination address are stored in the same cache area. When the amount of data to be forwarded in the cache area reaches a preset data amount threshold or the release time of the cache area reaches a preset time threshold, all the data to be forwarded in the cache area are sent to the corresponding port at one time, and the data to be forwarded is forwarded to the data receiver through the port. After receiving the data to be forwarded, the data receiver verifies whether the first destination address of the data to be forwarded matches the data receiver's own destination address, and determines whether to receive the data to be forwarded. After receiving the data to be forwarded, the data receiver performs corresponding packet processing, and all messages are processed at one time.

[0111] In summary, the embodiments of the present disclosure can achieve the following effects:

[0112] 1. The embodiment of the present disclosure determines whether there is a cache area corresponding to the first forwarding priority based on a pre-established mapping relationship between forwarding priorities and cache areas. When there are at least two cache areas corresponding to the first forwarding priority, the target cache area corresponding to the first target address is searched from the at least two cache areas, and the data to be forwarded is stored in the target cache area. When it is determined that the target cache area meets the target forwarding condition, all the data to be forwarded in the target cache area is forwarded to the first target address, thereby forwarding the data to be forwarded with the same forwarding priority and the same target address together without sorting the forwarding priority of the data to be forwarded. In the scenario where a large amount of data to be forwarded needs to be forwarded, the forwarding efficiency of the data to be forwarded is improved.

[0113] 2. The disclosed embodiments solve the problem of network congestion that is prone to occur in Ethernet switches when the bandwidth is high, avoid the situation where data to be forwarded is always forwarded with a delay, and alleviate the problem of excessive data processing frequency and high CPU load between the Ethernet switch and the data receiver in high-bandwidth scenarios.

[0114] Corresponding to the above-mentioned data forwarding method, the present invention also provides a data forwarding device. Since the device embodiment of the present invention corresponds to the above-mentioned method embodiment, details not disclosed in the device embodiment can be referred to the above-mentioned method embodiment and will not be repeated in the present invention.

[0115] Figure 4 A schematic diagram of the structure of a data forwarding device provided in an embodiment of the present disclosure is shown in FIG. Figure 4 As shown, the device is applied to an Ethernet switch, including:

[0116] The receiving unit 31 is configured to receive first data to be forwarded; the first data to be forwarded includes a first destination address and a first forwarding priority;

[0117] A first determining unit 32 is configured to determine whether there is a cache area corresponding to the first forwarding priority according to a pre-established mapping relationship between forwarding priorities and cache areas;

[0118] a search unit 33 configured to, when there are at least two cache areas corresponding to the first forwarding priority, search the at least two cache areas for a target cache area corresponding to the first target address, wherein different cache areas corresponding to different priorities are used to store data to be forwarded corresponding to different target addresses;

[0119] a storage unit 34, configured to store the first to-be-forwarded data in the target buffer area;

[0120] The forwarding unit 35 is configured to forward all the to-be-forwarded data in the target buffer area to the first target address when it is determined that the target buffer area meets the target forwarding condition.

[0121] The data forwarding device provided by the present disclosure receives first data to be forwarded; the first data to be forwarded includes a first target address and a first forwarding priority; based on a pre-established mapping relationship between forwarding priorities and cache areas, determines whether there is a cache area corresponding to the first forwarding priority; in the case where there are at least two cache areas corresponding to the first forwarding priority, searches for a target cache area corresponding to the first target address from the at least two cache areas, and different cache areas corresponding to different priorities are used to store data to be forwarded corresponding to different target addresses; when it is determined that the target cache area meets the target forwarding condition, all data to be forwarded in the target cache area are forwarded to the first target address. Compared with the related art, the embodiment of the present disclosure determines whether there is a cache area corresponding to the first forwarding priority based on a pre-established mapping relationship between forwarding priorities and cache areas. When there are at least two cache areas corresponding to the first forwarding priority, the target cache area corresponding to the first target address is searched from the at least two cache areas, and the data to be forwarded is stored in the target cache area. When it is determined that the target cache area meets the target forwarding condition, all the data to be forwarded in the target cache area is forwarded to the first target address, thereby forwarding the data to be forwarded with the same forwarding priority and the same target address together, without the need to sort the forwarding priority of the data to be forwarded. In the scenario where a large amount of data to be forwarded needs to be forwarded, the forwarding efficiency of the data to be forwarded is improved.

[0122] Furthermore, in a possible implementation of this embodiment, as Figure 5 As shown, the device also includes:

[0123] A second determining unit 36 ​​is configured to determine that the target cache area meets the target forwarding condition if there is a corresponding fixed storage space in the target cache area and the free storage space of the target cache area is less than or equal to the storage space threshold;

[0124] The second determining unit 36 ​​is further configured to, when a timer exists in the target buffer area and the timer of the target buffer area times out, determine that the target buffer area meets the target forwarding condition;

[0125] The second determining unit 36 ​​is further configured to determine that the target cache area meets the target forwarding condition if there is a corresponding fixed storage space and a timer in the target cache area, and the free storage space of the target cache area is less than or equal to the storage space threshold or the timer of the target cache area times out;

[0126] Different buffer areas have different timers, and different buffer areas have different fixed storage spaces.

[0127] Furthermore, in a possible implementation of this embodiment, as Figure 5 As shown, the cache area corresponds to a fixed storage space, and the search unit 33 includes:

[0128] The search module 331 is configured to search, from the at least two cache areas, for a target cache area whose free storage space is larger than the first storage space required by the first data to be forwarded and whose corresponding target address is the same as the first target address.

[0129] Furthermore, in a possible implementation of this embodiment, as Figure 5 As shown, the search module 331 is also used to:

[0130] Traversing the free storage space and target address of the at least two buffer areas;

[0131] Determine the first cache area whose free storage space is greater than the storage space threshold and has the same address as the first target address as the target cache area;

[0132] When the unfindable free storage space is greater than the storage space threshold and is the same as the first target address of the cache area, determining the first unused cache area of ​​the at least two cache areas as the target cache area;

[0133] The target address corresponding to the target buffer area is set as a first target address, and when the target buffer area includes a timer, the timer of the target buffer area is started.

[0134] Furthermore, in a possible implementation of this embodiment, as Figure 5 As shown, the device also includes:

[0135] The clearing unit 37 is used to clear the data to be forwarded in the target cache area after forwarding all the data to be forwarded in the target cache area to the first target address, delete the first target address of the target cache area, and turn off the timer of the target cache area if there is a timer in the target cache area.

[0136] Furthermore, in a possible implementation of this embodiment, as Figure 5 As shown, the forwarding unit 35 is further configured to, after determining whether there is a cache area corresponding to the first forwarding priority, forward the first to-be-forwarded data to the first target address if there is no cache area corresponding to the first forwarding priority.

[0137] Furthermore, in a possible implementation of this embodiment, as Figure 5 As shown, the storage unit 34 also includes:

[0138] The storage module 341 is configured to concatenate the first data to be forwarded behind the cached data to be forwarded in the target buffer area for storage.

[0139] It should be noted that the above explanation of the method embodiment is also applicable to the device of the embodiment of the present disclosure, and the principles are the same, which is no longer limited in the embodiment of the present disclosure.

[0140] According to an embodiment of the present disclosure, the present disclosure also provides an electronic device, a readable storage medium, and a computer program product.

[0141] Figure 6 A schematic block diagram of an example electronic device 400 that can be used to implement embodiments of the present disclosure is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital assistants, cellular phones, smartphones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are provided as examples only and are not intended to limit the implementation of the present disclosure described and / or claimed herein.

[0142] like Figure 6As shown, the device 400 includes a computing unit 401, which can perform various appropriate actions and processes according to a computer program stored in a ROM (Read-Only Memory) 402 or a computer program loaded from a storage unit 408 into a RAM (Random Access Memory) 403. Various programs and data required for the operation of the device 400 can also be stored in the RAM 403. The computing unit 401, the ROM 402, and the RAM 403 are connected to each other via a bus 404. An I / O (Input / Output) interface 405 is also connected to the bus 404.

[0143] Various components in device 400 are connected to I / O interface 405, including an input unit 406, such as a keyboard, mouse, etc.; an output unit 407, such as various types of displays, speakers, etc.; a storage unit 408, such as a magnetic disk, optical disk, etc.; and a communication unit 409, such as a network card, modem, wireless communication transceiver, etc. Communication unit 409 allows device 400 to exchange information / data with other devices via a computer network such as the Internet and / or various telecommunication networks.

[0144] The computing unit 401 can be a variety of general-purpose and / or specialized processing components with processing and computing capabilities. Some examples of the computing unit 401 include, but are not limited to, a CPU (Central Processing Unit), a GPU (Graphic Processing Unit), various specialized AI (Artificial Intelligence) computing chips, various computing units that run machine learning model algorithms, a DSP (Digital Signal Processor), and any suitable processor, controller, microcontroller, etc. The computing unit 401 performs the various methods and processes described above, such as the data forwarding method. For example, in some embodiments, the data forwarding method can be implemented as a computer software program that is tangibly embodied in a machine-readable medium, such as the storage unit 408. In some embodiments, part or all of the computer program can be loaded and / or installed on the device 400 via the ROM 402 and / or the communication unit 409. When the computer program is loaded into the RAM 403 and executed by the computing unit 401, one or more steps of the method described above can be performed. Alternatively, in other embodiments, the computing unit 401 may be configured to execute the aforementioned data forwarding method in any other appropriate manner (for example, by means of firmware).

[0145] Various embodiments of the systems and techniques described herein can be implemented in digital electronic circuit systems, integrated circuit systems, FPGAs (Field Programmable Gate Arrays), ASICs (Application-Specific Integrated Circuits), ASSPs (Application Specific Standard Products), SOCs (System on Chips), CPLDs (Complex Programmable Logic Devices), computer hardware, firmware, software, and / or combinations thereof. These various embodiments can include being implemented in one or more computer programs that are executable and / or interpreted on a programmable system that includes at least one programmable processor, which can be a special-purpose or general-purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.

[0146] The program code for implementing the method of the present disclosure can be written in any combination of one or more programming languages. These program codes can be provided to a processor or controller of a general-purpose computer, a special-purpose computer, or other programmable data processing device so that when the program code is executed by the processor or controller, the functions / operations specified in the flow chart and / or block diagram are implemented. The program code can be executed entirely on the machine, partially on the machine, as a stand-alone software package, partially on the machine and partially on a remote machine, or entirely on a remote machine or server.

[0147] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or apparatus. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or apparatus, or any suitable combination of the foregoing. More specific examples of machine-readable storage media may include an electrical connection based on one or more wires, a portable computer disk, a hard disk, RAM, ROM, EPROM (Electrically Programmable Read-Only-Memory) or flash memory, optical fiber, CD-ROM (Compact Disc Read-Only Memory), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0148] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device (e.g., a CRT (Cathode-Ray Tube) or LCD (Liquid Crystal Display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user can provide input to the computer. Other types of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).

[0149] The systems and techniques described herein can be implemented in a computing system that includes backend components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes frontend components (e.g., a user computer with a graphical user interface or web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such backend components, middleware components, or frontend components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: LAN (Local Area Network), WAN (Wide Area Network), the Internet, and blockchain networks.

[0150] A computer system may include a client and a server. The client and server are generally remote from each other and typically interact via a communication network. This client-server relationship is established by computer programs running on the respective computers, establishing a client-server relationship. The server may be a cloud server, also known as a cloud computing server or cloud host, a host product within the cloud computing service ecosystem that addresses the management difficulties and limited scalability of traditional physical hosts and VPS services ("Virtual Private Servers" or simply "VPS"). The server may also be a server in a distributed system or a server integrated with blockchain.

[0151] It's important to note that artificial intelligence (AI) is the study of how computers can simulate certain human thought processes and intelligent behaviors (such as learning, reasoning, thinking, and planning). This encompasses both hardware and software technologies. AI hardware technologies generally include sensors, specialized AI chips, cloud computing, distributed storage, and big data processing. AI software technologies primarily encompass computer vision, speech recognition, natural language processing, machine learning / deep learning, big data processing, and knowledge graphs.

[0152] It should be understood that the various forms of the processes shown above can be used to reorder, add, or delete steps. For example, the steps described in this disclosure can be performed in parallel, sequentially, or in a different order, as long as the desired results of the technical solutions disclosed in this disclosure can be achieved. This is not limited herein.

[0153] The above specific embodiments do not constitute a limitation on the scope of protection of this disclosure. Those skilled in the art will appreciate that various modifications, combinations, sub-combinations, and substitutions may be made based on design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this disclosure shall be included within the scope of protection of this disclosure.

Claims

1. A data forwarding method, characterized in that: include: receiving first data to be forwarded; The first data to be forwarded includes a first target address and a first forwarding priority; determining, based on a pre-established mapping relationship between forwarding priorities and cache areas, whether a cache area corresponding to the first forwarding priority exists; In a case where there are at least two cache areas corresponding to the first forwarding priority, searching for a target cache area corresponding to the first target address from the at least two cache areas, where different cache areas corresponding to different priorities are used to store data to be forwarded corresponding to different target addresses; Storing the first to-be-forwarded data in the target buffer area; When it is determined that the target buffer area meets the target forwarding condition, all the to-be-forwarded data in the target buffer area are forwarded to the first target address.

2. The method according to claim 1, characterized in that Determining that the target cache area meets the target forwarding condition includes: If the target cache area has a corresponding fixed storage space and the free storage space of the target cache area is less than or equal to the storage space threshold, determining that the target cache area meets the target forwarding condition; If a timer exists in the target buffer area and the timer of the target buffer area times out, determining that the target buffer area meets the target forwarding condition; If the target cache area has a corresponding fixed storage space and a timer, and the free storage space of the target cache area is less than or equal to the storage space threshold or the timer of the target cache area times out, determining that the target cache area meets the target forwarding condition; Different buffer areas have different timers, and different buffer areas have different fixed storage spaces.

3. The method according to claim 1 or 2, characterized in that The cache area corresponds to a fixed storage space, and searching the at least two cache areas for a target cache area corresponding to the first target address includes: A target cache area whose free storage space is larger than the first storage space required by the first data to be forwarded and whose corresponding target address is the same as the first target address is searched from the at least two cache areas.

4. The method according to claim 3, characterized in that The searching, from the at least two buffer areas, for a target buffer area having a free storage space larger than the first storage space required by the first data to be forwarded and a corresponding target address identical to the first target address includes: Traversing the free storage space and target address of the at least two buffer areas; Determine the first cache area whose free storage space is greater than the storage space threshold and has the same address as the first target address as the target cache area; If the unfinded free storage space is greater than the storage space threshold and is the same as the first target address of the cache area, determining the first unused cache area of ​​the at least two cache areas as the target cache area; The target address corresponding to the target buffer area is set as a first target address, and when the target buffer area includes a timer, the timer of the target buffer area is started.

5. The method according to claim 1, wherein After forwarding all the to-be-forwarded data in the target buffer area to the first target address, the method further includes: The data to be forwarded in the target buffer area is cleared, the first target address of the target buffer area is deleted, and if a timer exists in the target buffer area, the timer of the target buffer area is turned off.

6. The method according to claim 1, characterized in that After determining whether there is a cache area corresponding to the first forwarding priority, the method further includes: If there is no cache area corresponding to the first forwarding priority, the first to-be-forwarded data is forwarded to the first target address.

7. The method according to claim 1, characterized in that The storing the first to-be-forwarded data in the target buffer area includes: The first to-be-forwarded data is spliced ​​behind the cached to-be-forwarded data in the target cache area for storage.

8. A data forwarding device, characterized in that: include: A receiving unit, configured to receive first data to be forwarded; The first data to be forwarded includes a first target address and a first forwarding priority; a first determining unit, configured to determine whether a cache area corresponding to the first forwarding priority exists according to a pre-established mapping relationship between forwarding priorities and cache areas; a search unit, configured to, when there are at least two cache areas corresponding to the first forwarding priority, search the at least two cache areas for a target cache area corresponding to the first target address, wherein different cache areas corresponding to different priorities are used to store data to be forwarded corresponding to different target addresses; a storage unit, configured to store the first to-be-forwarded data in the target buffer area; The forwarding unit is configured to forward all the to-be-forwarded data in the target buffer area to the first target address when it is determined that the target buffer area satisfies a target forwarding condition.

9. An electronic device, characterized in that: include: at least one processor; as well as a memory communicatively connected to the at least one processor; wherein, 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 according to any one of claims 1 to 7.

10. A non-transitory computer-readable storage medium storing computer instructions, characterized in that: The computer instructions are used to cause the computer to execute the method according to any one of claims 1 to 7.

11. A computer program product, characterized in that The invention comprises a computer program which, when executed by a processor, implements the method according to any one of claims 1 to 7.