Flow control method and device

By decapsulating the frame structure and identifying service types of data packets in the distributed on-board switching equipment of the low-orbit satellite Internet, and using matching token buckets for flow control, the network congestion problem caused by excessive sudden business volume is solved. Efficient data transmission and communication quality assurance for priority services are achieved.

CN118740749APending Publication Date: 2024-10-01CHONGQING SATELLITE NETWORK SYSTEM CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202310316571.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-03-28
Publication Date
2024-10-01

AI Technical Summary

Technical Problem

In low-orbit satellite Internet distributed onboard switching equipment, data flow control is difficult to cope with network congestion caused by excessive sudden business volume. The traditional token bucket algorithm cannot guarantee the communication quality of high-priority services and the absolute occupation of bandwidth resources.

Method used

Propose a flow control method that decapsulates the frame structure of received data packets, identifies the service type, and uses matching token buckets for flow control to achieve targeted and refined flow control and avoid uniform data flow. ization to improve the quality of data transmission.

Benefits of technology

It effectively avoids network congestion, meets the needs of different services, improves data transmission quality, and ensures the communication quality of high-priority services and the absolute occupation of bandwidth resources.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118740749A_ABST
    Figure CN118740749A_ABST
Patent Text Reader

Abstract

The invention provides a flow control method and device, and the method comprises the steps: carrying out the decapsulation of a received data package according to a set frame structure, so as to obtain a first data frame, carrying out the discrimination of the first data frame, so as to determine the business type of the first data frame, and to determine the business type of the first data frame; performing first flow control on the first data frame by adopting a first token bucket matched with the service type of the first data frame so as to determine whether the first data frame passes the first flow control or not; and when the first data frame passes through the first flow control, the second token bucket matched with each piece of service data in the first data frame is adopted to perform second flow control on each piece of service data in the first data frame, so that network congestion caused by excessive burst service volume can be avoided, meanwhile, the uniformity of data flow control can be avoided, and the user experience is improved. And the data transmission quality is improved, so that the user requirements can be better met.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of satellite communication technology, and in particular to a flow control method and device. Background Art

[0002] At present, in the distributed onboard switching equipment of low-orbit satellite Internet, onboard switching equipment is required to forward data. Due to the limited switching capacity of onboard switching equipment, data flow needs to be controlled when forwarding data. However, when a large amount of data bursts out at each port of the onboard switching equipment at the same time, it may exceed the switching capacity of the onboard switching equipment, causing congestion of the onboard switching equipment and affecting normal message forwarding. Therefore, in order to avoid congestion of the onboard switching equipment, it is very important to control the data flow. Summary of the invention

[0003] The present disclosure aims to solve one of the technical problems in the related art at least to some extent.

[0004] To this end, the first purpose of the present disclosure is to propose a flow control method and device, so as to realize decapsulation of a received data packet according to a set frame structure to obtain a first data frame, to identify the first data frame, to determine the service type to which the first data frame belongs, and to perform a first flow control on the first data frame using a first token bucket matching the service type of the first data frame to determine whether the first data frame passes the first flow control; when the first data frame passes the first flow control, a second token bucket matching each service data in the first data frame is used to perform a second flow control on each service data in the first data frame, thereby, when forwarding data, the set frame structure can be used to decapsulate the forwarded data to generate a first data frame, and the first data frame is identified to determine the service type of the forwarded data, and a flow control strategy matching the service type of the forwarded data is used to perform flow control on the forwarded data in a targeted and refined manner, thereby meeting the needs of different services, and avoiding network congestion caused by excessive burst business volume, while also avoiding the uniformity of data flow control, thereby improving the quality of data transmission, so as to better meet user needs.

[0005] The second objective of the present disclosure is to provide a flow control device.

[0006] A third objective of the present disclosure is to provide an electronic device.

[0007] A fourth objective of the present disclosure is to provide a computer-readable storage medium.

[0008] A fifth object of the present disclosure is to provide a computer program product.

[0009] To achieve the above-mentioned purpose, the first aspect of the present disclosure proposes a flow control method, including: decapsulating the received data packet according to the set frame structure to obtain a first data frame; distinguishing the first data frame to determine the service type to which the first data frame belongs; using a first token bucket matching the service type of the first data frame to perform a first flow control on the first data frame to determine whether the first data frame passes the first flow control; when the first data frame passes the first flow control, using a second token bucket matching each service data in the first data frame to perform a second flow control on each service data in the first data frame.

[0010] The flow control method of the disclosed embodiment decapsulates the received data packet according to the set frame structure to obtain the first data frame; discriminates the first data frame to determine the service type to which the first data frame belongs; uses the first token bucket matching the service type of the first data frame to perform the first flow control on the first data frame to determine whether the first data frame passes the first flow control; when the first data frame passes the first flow control, uses the second token bucket matching the service data in the first data frame to perform the second flow control on the service data in the first data frame. Thus, when forwarding data, the forwarding data can be decapsulated using the set frame structure to generate the first data frame, and the first data frame can be discriminated to determine the service type of the forwarding data, and the flow control strategy matching the service type of the forwarding data is used to control the forwarding data in a targeted and refined manner, so as to meet the needs of different services, and avoid network congestion caused by excessive burst traffic, and at the same time avoid the uniformity of data flow control, improve the data transmission quality, and better meet the needs of users.

[0011] To achieve the above-mentioned purpose, the second aspect embodiment of the present disclosure proposes a flow control device, including: a decapsulation module, used to decapsulate the received data packet according to the set frame structure to obtain a first data frame; a discrimination module, used to discriminate the first data frame to determine the service type to which the first data frame belongs; a first flow control module, used to perform a first flow control on the first data frame using a first token bucket matching the service type of the first data frame to determine whether the first data frame passes the first flow control; a second flow control module, used to perform a second flow control on each service data in the first data frame using a second token bucket matching the each service data in the first data frame when the first data frame passes the first flow control.

[0012] To achieve the above-mentioned purpose, the third aspect embodiment of the present disclosure proposes an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the flow control method as described in the first aspect embodiment of the present disclosure is implemented.

[0013] In order to achieve the above-mentioned objectives, the fourth aspect embodiment of the present disclosure proposes a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the flow control method as described in the first aspect embodiment of the present disclosure is implemented.

[0014] In order to achieve the above-mentioned purpose, the fifth aspect embodiment of the present disclosure proposes a computer program product, when the instruction processor in the computer program product is executed, it implements the flow control method as described in the first aspect embodiment of the present disclosure.

[0015] Additional aspects and advantages of the present disclosure will be given in part in the following description and in part will be obvious from the following description or learned through practice of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS

[0016] The above and / or additional aspects and advantages of the present disclosure will become apparent and easily understood from the following description of the embodiments in conjunction with the accompanying drawings, in which:

[0017] Figure 1 A schematic diagram of a token bucket generating tokens and forwarding data in the related art;

[0018] Figure 2 A flow chart of a flow control method provided by an embodiment of the present disclosure;

[0019] Figure 3 A structural diagram of a frame structure provided by an embodiment of the present disclosure;

[0020] Figure 4 A schematic diagram of the structure of a data unit provided in an embodiment of the present disclosure;

[0021] Figure 5 A flow chart of another flow control method provided by an embodiment of the present disclosure;

[0022] Figure 6 A schematic diagram of the priority level in the second sub-token bucket provided by an embodiment of the present disclosure;

[0023] Figure 7 A flow chart of another flow control method provided by an embodiment of the present disclosure;

[0024] Figure 8 A flow chart of another flow control method provided by an embodiment of the present disclosure;

[0025] Fig. 9 A flow chart of another flow control method provided by an embodiment of the present disclosure;

[0026] Fig.10 A flow chart of another flow control method provided by an embodiment of the present disclosure;

[0027] Fig.11 A schematic diagram of the structure of a flow control system provided by an embodiment of the present disclosure;

[0028] Fig.12 A schematic diagram of the structure of a flow control device provided by an embodiment of the present disclosure;

[0029] Fig.13 It is a block diagram of an electronic device for flow control according to an exemplary embodiment. DETAILED DESCRIPTION

[0030] Embodiments of the present disclosure are described in detail below, examples of which are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are intended to be used to explain the present disclosure, and should not be construed as limiting the present disclosure.

[0031] In order to avoid network congestion caused by excessive burst traffic, the token bucket algorithm is used in related technologies to control the flow of forwarded data. Figure 1 Describe the basic process of the token bucket algorithm. Figure 1 A schematic diagram of a token bucket generating tokens and forwarding data in the related art.

[0032] like Figure 1 As shown in Figure 1, the basic process of the token bucket algorithm is as follows: the user configures the average sending rate to be r, and adds a token to the bucket every 1 / r seconds; the bucket can store a maximum of b tokens, and if the token bucket is full, the newly arrived token will be discarded; when an n-byte datagram arrives, n tokens are deleted from the token bucket and the data packet is sent to the network; if the number of tokens is less than n, the token is not deleted and the data packet is considered to be outside the flow limit. The algorithm allows data bursts of up to b bytes and limits the average output rate of the port to r. Data packets that exceed the flow limit are stored in the on-chip cache and discarded if the cache capacity is insufficient.

[0033] In the related art, the flow control technology of the token bucket algorithm temporarily stores data packets that exceed the flow limit, thereby evenly distributing the burst services. By increasing the cache size or using an off-chip cache, the burst data volume that the token bucket can tolerate can be increased. However, the traditional token bucket algorithm cannot guarantee the communication quality of high-priority services, and cannot achieve absolute occupation of bandwidth resources by high priority during traffic congestion. If the cache area is filled with low-priority services, the high-priority services that arrive later will be discarded. At the same time, it cannot support various rate services.

[0034] In view of the above problems, the present disclosure proposes a flow control method and device. It should be noted that the flow control method of the embodiment of the present disclosure can be applied to the flow control device of the embodiment of the present disclosure, and the device can be configured in an electronic device, and the electronic device can be a satellite-borne switching device.

[0035] The flow control method and device according to the embodiments of the present disclosure are described below with reference to the accompanying drawings.

[0036] Figure 2 A flow chart of a flow control method provided in an embodiment of the present disclosure.

[0037] like Figure 2 As shown, the flow control method may include the following steps:

[0038] Step 201, decapsulate the received data packet according to the set frame structure to obtain a first data frame.

[0039] In the embodiment of the present disclosure, the received data packet may include service data of at least one data type, for example, the service data may be voice, picture, short message, navigation data or video, etc. Then, the received data packet is decapsulated according to the set frame structure. As an example, Figure 3 As shown, the set frame structure may include synchronization information, frame header information and data part.

[0040] The data part can be classified according to the data type and data volume of the service data. As an example, the data part can be divided into 4 low-speed services, 1 medium-speed service and 1 high-speed service, wherein the data volume corresponding to the high-speed service is greater than the data volume corresponding to the medium-speed service, and the data volume corresponding to the medium-speed service is greater than the data volume corresponding to the low-speed service. For example, the low-speed service is pictures, the medium-speed service is voice, and the high-speed service is video. The frame header information in the frame structure may include a frame count bit (32 bits), a priority (3 bits), a service type (1 bit, designated service or non-designated service), low-speed service indication information (2 bits), medium-speed service indication information (1 bit), and high-speed service indication information (1 bit); in addition, the service type may include 0 and 1, wherein 1 may represent a designated service (special service), and 0 may represent a non-designated service (ordinary service). The designated service may be a service with a high delay requirement, and the non-designated service may be a service other than the designated service. The priority of the designated service is higher than that of the non-designated service. The low-speed service indication information may be used to indicate the number of low-speed services in the frame structure. For example, the low-speed service indication information is 00, indicating that the frame structure contains one low-speed service, the low-speed service indication information is 01, indicating that the frame structure contains two low-speed services, the low-speed service indication information is 10, indicating that the frame structure contains three low-speed services, and the low-speed service indication information is 11, which can be used to indicate that the frame structure contains four low-speed services. Similarly, the medium-speed service indication information is used to indicate the number of medium-speed services in the frame structure, and the high-speed service information is used to indicate the number of high-speed services in the frame structure.

[0041] As an example, Figure 4 As shown, the data in the data part may be composed of data units, for example, a low-speed service may be composed of 1 data unit, a medium-speed service may be composed of 10 to 100 data units, and a high-speed service may be composed of 1000 to 10000 data units, wherein each data unit may include an information frame header, data, and invalid information (100 bits); for designated services, the information frame header in each data unit is 8 bits, wherein 1 bit indicates whether there is data or no data, and the remaining 7 bits may not be defined; for non-designated services, the information frame header in each data unit is 8 bits, wherein 1 bit indicates whether there is data or no data, 4 bits indicate the corresponding data type (such as 0000 for voice, 0001 for IoT data, 0010 for short message, etc.), and 3 bits indicate the priority; wherein it should be noted that the invalid information in each data unit can be used to protect against inter-satellite jitter.

[0042] Step 202: Identify the first data frame to determine the service type to which the first data frame belongs.

[0043] In the embodiment of the present disclosure, the service type of the first data frame can be determined according to the information indicating the service type in the frame header information of the first data frame to obtain the service type to which the first data frame belongs. The service type may include designated services and non-designated services.

[0044] For example, the information used to indicate the service type in the frame header information of the first data frame is 0, and the service type of the first data frame is non-specified service; the information used to indicate the service type in the frame header information of the first data frame is 1, and the service type of the first data frame is specified service.

[0045] Step 203: Perform a first flow control on the first data frame using a first token bucket that matches the service type of the first data frame to determine whether the first data frame passes the first flow control.

[0046] In order to meet the needs of different services and avoid network congestion caused by excessive burst business volume, in an embodiment of the present disclosure, a first token bucket matching the business type of the forwarded data can be used to perform a first flow control on the first data frame to determine whether the first data frame passes the first flow control, wherein the first token bucket can be used to limit the data output flow of the physical port.

[0047] Step 204, when the first data frame passes through the first flow control, a second token bucket matching each service data in the first data frame is used to perform a second flow control on each service data in the first data frame.

[0048] In order to achieve refined flow control, flow control can be performed separately for each business data in the first data frame. In the embodiment of the present disclosure, when the first data frame passes through the first flow control, a second token bucket matching the business data in the first data frame is used to perform second flow control on each business data in the first data frame.

[0049] It should be noted that the second token bucket may be used to limit the output flow of the logical port, and service data exceeding the flow limit may be discarded.

[0050] In summary, the received data packet is decapsulated according to the set frame structure to obtain the first data frame; the first data frame is identified to determine the service type to which the first data frame belongs; the first token bucket matching the service type of the first data frame is used to perform the first flow control on the first data frame to determine whether the first data frame passes the first flow control; when the first data frame passes the first flow control, the second token bucket matching the service data in the first data frame is used to perform the second flow control on the service data in the first data frame. Therefore, when forwarding data, the forwarding data can be decapsulated using the set frame structure to generate the first data frame, and the first data frame can be identified to determine the service type of the forwarding data, and the flow control strategy matching the service type of the forwarding data is used to control the forwarding data in a targeted and refined manner, so as to meet the needs of different services, and avoid network congestion caused by excessive burst business volume, and at the same time, it can also avoid the uniformity of data flow control, improve the quality of data transmission, and better meet user needs.

[0051] In order to clearly illustrate how the above embodiment uses a first token bucket matching the service type of the first data frame to perform a first flow control on the first data frame to determine whether the first data frame passes the first flow control, the present disclosure proposes another flow control method.

[0052] Figure 5 A flow chart of another flow control method provided in an embodiment of the present disclosure.

[0053] like Figure 5 As shown, the flow control method may include the following steps:

[0054] Step 501: decapsulate the received data packet according to the set frame structure to obtain a first data frame.

[0055] Step 502: Identify the first data frame to determine the service type to which the first data frame belongs.

[0056] Step 503, when the service type to which the first data frame belongs is a designated service, first flow control is performed on the first data frame according to the number of first real-time tokens in the first sub-token bucket to determine whether the first data frame passes the first flow control.

[0057] The priority of the specified service type is greater than or equal to a set level threshold.

[0058] In an embodiment of the present disclosure, the first token bucket may include a first sub-token bucket and a second sub-token bucket. The first sub-token bucket may be used for first flow control of designated services, and the second sub-token bucket may be used for first flow control of non-designated services.

[0059] As an example, when the service type to which the first data frame belongs is a designated service, the first real-time token number in the first sub-token bucket is compared with the number of tokens required for the first data frame. When the first real-time token number is greater than or equal to the number of tokens required for the first data frame, the first data frame passes the first flow control; when the first real-time token number is less than the number of tokens required for the first data frame, the first data frame fails to pass the first flow control, that is, the first data frame that exceeds the flow limit of the physical port is accumulated in the shared cache of the queue management.

[0060] Step 504, when the service type to which the first data frame belongs is a non-designated service, the first data frame is subjected to first flow control according to the second real-time token number in the second sub-token bucket and the priority of the first data frame to determine whether the first data frame passes the first flow control.

[0061] Among them, the priority of the non-designated service is less than the level threshold.

[0062] In order to avoid the uniformity of burst services during flow control and realize the absolute occupation of bandwidth resources by high priority during traffic congestion, as an example, when the service type to which the first data frame belongs is a non-specified service, the first flow control can be performed on the first data frame according to the second real-time token number in the second sub-token bucket combined with the priority of the first data frame to determine whether the first data frame passes the first flow control.

[0063] As an example, determine a first ratio of the second real-time token in the second sub-token bucket to the set total number of cards in the second sub-token bucket; when the first ratio is greater than or equal to (ni) / n, determine whether the priority of the first data frame is greater than i; when the priority of the first data frame is greater than, determine that the first data frame passes the first flow control; when the priority of the first data frame is less than or equal to i, determine that the first data frame does not pass the first flow control; wherein n is the set number of priorities, i=0,1,2,…,(n-1).

[0064] For example, Figure 6 As shown, 8 priorities are set for the first data frame. When the second real-time token number is greater than 7 / 8 of the total token number set in the second sub-token bucket, the first data frames of all priorities are allowed to consume tokens and send; when the second real-time token number is less than 7 / 8 of the total token number set in the second sub-token bucket, and the second real-time token number is greater than 6 / 8 of the total token number set in the second sub-token bucket, the first data frame with the lowest priority is prohibited from sending; and so on, when the second real-time token number is greater than 1 / 8 of the total token number set in the second sub-token bucket, only the first data frame with the highest priority is allowed to consume tokens and send. The data packets prohibited from sending are stored in the on-chip cache and discarded if the cache capacity is insufficient.

[0065] Step 505 , when the first data frame passes through the first flow control, a second token bucket matching each service data in the first data frame is used to perform a second flow control on each service data in the first data frame.

[0066] It should be noted that the execution process of steps 501 to 502 and step 505 can be implemented in any manner in the embodiments of the present disclosure, and the embodiments of the present disclosure do not limit this and will not be described in detail.

[0067] In summary, when the service type to which the first data frame belongs is a designated service, the first flow control is performed on the first data frame according to the first real-time token number in the first sub-token bucket to determine whether the first data frame passes the first flow control; when the service type to which the first data frame belongs is a non-designated service, the first flow control is performed on the first data frame according to the second real-time token number in the second sub-token bucket and the priority of the first data frame to determine whether the first data frame passes the first flow control. Therefore, the first flow control is performed on the first data frame using a flow control strategy that matches the service type to which the first data frame belongs, which can meet different business needs and also avoid network congestion caused by excessive burst business volume.

[0068] In order to clearly illustrate how the above embodiment uses a second token bucket matching each business data in the first data frame to perform second flow control on each business data in the first data frame when the first data frame passes the first flow control, the present disclosure proposes another flow control method.

[0069] Figure 7 A flow chart of another flow control method provided in an embodiment of the present disclosure.

[0070] like Figure 7 As shown, the flow control method may include the following steps:

[0071] Step 701, decapsulate the received data packet according to the set frame structure to obtain a first data frame.

[0072] Step 702: Identify the first data frame to determine the service type to which the first data frame belongs.

[0073] Step 703: Perform a first flow control on the first data frame using a first token bucket that matches the service type of the first data frame to determine whether the first data frame passes the first flow control.

[0074] Step 704, when the service type to which the first data frame belongs is a designated service and the first data frame passes the first flow control, a second flow control is performed on each service data in the first data frame according to the number of third real-time tokens in the third sub-token bucket that matches each service data in the first data frame.

[0075] In an embodiment of the present disclosure, the second token bucket may include a third sub-token bucket and a fourth sub-token bucket, the third sub-token bucket may be used for second flow control of designated services, and the fourth sub-token bucket may be used for second flow control of non-designated services.

[0076] In order to achieve refined flow control, the second flow control may be performed on each service data in the first data frame.

[0077] As an example, when the first data frame passes the first flow control, each business data can be read from the first data frame according to the set frame structure, and for any business data, identification information of any business data can be obtained; when the identification information of any business data indicates that any business data is valid, a third sub-token bucket matching the data volume is determined according to the data volume of any business data.

[0078] That is to say, when the first data frame passes through the first flow control, based on the set frame structure, each business data is read from the first data frame. Since each business data may be invalid data, after reading each business data, it is possible to determine whether the business data is valid based on the identification information (e.g., the information frame header) in each business data. When the business data is determined to be valid based on the identification information, the type corresponding to the business data (e.g., low speed, medium speed, or high speed) can be determined based on the data volume of the business data, and a third sub-token bucket matching the type is selected based on the type corresponding to the business data. For example, if the type corresponding to the data volume of the business data is low-speed business, a low-speed third sub-token bucket is selected; for another example, if the type corresponding to the data volume of the business data is medium-speed business, a medium-speed third sub-token bucket is selected; for another example, if the type corresponding to the data volume of the business data is high-speed business, a high-speed third sub-token bucket is selected. It should be noted that the total number of tokens in the low-speed third sub-token bucket is less than the total number of tokens in the medium-speed third sub-token bucket, and the total number of tokens in the medium-speed third sub-token bucket is less than the total number of tokens in the high-speed third sub-token bucket.

[0079] Furthermore, the number of third real-time tokens in the third sub-token bucket is compared with the number of tokens required for the corresponding business data. When the number of third real-time tokens in the third sub-token bucket is greater than the number of tokens required for the corresponding business data, the corresponding business data passes through the second flow control.

[0080] It should be noted that the third sub-token bucket can be used to limit the output flow of the logical port, and the service data exceeding the flow limit can be discarded.

[0081] Step 705, when the service type to which the first data frame belongs is non-designated service and the first data frame passes the first flow control, the second flow control is performed on each service data in the first data frame according to the number of fourth real-time tokens in the fourth sub-token bucket that matches each service data in the first data frame and the priority of each service data.

[0082] In order to achieve refined flow control and improve the service quality of non-designated services, in the embodiment of the present disclosure, when the data packet passes the first flow control, the second flow control can be performed on each service data in the first data frame.

[0083] As an example, when the first data frame passes the first flow control, each business data can be read from the first data frame according to the set frame structure, and for any business data, the identification information of any business data can be obtained; when the identification information of any business data indicates that any business data is valid, the fourth sub-token bucket matching the data volume is determined according to the data volume of any business data.

[0084] That is to say, when the first data frame passes through the first flow control, based on the set frame structure, each business data is read from the first data frame. Since each business data may be invalid data, after reading each business data, it is possible to determine whether the business data is valid based on the identification information (e.g., the information frame header) in each business data. When the business data is determined to be valid based on the identification information, the type corresponding to the business data (e.g., low speed, medium speed, or high speed) can be determined based on the data volume of the business data, and a fourth sub-token bucket matching the type is selected based on the type corresponding to the business data. For example, if the type corresponding to the data volume of the business data is low-speed business, the fourth sub-token bucket with a low rate is selected; for another example, if the type corresponding to the data volume of the business data is medium-speed business, the fourth token bucket with a medium rate is selected; for another example, if the type corresponding to the data volume of the business data is high-speed business, the fourth sub-token bucket with a high rate is selected. It should be noted that the total number of tokens in the fourth sub-token bucket with a low rate is less than the total number of tokens in the fourth sub-token bucket with a medium rate, and the total number of tokens in the fourth sub-token bucket with a medium rate is less than the total number of tokens in the fourth sub-token bucket with a high rate.

[0085] In order to avoid the uniformity of burst services during flow control and achieve absolute occupation of bandwidth resources by high priority during traffic congestion, as an example, when the first data frame passes the first flow control, the second flow control can be performed on each business data in the first data frame based on the number of fourth real-time tokens in the fourth sub-token bucket matching each business data in the first data frame and the priority of each business data.

[0086] As an example, for any business data in the first data frame, determine the second ratio of the fourth real-time token number in the fourth sub-token bucket matching any business data to the set total token number in the fourth sub-token bucket; when the second ratio is greater than or equal to (ni) / n, determine whether the priority of any business data is greater than i; when the priority of any business data is greater than i, determine that any business data passes the corresponding second flow control; when the priority of any business data is less than or equal to i, determine that any business data does not pass the corresponding second flow control; wherein n is the set number of priorities, i=0,1,2,…,(n-1).

[0087] For example, if any service data in the first data frame is set with 8 priorities, when the fourth real-time token number is greater than 7 / 8 of the total token number set in the fourth sub-token bucket, service data of all priorities corresponding to the fourth real-time token number are allowed to consume tokens and be sent; when the fourth real-time token number is less than 7 / 8 of the total token number set in the fourth sub-token bucket, and the fourth real-time token number is greater than 6 / 8 of the total token number set in the fourth sub-token bucket, the service data with the lowest priority corresponding to the fourth real-time token number is prohibited from being sent; and so on, when the fourth real-time token number is greater than 1 / 8 of the total token number set in the fourth sub-token bucket, only the service data with the highest priority corresponding to the fourth real-time token number is allowed to consume tokens and be sent. The service data prohibited from being sent is stored in the on-chip cache and discarded if the cache capacity is insufficient.

[0088] It should be noted that the execution process of steps 701 to 703 can be implemented in any way in the embodiments of the present disclosure, and the embodiments of the present disclosure do not limit this and will not be described in detail.

[0089] In summary, when the service type to which the first data frame belongs is a designated service and the first data frame passes the first flow control, the second flow control is performed on each service data in the first data frame according to the third real-time token number in the third sub-token bucket that matches each service data in the first data frame; when the service type to which the first data frame belongs is a non-designated service and the first data frame passes the first flow control, the second flow control is performed on each service data in the first data frame according to the fourth real-time token number in the fourth sub-token bucket that matches each service data in the first data frame and the priority of each service data. Therefore, when the second flow control is performed on the first data frame, the third sub-token bucket or the fourth sub-token bucket that matches each service data is used to perform the second flow control on each service data, thereby realizing the refined flow control of the first data frame. At the same time, when the service type to which the first data frame belongs is a non-designated service, the second flow control is performed on each service data in the first data frame according to the fourth real-time token number in the fourth sub-token bucket that matches each service data in the first data frame and the priority of each service data, thereby avoiding the uniformity of burst services during flow control and realizing the absolute occupation of bandwidth resources by high priority during traffic congestion.

[0090] In order to achieve precise control of the delay of a specified service, when the first data frame passes the first flow control, after the second flow control is performed on each service data in the first data frame according to the number of third real-time tokens in the third sub-token bucket that matches each service data in the first data frame, the first target service data that passes the second flow control can be encapsulated based on the set frame structure, and the encapsulated data frame can be scheduled. Figure 8 The above process is described in detail.

[0091] Figure 8 A flow chart of another flow control method provided in an embodiment of the present disclosure.

[0092] like Figure 8 As shown, the flow control method may include the following steps:

[0093] Step 801, decapsulate the received data packet according to the set frame structure to obtain a first data frame.

[0094] Step 802: Identify the first data frame to determine the service type to which the first data frame belongs.

[0095] Step 803, when the service type to which the first data frame belongs is a designated service, first flow control is performed on the first data frame according to the number of first real-time tokens in the first sub-token bucket to determine whether the first data frame passes the first flow control.

[0096] The priority of the specified service type is greater than or equal to a set level threshold.

[0097] Step 804, when the first data frame passes the first flow control, second flow control is performed on each service data in the first data frame according to the number of third real-time tokens in the third sub-token bucket matching each service data in the first data frame.

[0098] Step 805: Determine first target service data that passes the second flow control from each service data of the first data frame.

[0099] Since the service type to which the first data frame belongs is a designated service type, and when the first data frame passes the first flow control, the second flow control is performed on each service data in the first data frame according to the number of third real-time tokens in the third sub-token bucket that matches each service data in the first data frame. Therefore, in order to achieve precise control of the delay of the designated service, in the embodiment of the present disclosure, the service data passing the second flow can be encapsulated into a second data frame, and the second data frame can be scheduled. As an example, the service data passing the second flow control is obtained from each service data of the first data frame, and the service data passing the second flow control is used as the first target service data. Among them, the first target service data may include: at least one of low-speed service, medium-speed service and high-speed service.

[0100] Step 806: encapsulate the first target service data based on the frame structure to obtain a second data frame.

[0101] Further, according to the set frame structure, the first target service data is encapsulated to obtain a second data frame, wherein it should be noted that since the first target service data may include at least one of low-speed service, medium-speed service and high-speed service, the service data in the frame structure may include 4 low-speed services, 1 medium-speed service and 1 high-speed service, and the service data in the frame structure that is not included in the first target service data may be filled with invalid information. For example, the first target service data only includes medium-speed service and high-speed service, and when the first target service is encapsulated, the 4 low-speed services in the frame structure may be filled with invalid information.

[0102] Step 807: Use the set first gating strategy to periodically schedule the second data frame.

[0103] In order to achieve accurate control of the delay, for a designated service, the first gating may be periodically opened to schedule the second data frame.

[0104] It should be noted that the execution process of steps 801 to 804 can be implemented in any way in the embodiments of the present disclosure, and the embodiments of the present disclosure do not limit this and will not be described in detail.

[0105] In summary, by determining the first target business data through the second flow control from the business data of the first data frame; encapsulating the first target business data based on the frame structure to obtain the second data frame; and adopting the set first gating strategy to periodically schedule the second data frame, the delay of the specified business can be accurately controlled, thereby improving the service quality of the specified business.

[0106] In order to improve the service quality of non-designated services, in the embodiment of the present disclosure, when the first data frame passes the first flow control, according to the number of fourth real-time tokens in the fourth sub-token bucket matching the service data in the first data frame and the priority of each service data, after the second flow control is performed on each service data in the first data frame, the second gating strategy can be adopted to schedule the service data passing the second flow control. Fig. 9 The above process is described in detail.

[0107] Fig. 9 A flow chart of another flow control method provided in an embodiment of the present disclosure.

[0108] like Fig. 9 As shown, the flow control method may include the following steps:

[0109] Step 901: decapsulate the received data packet according to the set frame structure to obtain a first data frame.

[0110] Step 902: Identify the first data frame to determine the service type to which the first data frame belongs.

[0111] Step 903, when the service type to which the first data frame belongs is a non-designated service, the first data frame is subjected to a first flow control according to the number of second real-time tokens in the second sub-token bucket and the priority of the first data frame to determine whether the first data frame passes the first flow control.

[0112] Among them, the priority of the non-designated service is less than the level threshold.

[0113] Step 904, when the first data frame passes the first flow control, the second flow control is performed on each business data in the first data frame according to the number of fourth real-time tokens in the fourth sub-token bucket matching each business data in the first data frame and the priority of each business data.

[0114] Step 905: Determine second target service data that passes the second flow control from each service data of the first data frame.

[0115] Since the service type to which the first data frame belongs is a non-specified service type, and when the first data frame passes the first flow control, the second flow control is performed on each service data in the first data frame according to the fourth real-time token number in the fourth sub-token bucket that matches each service data in the first data frame and the priority of each service data. Therefore, in order to achieve accurate synchronization of each designated service data, the service data that passes the second flow control can be encapsulated into a data frame, and the encapsulated data frame can be scheduled. In the embodiment of the present disclosure, the second target service data that passes the second flow control can be obtained from each service data of the first data frame, and the service data that passes the second flow control can be used as the second target service data.

[0116] Step 906: encapsulate the second target service data based on the set frame structure to obtain a third data frame.

[0117] Furthermore, the second target service data is encapsulated according to the set frame structure to obtain a second data frame.

[0118] Step 907: use the set second gating strategy to schedule the third data frame.

[0119] In order to improve the service quality of non-designated services, in the embodiment of the present disclosure, the first gating may be periodically opened to schedule the third data frame.

[0120] It should be noted that the execution process of steps 901 to 904 can be implemented in any way in the embodiments of the present disclosure, and the embodiments of the present disclosure do not limit this and will not be described in detail.

[0121] In summary, by determining the second target business data through the second flow control from the business data of the first data frame; encapsulating the second target business data based on the set frame structure to obtain the third data frame; and adopting the set second gating strategy to schedule the third data frame, thereby achieving accurate synchronization of each business data in the non-designated business, and improving the service quality of the non-designated business.

[0122] In order to clearly illustrate how the received data packet is decapsulated according to the set frame structure in the above embodiment to obtain the first data frame, the present disclosure proposes a flow chart of another flow control method.

[0123] Fig.10 A flow chart of another flow control method provided in an embodiment of the present disclosure.

[0124] like Fig.10 As shown, the flow control method may include the following steps:

[0125] Step 1001, determining the data type of each service data in the data packet.

[0126] In the embodiment of the present disclosure, the business data in the data can be identified to determine the data type of each business data in the data packet. It should be noted that the data packet may include business data of at least one data type, for example, the business data may be voice, short message, navigation data or video.

[0127] Step 1002: Determine the location information of each service data in the frame structure according to the data type and data volume corresponding to each service data.

[0128] As an example, the set frame structure may include synchronization information, frame header information and data part, wherein the data part may be classified according to the data type and data volume of the service data. As an example, the data part may be divided into 4 low-speed services, 1 medium-speed service and 1 high-speed service, wherein the data volume corresponding to the high-speed service is greater than the data volume corresponding to the medium-speed service, and the data volume corresponding to the medium-speed service is greater than the data volume corresponding to the low-speed service. For example, the low-speed service is pictures, the medium-speed service is voice, and the high-speed service is video. Furthermore, according to the data type and data volume corresponding to each service data, the position information of each service data in the frame structure may be determined. For example, pictures correspond to low-speed services in the frame structure, voice corresponds to medium-speed services in the frame structure, and video corresponds to high-speed services in the frame structure.

[0129] Step 1003: decapsulate each service data according to the position information of each service data in the frame structure to obtain a first data frame.

[0130] Then, each service data can be decapsulated according to the position information in the frame structure, so as to obtain the first data frame. It should be noted that when the service data of each service data of the data packet does not contain the service data of the data part in the frame structure, invalid information can be used to fill it to avoid inter-satellite jitter. For example, the data packet includes medium-speed services and high-speed services. When decapsulating each service data, the four low-speed services in the data part of the frame structure can be filled with invalid information.

[0131] Step 1004: Identify the first data frame to determine the service type to which the first data frame belongs.

[0132] Step 1005: Perform a first flow control on the first data frame using a first token bucket that matches the service type of the first data frame to determine whether the first data frame passes the first flow control.

[0133] Step 1006: When the first data frame passes through the first flow control, a second token bucket matching each service data in the first data frame is used to perform a second flow control on each service data in the first data frame.

[0134] It should be noted that the execution process of steps 1004 to 1006 can be implemented in any way in the embodiments of the present disclosure, and the embodiments of the present disclosure do not limit this and will not be described in detail.

[0135] In summary, by determining the data type of each business data in the data packet; determining the position information of each business data in the frame structure according to the data type and data volume corresponding to each business data; and decapsulating each business data according to the position information of each business data in the frame structure to obtain the first data frame, it is possible to effectively decapsulate each business data in the data packet according to the set frame structure to obtain the first data frame.

[0136] As a possible implementation of the embodiment of the present disclosure, the flow control method provided by the embodiment of the present disclosure can be implemented based on a flow control system. For example, the structure of the flow control system can be as follows: Fig.11 As shown, the flow control system implements the flow control method provided by the embodiment of the present disclosure in the following steps:

[0137] 1. In order to facilitate interaction with other communication devices, the time slot counter can be started to count the co-track, off-track, and feeding data received by the payload by time slot. At the same time, the received data is judged by the service discriminator. If it is a designated service, it is sent to the refined shaping module 1-4; if it is a non-designated service, it is sent to the refined shaping module 5-8; at the same time, the time slot counter is judged. If it exceeds a frame length specified time slot (such as 1024), it is cleared and counted again;

[0138] 2. For the data sent to the refined shaping module, a first-level token bucket combined with a variable-rate token bucket is used to implement refined flow control. The first-level token bucket is used to limit the output flow of the physical port. Data packets that exceed the flow limit are accumulated in the shared cache of the queue management, and data packets that do not exceed the flow limit are sent to the corresponding variable-rate token bucket (the third sub-token bucket corresponding to each service data in the designated service, and the fourth sub-token bucket corresponding to each service data in the non-designated service). The variable-rate token bucket is used to limit the output flow of the logical port. Data packets that exceed the flow limit are discarded, and data packets that do not exceed the flow limit are sent to the gating scheduling module;

[0139] 3. Finally, for the data sent to the gating scheduling, the gating table is scheduled according to the counter and ephemeris, and the data output is controlled through the gating table; among them, the gating of designated services (special services) is periodically opened; the non-designated services (ordinary services) are always open, and the non-designated services are transmitted according to the service quality level of the non-designated services. Among them, the gating scheduling module is divided into gating 1-4 for designated services and gating 5-8 for non-designated services. It mainly controls whether the gating is opened by reading the gating table value through the ephemeris and counter, thereby controlling whether the data frames in each queue are transmitted. Among them, the gating of designated services is periodically opened by four gatings; the gating of non-designated services is always open. The gating table is shown in Table 1. In the gating table, Y represents gating opening and N represents gating closing.

[0140] Table 1 Gating table

[0141] Serial number time Gate (1-8) status 1 0us YNNNYYYY 2 10us NYNNYYYY 3 20us NNYNYYYY 4 30us NNNYYYYY

[0142] The flow control method of the embodiment of the present disclosure decapsulates the received data packet according to the set frame structure to obtain the first data frame; distinguishes the first data frame to determine the service type to which the first data frame belongs; uses a first token bucket matching the service type of the first data frame to perform a first flow control on the first data frame to determine whether the first data frame passes the first flow control; when the first data frame passes the first flow control, uses a second token bucket matching each service data in the first data frame to perform a second flow control on each service data in the first data frame. Therefore, when forwarding data, the set frame structure can be used to decapsulate the forwarded data to generate the first data frame, and the first data frame is distinguished to determine the service type of the forwarded data. A flow control strategy matching the service type of the forwarded data is used to perform flow control on the forwarded data in a targeted and refined manner, thereby meeting the needs of different services, and avoiding network congestion caused by excessive burst business volume. At the same time, it can also avoid the uniformity of data flow control, improve the data transmission quality, and better meet user needs.

[0143] In order to implement the above embodiments, the present disclosure also proposes a flow control device.

[0144] Fig.12 A schematic diagram of the structure of a flow control device provided in an embodiment of the present disclosure.

[0145] like Fig.12 As shown, the flow control device 1200 includes: a decapsulation module 1210 , a determination module 1220 , a first flow control module 1230 and a second flow control module 1240 .

[0146] Among them, the decapsulation module 1210 is used to decapsulate the received data packet according to the set frame structure to obtain the first data frame; the identification module 1220 is used to identify the first data frame to determine the service type to which the first data frame belongs; the first flow control module 1230 is used to perform a first flow control on the first data frame using a first token bucket matching the service type of the first data frame to determine whether the first data frame passes the first flow control; the second flow control module 1240 is used to perform a second flow control on each service data in the first data frame using a second token bucket matching each service data in the first data frame when the first data frame passes the first flow control.

[0147] As a possible implementation method of the embodiment of the present disclosure, the first token bucket includes a first sub-token bucket and a second sub-token bucket, and the first flow control module 1230 is specifically used to: when the service type to which the first data frame belongs is a designated service, according to the first real-time token number in the first sub-token bucket, perform a first flow control on the first data frame to determine whether the first data frame passes the first flow control; wherein the priority of the designated service type is greater than or equal to the set level threshold; when the service type to which the first data frame belongs is a non-designated service, according to the second real-time token number in the second sub-token bucket and the priority of the first data frame, perform a first flow control on the first data frame to determine whether the first data frame passes the first flow control; wherein the priority of the non-designated service is less than the level threshold.

[0148] As a possible implementation method of the embodiment of the present disclosure, the second token bucket includes a third sub-token bucket and a fourth sub-token bucket, and the second flow control module 1240 is specifically used to: when the business type to which the first data frame belongs is a designated business and the first data frame passes the first flow control, perform second flow control on each business data in the first data frame according to the third real-time token number in the third sub-token bucket that matches each business data in the first data frame; when the business type to which the first data frame belongs is a non-designated business and the first data frame passes the first flow control, perform second flow control on each business data in the first data frame according to the fourth real-time token number in the fourth sub-token bucket that matches each business data in the first data frame and the priority of each business data.

[0149] As a possible implementation method of the embodiment of the present disclosure, the first flow control module 1230 is also used to: determine a first ratio of the second real-time token in the second sub-token bucket to the set total number of cards in the second sub-token bucket; when the first ratio is greater than or equal to (ni) / n, determine whether the priority of the first data frame is greater than i; when the priority of the first data frame is greater than, determine that the first data frame passes the first flow control; when the priority of the first data frame is less than or equal to i, determine that the first data frame does not pass the first flow control; wherein n is the set number of priorities, i=0,1,2,…,(n-1).

[0150] As a possible implementation method of the embodiment of the present disclosure, the second flow control module 1240 is also used to: for any business data in the first data frame, determine the second ratio of the fourth real-time token in the fourth sub-token bucket matching any business data to the set total number of cards in the fourth sub-token bucket; when the second ratio is greater than or equal to (ni) / n, determine whether the priority of any business data is greater than i; when the priority of any business data is greater than i, determine that any business data passes the corresponding second flow control; when the priority of any business data is less than or equal to i, determine that any business data does not pass the corresponding second flow control; wherein n is the set number of priorities, i=0,1,2,…,(n-1).

[0151] As a possible implementation of the embodiment of the present disclosure, the flow control device 1200 further includes: a first determination module, a first encapsulation module and a first scheduling module.

[0152] Among them, the first determination module is used to determine the first target business data through the second flow control from the various business data of the first data frame; the first encapsulation module is used to encapsulate the first target business data based on the frame structure to obtain the second data frame; the first scheduling module is used to adopt the set first gating strategy to periodically schedule the second data frame.

[0153] As a possible implementation manner of the embodiment of the present disclosure, the flow control device 1200 further includes: a second determination module, a second encapsulation module and a second scheduling module.

[0154] Among them, the second determination module is used to determine the second target business data through the second flow control from the various business data of the first data frame; the second encapsulation module is used to encapsulate the second target business data based on the set frame structure to obtain the third data frame; the second scheduling module is used to schedule the third data frame using the set second gating strategy.

[0155] As a possible implementation method of the embodiment of the present disclosure, the determination module 1220 is used to: obtain frame header information of the first data frame; determine the target business type from multiple reference business types based on the frame header information, wherein the target business type matches the frame header information; and use the target business type as the business type to which the first data frame belongs.

[0156] As a possible implementation method of the embodiment of the present disclosure, the decapsulation module 1210 is used to: determine the data type of each business data in the data packet; determine the position information of each business data in the frame structure according to the data type and data volume corresponding to each business data; decapsulate each business data according to the position information of each business data in the frame structure to obtain a first data frame.

[0157] The flow control device of the disclosed embodiment decapsulates the received data packet according to the set frame structure to obtain the first data frame; discriminates the first data frame to determine the service type to which the first data frame belongs; uses the first token bucket matching the service type of the first data frame to perform the first flow control on the first data frame to determine whether the first data frame passes the first flow control; when the first data frame passes the first flow control, uses the second token bucket matching the service data in the first data frame to perform the second flow control on the service data in the first data frame. Thus, when forwarding data, the forwarding data can be decapsulated using the set frame structure to generate the first data frame, and the first data frame can be discriminated to determine the service type of the forwarding data, and the flow control strategy matching the service type of the forwarding data is used to control the forwarding data in a targeted and refined manner, so as to meet the needs of different services, and avoid network congestion caused by excessive burst business volume, and at the same time, avoid the uniformity of data flow control, improve the data transmission quality, and better meet the needs of users.

[0158] It should be noted that the above explanation of the flow control method embodiment is also applicable to the flow control device of this embodiment, and will not be repeated here.

[0159] In order to implement the above embodiments, the present application also proposes an electronic device, such as Fig.13 As shown, Fig.13 It is a block diagram of an electronic device for flow control according to an exemplary embodiment.

[0160] like Fig.13 As shown, the electronic device 1300 includes:

[0161] The memory 1310 and the processor 1320, a bus 1330 connecting different components (including the memory 1310 and the processor 1320), the memory 1310 stores a computer program, and when the processor 1320 executes the program, the flow control method described in the embodiment of the present disclosure is implemented.

[0162] Bus 1330 represents one or more of several types of bus structures, including a memory bus or memory controller, a peripheral bus, an accelerated graphics port, a processor or a local bus using any of a variety of bus architectures. For example, these architectures include but are not limited to Industry Standard Architecture (ISA) bus, Micro Channel Architecture (MAC) bus, Enhanced ISA bus, Video Electronics Standards Association (VESA) local bus and Peripheral Component Interconnect (PCI) bus.

[0163] The electronic device 1300 typically includes a variety of electronic device readable media. These media can be any available media that can be accessed by the electronic device 1300, including volatile and non-volatile media, removable and non-removable media.

[0164] The memory 1310 may also include computer system readable media in the form of volatile memory, such as random access memory (RAM) 1340 and / or cache memory 1350. The electronic device 1300 may further include other removable / non-removable, volatile / non-volatile computer system storage media. By way of example only, the storage system 1360 may be used to read and write non-removable, non-volatile magnetic media ( Fig.13 not shown, usually called a "hard drive"). Although Fig.13 Not shown, a disk drive for reading and writing to a removable non-volatile disk (e.g., a "floppy disk"), and an optical disk drive for reading and writing to a removable non-volatile optical disk (e.g., a CD-ROM, a DVD-ROM, or other optical media) may be provided. In these cases, each drive may be connected to the bus 1330 via one or more data medium interfaces. The memory 1310 may include at least one program product having a set (e.g., at least one) of program modules that are configured to perform the functions of the various embodiments of the present disclosure.

[0165] A program / utility 1380 having a set (at least one) of program modules 1370 may be stored, for example, in the memory 1310, such program modules 1370 including but not limited to an operating system, one or more application programs, other program modules, and program data, each of which or some combination may include an implementation of a network environment. The program modules 1370 generally perform the functions and / or methods of the embodiments described in the present disclosure.

[0166] The electronic device 1300 may also communicate with one or more external devices 1390 (e.g., keyboards, pointing devices, displays, etc.), one or more devices that enable a user to interact with the electronic device 1300, and / or any device that enables the electronic device 1300 to communicate with one or more other computing devices (e.g., network cards, modems, etc.). Such communication may be performed through an input / output (I / O) interface 1392. Furthermore, the electronic device 1300 may also communicate with one or more networks (e.g., a local area network (LAN), a wide area network (WAN), and / or a public network, such as the Internet) through a network adapter 1393. Fig.13 As shown, the network adapter 1393 communicates with other modules of the electronic device 1300 via the bus 1330. It should be understood that although Fig.13 Not shown, other hardware and / or software modules may be used in conjunction with electronic device 1300, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems.

[0167] The processor 1320 executes various functional applications and data processing by running the programs stored in the memory 1310 .

[0168] It should be noted that the implementation process and technical principles of the electronic device of this embodiment refer to the aforementioned explanation of the flow control of the embodiment of the present disclosure, and will not be repeated here.

[0169] In order to implement the above embodiments, the present application also proposes a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the flow control method described in the above embodiments is implemented.

[0170] In order to implement the above embodiments, the present disclosure further provides a computer program product. When an instruction processor in the computer program product is executed, the flow control method described in the above embodiments is executed.

[0171] In the description of this specification, the terms "first" and "second" are used for descriptive purposes only and cannot be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" and "second" may explicitly or implicitly include at least one of the features. In the description of this application, the meaning of "plurality" is at least two, such as two, three, etc., unless otherwise clearly and specifically defined.

[0172] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" etc. means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present application. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine the different embodiments or examples described in this specification and the features of the different embodiments or examples, without contradiction.

[0173] Although the embodiments of the present application have been shown and described above, it can be understood that the above embodiments are exemplary and cannot be understood as limitations on the present application. Ordinary technicians in this field can change, modify, replace and modify the above embodiments within the scope of the present application.

Claims

1. A flow control method, characterized in that: include: Decapsulating the received data packet according to the set frame structure to obtain a first data frame; Determining the first data frame to determine the service type to which the first data frame belongs; Performing a first flow control on the first data frame using a first token bucket matching the service type of the first data frame to determine whether the first data frame passes the first flow control; When the first data frame passes through the first flow control, a second token bucket matching each service data in the first data frame is used to perform second flow control on each service data in the first data frame.

2. The method according to claim 1, characterized in that The first token bucket includes a first sub-token bucket and a second sub-token bucket, and the first token bucket matching the service type of the first data frame is used to perform a first flow control on the first data frame to determine whether the first data frame passes the first flow control, including: When the service type to which the first data frame belongs is a designated service, performing a first flow control on the first data frame according to the number of first real-time tokens in the first sub-token bucket to determine whether the first data frame passes the first flow control; wherein the priority of the designated service type is greater than or equal to a set level threshold; When the service type to which the first data frame belongs is a non-designated service, a first flow control is performed on the first data frame according to the number of second real-time tokens in the second sub-token bucket and the priority of the first data frame to determine whether the first data frame passes the first flow control; wherein the priority of the non-designated service is less than the level threshold.

3. The method according to claim 1, characterized in that: The second token bucket includes a third sub-token bucket and a fourth sub-token bucket, and when the first data frame passes through the first flow control, the second token bucket matching each service data in the first data frame is used to perform second flow control on each service data in the first data frame, including: When the service type to which the first data frame belongs is a designated service and the first data frame passes the first flow control, performing a second flow control on each service data in the first data frame according to the number of third real-time tokens in a third sub-token bucket matching each service data in the first data frame; When the service type to which the first data frame belongs is non-designated service and the first data frame passes the first flow control, the second flow control is performed on each service data in the first data frame according to the number of fourth real-time tokens in the fourth sub-token bucket matching each service data in the first data frame and the priority of each service data.

4. The method according to claim 2, characterized in that: When the service type to which the first data frame belongs is a non-specified service type, performing a first flow control on the first data frame according to the number of second real-time tokens in the second sub-token bucket and the priority of the first data frame to determine whether the first data frame passes the first flow control, including: Determine a first ratio of the number of second real-time tokens in the second sub-token bucket to a set total number of tokens in the second sub-token bucket; When the first proportion is greater than or equal to (ni) / n, determining whether the priority of the first data frame is greater than i; In a case where the priority of the first data frame is greater than , determining that the first data frame passes the first flow control; When the priority of the first data frame is less than or equal to i, determining that the first data frame fails to pass the first flow control; Wherein, n is the number of set priorities, i=0, 1, 2,…, (n-1).

5. The method according to claim 3, characterized in that: The method further comprises: performing a second flow control on each service data in the first data frame according to the number of fourth real-time tokens in a fourth sub-token bucket matching each service data in the first data frame and the priority of each service data, when the service type to which the first data frame belongs is a non-designated service and the first data frame passes the first flow control, including: For any of the business data in the first data frame, determine a second ratio of the number of fourth real-time tokens in a fourth sub-token bucket matching any of the business data to a set total number of tokens in the fourth sub-token bucket; When the second proportion is greater than or equal to (ni) / n, determining whether the priority of any of the service data is greater than i; In the case where the priority of any of the service data is greater than i, determining that any of the service data passes the corresponding second flow control; When the priority of any of the service data is less than or equal to i, determining that any of the service data fails to pass the corresponding second flow control; Wherein, n is the number of set priorities, i=0, 1, 2,…, (n-1).

6. The method according to claim 3, characterized in that The method further comprises: Based on the set frame structure, reading each service data from the first data frame; For any of the business data, obtaining identification information of any of the business data; When the identification information of any of the business data indicates that any of the business data is valid, a third sub-token bucket or a fourth sub-token bucket matching the data volume is determined according to the data volume of any of the business data.

7. The method according to claim 3, characterized in that The method further comprises: after performing second flow control on each service data in the first data frame according to the number of third real-time tokens in a third sub-token bucket matching each service data in the first data frame when the service type to which the first data frame belongs is a designated service and the first data frame passes the first flow control, the method further comprises: Determining first target service data that passes the second flow control from each service data of the first data frame; Based on the frame structure, encapsulate the first target service data to obtain a second data frame; The second data frame is scheduled periodically using the set first gating strategy.

8. The method according to claim 3, characterized in that In the case where the service type to which the first data frame belongs is a non-designated service and the first data frame passes the first flow control, after performing the second flow control on each service data in the first data frame according to the number of fourth real-time tokens in a fourth sub-token bucket matching each service data in the first data frame and the priority of each service data, the method further includes: Determining second target service data that passes the second flow control from each service data of the first data frame; Based on the set frame structure, encapsulate the second target service data to obtain a third data frame; The third data frame is scheduled using the set second gating strategy.

9. The method according to claim 1, characterized in that: The distinguishing the first data frame to determine the service type to which the first data frame belongs includes: Obtaining frame header information of the first data frame; Determining a target service type from a plurality of reference service types according to the frame header information, wherein the target service type matches the frame header information; The target service type is used as the service type to which the first data frame belongs.

10. The method according to any one of claims 1 to 9, characterized in that The step of decapsulating the received data packet according to the set frame structure to obtain a first data frame includes: Determine the data type of each service data in the data packet; Determine the location information of each service data in the frame structure according to the data type and data volume corresponding to each service data; Decapsulate each of the service data according to the position information of each of the service data in the frame structure to obtain a first data frame.

11. A flow control device, characterized in that: include: A decapsulation module, used for decapsulating the received data packet according to a set frame structure to obtain a first data frame; A distinguishing module, used for distinguishing the first data frame to determine the service type to which the first data frame belongs; A first flow control module, configured to perform a first flow control on the first data frame by using a first token bucket matching a service type of the first data frame to determine whether the first data frame passes the first flow control; The second flow control module is used to use a second token bucket matching each business data in the first data frame to perform second flow control on each business data in the first data frame when the first data frame passes the first flow control.

12. An electronic device, characterized in that: The method comprises a memory, a processor and a computer program stored in the memory and executable on the processor. When the processor executes the program, the flow control method according to any one of claims 1 to 10 is implemented.

Citation Information

Cited By

  • Traffic scheduling method and device, electronic equipment and storage medium

    CN121418359A