[go: up one dir, main page]

HK1243565B - Systems and method for single queue multi-stream traffic shaping - Google Patents

Systems and method for single queue multi-stream traffic shaping Download PDF

Info

Publication number
HK1243565B
HK1243565B HK18101465.4A HK18101465A HK1243565B HK 1243565 B HK1243565 B HK 1243565B HK 18101465 A HK18101465 A HK 18101465A HK 1243565 B HK1243565 B HK 1243565B
Authority
HK
Hong Kong
Prior art keywords
network interface
data
queue
data packets
transmission
Prior art date
Application number
HK18101465.4A
Other languages
Chinese (zh)
Other versions
HK1243565A1 (en
Inventor
Contavalli Carlo
Original Assignee
Google Llc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Google Llc filed Critical Google Llc
Publication of HK1243565A1 publication Critical patent/HK1243565A1/en
Publication of HK1243565B publication Critical patent/HK1243565B/en

Links

Description

单队列多流业务整形的系统和方法System and method for single-queue multi-flow service shaping

背景技术Background Art

业务整形是通过放慢被确定为比优先的业务流更不重要或比优先的业务流更不期望的业务流来调控网络数据业务的技术。存在两种放慢流的通用机制:第一种,放弃或丢弃某些分组,以及第二种,将分组延迟。分组放弃机制被广泛使用并且在众多情况下被当作唯一可行的方案。例如,如果由计算机连接到的单独的设备来执行,业务整形能够通过选择性地放弃分组来执行。Traffic shaping is a technique used to regulate network data traffic by slowing down traffic flows that are determined to be less important or less desirable than prioritized traffic flows. There are two common mechanisms for slowing down traffic flows: first, dropping or discarding certain packets, and second, delaying packets. The packet drop mechanism is widely used and, in many cases, is the only viable option. For example, if performed by a separate device to which a computer is connected, traffic shaping can be performed by selectively dropping packets.

替选地,分组延迟机制能够免除分组放弃或者减少所放弃分组的数目。例如,当分组被延迟时,反馈机制能够发挥“反压力”,即,发送反馈到发送模块(例如,设备或软件组件)以使得发送模块降低其发送分组的速率。在没有这样的“反压力”的情况下,业务整形模块将需要以更快的速率保持接收分组,并且需要缓冲他们,直到其能够以正确的速率来发送他们。缺少这样的“反压力”将不仅防止应用立即知晓业务拥塞,而且还使得分组传输系统的整体吞吐量和性能降级。Alternatively, a packet delay mechanism can eliminate packet abandonment or reduce the number of abandoned packets. For example, when packets are delayed, a feedback mechanism can exert "back pressure", that is, send feedback to the sending module (e.g., a device or software component) to cause the sending module to reduce the rate at which it sends packets. In the absence of such "back pressure", the traffic shaping module will need to keep receiving packets at a faster rate and will need to buffer them until it can send them at the correct rate. The lack of such "back pressure" will not only prevent applications from immediately becoming aware of traffic congestion, but will also degrade the overall throughput and performance of the packet transmission system.

发明内容Summary of the Invention

在一个方面中,给出了一种包括网络设备的系统。网络设备包括:网络接口驱动器、数据业务整形模块以及网卡。网络接口驱动器被配置为发送由软件应用所生成并且转发的第一数据分组集合以由网卡传输,按照第一顺序在主传输队列中存储与所接收的第一数据分组集合相关联的描述符,以及将与所接收的第一数据分组集合相关联的描述符传递到在网卡和至少一个处理器中的一者上执行的数据业务整形模块。响应于确定网卡已经成功传送所接收的第一分组集合中的分组,网络接口驱动器被配置为在将附加数据分组转发到网络接口驱动器之前,将分组传输完成消息通信到等待接收来自网络接口驱动器的分组传输完成消息的软件应用。数据业务整形模块被配置为维持多个业务整形队列,每个业务整形队列具有至少一个相关联的传输速率规则。数据业务整形模块进一步被配置为接收来自主传输队列的由网络接口驱动器所传递的数据分组的描述符,确定网卡的传输将被延迟,以及响应于这样的确定,从主传输队列中移除描述符并且基于分类的结果将其存储在对应的业务整形队列中。数据业务整形模块进一步被配置为使得网卡根据与相应的业务整形队列相关联的传输速率规则来传送与存储在辅助业务整形队列中的描述符相关联的数据分组,以及向网络接口驱动器通知以不同于第一顺序的第二顺序对数据分组的成功传输。In one aspect, a system including a network device is provided. The network device includes a network interface driver, a data traffic shaping module, and a network interface card. The network interface driver is configured to send a first set of data packets generated and forwarded by a software application for transmission by the network interface card, store descriptors associated with the received first set of data packets in a primary transmit queue in a first order, and pass the descriptors associated with the received first set of data packets to the data traffic shaping module executed on one of the network interface card and at least one processor. In response to determining that the network interface card has successfully transmitted a packet in the received first set of packets, the network interface driver is configured to communicate a packet transmission completion message to the software application waiting to receive the packet transmission completion message from the network interface driver before forwarding additional data packets to the network interface driver. The data traffic shaping module is configured to maintain a plurality of traffic shaping queues, each traffic shaping queue having at least one associated transmission rate rule. The data traffic shaping module is further configured to receive descriptors of data packets delivered by the network interface driver from the primary transmit queue, determine that transmission by the network card will be delayed, and, in response to such determination, remove the descriptors from the primary transmit queue and store them in a corresponding traffic shaping queue based on the classification result. The data traffic shaping module is further configured to cause the network card to transmit data packets associated with the descriptors stored in the auxiliary traffic shaping queue according to a transmission rate rule associated with the corresponding traffic shaping queue, and notify the network interface driver of successful transmission of the data packets in a second order different from the first order.

在一个方面中,给出了一种方法,包括由在至少一个处理器上执行的网络接口驱动器接收由软件应用所生成并且转发的第一数据分组集合,以由网卡传输。所述方法进一步包括:由网络接口驱动器按照第一顺序在主传输队列中存储与所接收的第一数据分组集合相关联的描述符;以及由网络接口驱动器将与所接收的第一数据分组集合相关联的描述符传递到在网卡和所述至少一个处理器中的一者上执行的数据业务整形模块。所述方法进一步包括响应于确定网卡已经成功传送所接收的第一数据分组集合中的分组,在将附加数据分组转发到网络接口驱动器之前,由网络接口驱动器将分组传输完成消息通信到等待接收来自网络接口驱动器的分组传输完成消息的软件应用。所述方法进一步包括由数据业务整形模块维持多个业务整形队列,其中每个业务整形队列具有至少一个相关联的传输速率规则;以及由数据业务整形模块接收来自主传输队列的由网络接口驱动器所传递的数据分组的描述符。所述方法进一步包括由数据业务整形模块对与所接收的描述符相关联的数据分组进行分类;由数据业务整形模块确定网卡对与所接收的第一描述符相关联的第一数据分组的传输将被延迟,以及响应于这样的确定,从主传输队列中移除与第一数据分组相关联的第一描述符并且基于分类的结果将所述第一描述符存储在对应的业务整形队列中。所述方法进一步包括由数据业务整形模块使得网卡根据与相应的业务整形队列相关联的传输速率规则来传送与存储在业务整形队列中的描述符相关联的数据分组;以及由数据业务整形模块向网络接口驱动器通知以不同于第一顺序的第二顺序对所述数据分组的成功传输。In one aspect, a method is provided that includes receiving, by a network interface driver executing on at least one processor, a first set of data packets generated and forwarded by a software application for transmission by a network interface card. The method further includes: storing, by the network interface driver, descriptors associated with the received first set of data packets in a primary transmit queue in a first order; and communicating, by the network interface driver, the descriptors associated with the received first set of data packets to a data traffic shaping module executing on one of the network interface card and the at least one processor. The method further includes, in response to determining that the network interface card has successfully transmitted a packet in the received first set of data packets, communicating, by the network interface driver, a packet transmission completion message to the software application awaiting receipt of the packet transmission completion message from the network interface driver before forwarding additional data packets to the network interface driver. The method further includes maintaining, by the data traffic shaping module, a plurality of traffic shaping queues, each traffic shaping queue having at least one associated transmission rate rule; and receiving, by the data traffic shaping module, the descriptors of the data packets communicated by the network interface driver from the primary transmit queue. The method further includes classifying, by the data traffic shaping module, data packets associated with the received descriptor; determining, by the data traffic shaping module, that transmission of a first data packet associated with the received first descriptor by the network interface card will be delayed, and in response to such determination, removing the first descriptor associated with the first data packet from a main transmission queue and storing the first descriptor in a corresponding traffic shaping queue based on the classification result. The method further includes causing, by the data traffic shaping module, the network interface card to transmit the data packets associated with the descriptor stored in the traffic shaping queue according to a transmission rate rule associated with the corresponding traffic shaping queue; and notifying, by the data traffic shaping module, the network interface driver of the successful transmission of the data packets in a second order different from the first order.

在一个方面中,一种计算机可读介质,存储当由计算处理器运行时使得计算处理器执行如下操作的指令:经由在计算处理器上中的网络接口驱动器接收由软件应用所生成并且转发的第一数据分组集合,以由网卡传输。进一步使得所述计算处理器经由网络接口驱动器在主传输队列中存储与所接收的第一数据分组集合相关联的描述符。进一步使得所述计算处理器经由网络接口驱动器将与所接收的第一数据分组集合相关联的描述符传递到在网卡和所述计算处理器中的一者上执行的数据业务整形模块。响应于确定网卡已经成功传送所接收的第一分组集合中的分组,进一步使得所述计算处理器在将附加数据分组转发到网络接口驱动器之前,经由网络接口驱动器将分组传输完成消息通信到等待接收来自网络接口驱动器的分组传输完成消息的软件应用。进一步使得所述计算处理器经由数据业务整形模块维持多个业务整形队列,其中每个业务整形队列具有至少一个相关联的传输速率规则。进一步使得所述计算处理器经由数据业务整形模块接收来自主传输队列的由网络接口驱动器所传递的数据分组的描述符;以及经由数据业务整形模块对与所接收的描述符相关联的数据分组进行分类。进一步使得所述计算处理器经由数据业务整形模块确定网卡对与所接收的第一描述符相关联的第一数据分组的传输将被延迟,以及响应于这样的确定,从主传输队列中移除与第一数据分组相关联的第一描述符并且基于分类的结果在对应的业务整形队列中存储第一描述符。所述计算处理器进一步经由数据业务整形模块使得网卡根据与相应的业务整形队列相关联的传输速率规则来传送与存储在业务整形队列中的描述符相关联的数据分组。进一步使得所述计算处理器:经由数据业务整形模块向网络接口驱动器通知对所述数据分组的成功传输。In one aspect, a computer-readable medium stores instructions that, when executed by a computing processor, cause the computing processor to: receive, via a network interface driver on the computing processor, a first set of data packets generated and forwarded by a software application for transmission by a network interface card. The computing processor is further caused to store, via the network interface driver, descriptors associated with the received first set of data packets in a primary transmit queue. The computing processor is further caused to communicate, via the network interface driver, the descriptors associated with the received first set of data packets to a data traffic shaping module executing on one of the network interface card and the computing processor. In response to determining that the network interface card has successfully transmitted a packet in the received first set of packets, the computing processor is further caused to communicate, via the network interface driver, a packet transmission completion message to the software application awaiting receipt of the packet transmission completion message from the network interface driver before forwarding additional data packets to the network interface driver. The computing processor is further caused to maintain, via the data traffic shaping module, a plurality of traffic shaping queues, each traffic shaping queue having at least one associated transmission rate rule. The computing processor is further caused to receive, via the data traffic shaping module, a descriptor of a data packet delivered by the network interface driver from the primary transmission queue; and to classify, via the data traffic shaping module, the data packet associated with the received descriptor. The computing processor is further caused to determine, via the data traffic shaping module, that transmission of a first data packet associated with the received first descriptor by the network card will be delayed, and in response to such determination, remove the first descriptor associated with the first data packet from the primary transmission queue and store the first descriptor in a corresponding traffic shaping queue based on the classification result. The computing processor is further caused to cause, via the data traffic shaping module, the network card to transmit the data packet associated with the descriptor stored in the traffic shaping queue according to a transmission rate rule associated with the corresponding traffic shaping queue. The computing processor is further caused to notify the network interface driver, via the data traffic shaping module, of the successful transmission of the data packet.

附图说明BRIEF DESCRIPTION OF THE DRAWINGS

当结合以下附图时,通过参考以下具体实施方式部分,将更全面地理解本公开的以上和相关的对象、特征、以及优点,其中:The above and related objects, features, and advantages of the present disclosure will be more fully understood by referring to the following detailed description when taken in conjunction with the following drawings, in which:

图1为根据某些实施方式的具有数据业务整形系统的网络环境的框图;FIG1 is a block diagram of a network environment having a data traffic shaping system according to certain embodiments;

图2为示例虚拟机环境的框图;FIG2 is a block diagram of an example virtual machine environment;

图3为根据某些实施方式的示出网络接口驱动器的操作的流程图;3 is a flow chart illustrating the operation of a network interface driver according to certain embodiments;

图4为根据某些实施方式的示出数据整形模块的操作的流程图;FIG4 is a flow chart illustrating the operation of a data shaping module according to certain embodiments;

图5为根据某些实施方式的示出网络接口驱动器的操作的流程图;5 is a flow chart illustrating the operation of a network interface driver according to certain embodiments;

图6A-6D为根据某些实施方式的表示数据业务整形系统的操作示例的框图;6A-6D are block diagrams illustrating examples of operations of a data traffic shaping system according to certain embodiments;

图7A-7D为根据某些实施方式的表示数据业务整形系统的操作示例的框图;7A-7D are block diagrams illustrating examples of operations of a data traffic shaping system according to certain embodiments;

图8A-8C为根据某些实施方式的表示数据业务整形系统的操作示例的框图;以及8A-8C are block diagrams illustrating examples of the operation of a data traffic shaping system according to certain embodiments; and

图9为示例计算系统的框图。9 is a block diagram of an example computing system.

具体实施方式DETAILED DESCRIPTION

给出了涉及网络设备中的业务整形的系统和方法。在某些实施方式中,所述系统和方法包括网络设备的网络接口驱动器,其被配置为存储与传输队列中所接收的分组相关联的描述符并且将所述描述符传递到业务整形模块。所接收的分组源自在计算设备上运行的应用,例如计算设备所托管的一个或多个虚拟机上。虚拟机的访客操作系统防止应用转发附加分组到网络接口驱动器,直到接收到确认已经成功传送之前所转发分组的消息。如本文中所述,在某些实施方式中,响应于确定网卡成功传送所接收的分组中的第一分组,在转发附加数据分组到网络接口驱动器之前,网络接口驱动器将分组传输完成消息通信到等待接收分组传输完成消息的软件应用或访客操作系统。在某些实施方式中,响应于确定网卡传输所接收的分组中的一个分组将被延迟,业务整形模块从传输队列中移除与分组相关联的描述符并且将所述描述符存储在对应的业务整形队列中。该配置能够利用网络接口驱动器中的单个主传输队列以及采用不同的业务整形规则的多个业务整形队列(例如,在网络接口卡中)来实现,因而允许按照每个流的业务整形,而不需要网络接口驱动器中的多个传输队列。进而,利用这一配置,分组源(诸如运行在网络设备的真实OS上(与虚拟机的访客OS 上相反)的软件应用、或由管理程序管理的访客OS中的软件应用或 TCP栈的上层)不需要知晓在网络接口驱动器中或在网卡上实现的业务整形算法。因此,能够降低在虚拟机环境中实现网络接口驱动器和访客操作系统的成本。此外,利用这一配置,分组源不需要知晓的不仅是业务整形算法,还有其他配置,例如,分组分类规则和其他业务管理策略。因此,整体业务整形系统能够比其中应用或用户能够配置这样的具体规则和策略(例如,队列的数目)的系统更可靠。Systems and methods are provided for traffic shaping in a network device. In some embodiments, the systems and methods include a network interface driver of the network device configured to store descriptors associated with packets received in a transmit queue and pass the descriptors to a traffic shaping module. The received packets originate from an application running on a computing device, such as one or more virtual machines hosted by the computing device. The guest operating system of the virtual machine prevents the application from forwarding additional packets to the network interface driver until a message confirming that previously forwarded packets have been successfully transmitted is received. As described herein, in some embodiments, in response to determining that a network interface card successfully transmitted a first packet of the received packets, before forwarding the additional data packets to the network interface driver, the network interface driver communicates a packet transmission completion message to a software application or guest operating system waiting to receive the packet transmission completion message. In some embodiments, in response to determining that transmission of one of the received packets by the network interface driver will be delayed, the traffic shaping module removes the descriptors associated with the packets from the transmit queue and stores the descriptors in a corresponding traffic shaping queue. This configuration can be implemented using a single main transmission queue in the network interface driver and multiple traffic shaping queues (for example, in the network interface card) that use different traffic shaping rules, thereby allowing traffic shaping on a per-flow basis without the need for multiple transmission queues in the network interface driver. Furthermore, using this configuration, the packet source (such as a software application running on the real OS of the network device (as opposed to the guest OS of the virtual machine), or a software application in the guest OS managed by the hypervisor or the upper layer of the TCP stack) does not need to know the traffic shaping algorithm implemented in the network interface driver or on the network card. Therefore, the cost of implementing the network interface driver and the guest operating system in the virtual machine environment can be reduced. In addition, using this configuration, the packet source does not need to know not only the traffic shaping algorithm, but also other configurations, such as packet classification rules and other traffic management policies. Therefore, the overall traffic shaping system can be more reliable than a system in which the application or user can configure such specific rules and policies (for example, the number of queues).

在传统的系统中,按照传输队列的顺序来处理分组,所述传输队列例如为先入先出(FIFO)队列,并且完成结果按顺序返回。在本公开的某些实施方式中,业务整形模块能够通过从传输队列中移除某些数据分组用于已延迟的传输(在不放弃的情况下)来使得完成消息无序返回。利用“无序完成”这一配置,因为应用在接收到已经转发到网络接口驱动器的数据分组的完成消息之前将不再发送更多数据分组,这能够使得应用更快或更慢地传送数据分组,同时仍然拥有单个传输队列。也就是,这一配置能够通过防止将延迟的数据分组仍然保持在队列中来避免队头阻塞。此外,在某些实施方式中,这一“无序”完成配置能够应用于应用内的数据分组的单独的流(flow)(或流 (stream)),使得能够选择性地放慢每个流,其中所述应用例如为具有为对应的流(flow)或流(stream)而打开的成千的连接的应用。In conventional systems, packets are processed in the order of the transmission queue, which is, for example, a first-in, first-out (FIFO) queue, and completion results are returned in order. In certain embodiments of the present disclosure, the traffic shaping module can cause completion messages to be returned out of order by removing certain data packets from the transmission queue for delayed transmission (without giving up). With the "out of order completion" configuration, because the application will no longer send more data packets before receiving the completion message for the data packet that has been forwarded to the network interface driver, this can enable the application to transmit data packets faster or slower while still having a single transmission queue. That is, this configuration can avoid head-of-line blocking by preventing delayed data packets from remaining in the queue. In addition, in certain embodiments, this "out of order" completion configuration can be applied to separate flows (or streams) of data packets within an application, making it possible to selectively slow down each flow, wherein the application is, for example, an application with thousands of connections opened for the corresponding flow or stream.

进而,在某些实施方式中,在没有队头阻塞的情况下,“无序”完成配置能够发挥“反压力”到发送模块,这与有多少主传输队列或每个队列中放了多少分组无关,只要完成消息能够无序返回。在某些实施方式中,具有无序完成配置的业务整形机制能够利用特定的网络/硬件配置(例如,特定数目的主传输队列和特定的队列指派规则)来实现。例如,为了对业务的一千个流(flow)/流(stream)进行整形,业务整形机制能够利用仅单个队列或者利用少量的队列(例如,16-32个队列) 来实现。当在具有少量的队列的系统中实现时,业务整形机制能够返回“无序”完成消息,指示每个分组是基于预定的队列指派规则而放在正确的队列中还是分组业务“随机地”散布在队列上。例如,在不修改网络/硬件配置(例如,Linux系统的队列指派规则或硬件队列的数目) 的情况下,用于对来自Linux系统的散布在多个硬件队列上的分组业务进行整形的“无序”完成业务整形系统能够在虚拟机中实现。在某些实施方式中,业务整形系统能够通过向应用或用户隐藏业务整形层、流分类规则和策略来提供这样的网络/硬件兼容性。Furthermore, in some embodiments, in the absence of head-of-line blocking, an "out-of-order" completion configuration can exert "back pressure" on the sending module, regardless of how many main transmission queues there are or how many packets are placed in each queue, as long as the completion messages can be returned out of order. In some embodiments, a traffic shaping mechanism with an out-of-order completion configuration can be implemented using a specific network/hardware configuration (e.g., a specific number of main transmission queues and specific queue assignment rules). For example, in order to shape a thousand flows/streams of traffic, the traffic shaping mechanism can be implemented using only a single queue or a small number of queues (e.g., 16-32 queues). When implemented in a system with a small number of queues, the traffic shaping mechanism can return "out-of-order" completion messages, indicating whether each packet is placed in the correct queue based on a predetermined queue assignment rule or whether the packet traffic is "randomly" spread across the queues. For example, without modifying the network/hardware configuration (e.g., the queue assignment rules or the number of hardware queues in the Linux system), a traffic shaping system for shaping packet traffic from a Linux system spread across multiple hardware queues can be implemented in a virtual machine. In some embodiments, the traffic shaping system can provide such network/hardware compatibility by hiding the traffic shaping layer, flow classification rules, and policies from applications or users.

图1为具有数据业务整形系统160的示例网络环境1000的框图。按照概述,图示的网络环境包括互连的网络节点750的网络700。网络节点750以数据源、数据目的地(或数据宿)、以及通过网络700从源朝目的地传播数据的中间节点来参与到网络700中。网络700包括具有到各种其他参与的网络节点750的链路600的网络设备110的数据业务整形系统160。详见图1,网络700为促进参与设备间的交互的网络。说明性的示例网络700为互联网;然而,在其他实施方式中,网络700可以为另一网络,诸如数据中心内的本地网络、网络结构、或任意其他局域或广域网。网络700可以由多个连接的子网或自治网络组成。网络700能够为局域网(LAN),诸如企业内联网、城域网 (MAN)、广域网(WAN)、诸如互联网的互连网络、或者例如为自组织WiFi对等点对点网络的对等网络。任意类型和/或形式的数据网络和/或通信网络都能够用于网络700。其能够为公共的、私有的、或公共网络和私有网络的组合。一般地,网络700用于在计算设备之间传递信息,例如,在网络节点750之间,并且数据业务整形系统的网络设备110根据其配置促进该通信。FIG1 is a block diagram of an example network environment 1000 having a data traffic shaping system 160. In overview, the illustrated network environment includes a network 700 of interconnected network nodes 750. Network nodes 750 participate in network 700 as data sources, data destinations (or sinks), and intermediate nodes that propagate data from the sources to the destinations through network 700. Network 700 includes a data traffic shaping system 160 of network devices 110 having links 600 to various other participating network nodes 750. As shown in FIG1 , network 700 is a network that facilitates interaction between participating devices. The illustrative example network 700 is the Internet; however, in other embodiments, network 700 can be another network, such as a local network within a data center, a network fabric, or any other local or wide area network. Network 700 can be composed of multiple connected subnets or autonomous networks. Network 700 can be a local area network (LAN) such as a corporate intranet, a metropolitan area network (MAN), a wide area network (WAN), an interconnected network such as the Internet, or a peer-to-peer network such as an ad hoc WiFi peer-to-peer network. Any type and/or form of data network and/or communication network can be used for network 700. It can be public, private, or a combination of public and private networks. Generally, network 700 is used to communicate information between computing devices, such as network nodes 750, and network devices 110 of the data traffic shaping system facilitate this communication according to their configuration.

参见图1,网络设备110为托管一个或多个虚拟机的服务器。网络设备110包括数据业务整形系统160。在某些实施方式中,网络设备 110包括存储器112、以及网卡168。网络设备110能够包括用于存储数据分组的分组缓冲器169。在某些实施方式中,网络设备110具有与如图9中所示的计算系统140的配置类似的配置。例如,存储器112 能够具有与如图9中所示的存储器144的配置类似的配置,以及网卡 168能够具有与如图9中所示的网络接口146或网络接口控制器143的配置类似的配置。以下参照图9更详细地描述计算系统140。图9中图示的计算系统140中示出的元件不都需要在图1中图示的网络设备110 的某些实施方式中给出。在某些实施方式中,网络设备110可以为软件队列或仿真的网络设备、或充当网络接口的软件。Referring to Figure 1 , network device 110 is a server that hosts one or more virtual machines. Network device 110 includes a data traffic shaping system 160. In certain embodiments, network device 110 includes memory 112 and a network interface card 168. Network device 110 can also include a packet buffer 169 for storing data packets. In certain embodiments, network device 110 has a configuration similar to that of computing system 140 shown in Figure 9 . For example, memory 112 can have a configuration similar to that of memory 144 shown in Figure 9 , and network interface card 168 can have a configuration similar to that of network interface 146 or network interface controller 143 shown in Figure 9 . Computing system 140 is described in more detail below with reference to Figure 9 . Not all elements shown in computing system 140 illustrated in Figure 9 are necessarily present in certain embodiments of network device 110 illustrated in Figure 1 . In certain embodiments, network device 110 can be a software queue or emulated network device, or software acting as a network interface.

再次参见图1,在某些实施方式中,数据业务整形系统160与一个或多个应用150(例如,应用150A、150B以及150C)通信。应用 150A-150C中的一个或多个应用能够为运行在网络设备110的真实操作系统上的软件应用。除此之外,软件应用150A-150C中的一个或多个软件应用能够为运行在由虚拟机环境中的管理程序管理的访客OS 上的软件应用、或虚拟机环境的访客OS的协议栈(例如,TCP栈)的上层。例如,参见图2,应用150A-150C能够各自为运行在真实OS 220 上的软件应用230、运行在由管理程序250管理的访客OS 260上的软件应用265、或图2中的访客OS 260的协议栈261的上层。管理程序 250和与其相关的虚拟机环境将在以下参照图2详细描述。Referring again to FIG. 1 , in some embodiments, data traffic shaping system 160 communicates with one or more applications 150 (e.g., applications 150A, 150B, and 150C). One or more of applications 150A-150C can be software applications running on the real operating system of network device 110. Furthermore, one or more of software applications 150A-150C can be software applications running on a guest OS managed by a hypervisor in a virtual machine environment, or upper layers of a protocol stack (e.g., a TCP stack) of a guest OS in a virtual machine environment. For example, referring to FIG. 2 , applications 150A-150C can each be software application 230 running on real OS 220, software application 265 running on guest OS 260 managed by hypervisor 250, or upper layers of protocol stack 261 of guest OS 260 in FIG. Hypervisor 250 and its associated virtual machine environment will be described in detail below with reference to FIG. 2 .

仍旧参见图1,在某些实施方式中,网络设备110包括网络接口驱动器164和数据业务整形模块166。网络接口驱动器164能够为运行在真实OS上的网络接口驱动模块。网络接口驱动器164能够直接地(如果运行在网络设备110的真实OS上)、经由虚拟机的访客OS(如果运行在虚拟机环境中)、或在某些实施方式中通过管理程序和访客OS 来与软件应用150A-150C(例如,图2中的应用265)中的一个软件应用通信。在某些实施方式中,网络接口驱动器164包括在网络设备110 的真实OS的传输控制协议(TCP)栈的第一层内并且与包括在TCP 栈的上层中的软件模块或应用通信。在一个示例中,网络接口驱动器 164包括在TCP栈的传输层内并且与包括在TCP栈的应用层中的软件模块或应用通信。在另一示例中,网络接口驱动器164包括在TCP栈的链路层内并且与包括在TCP栈的互联网/传输层中的TCP/IP模块通信。Still referring to FIG. 1 , in some embodiments, network device 110 includes a network interface driver 164 and a data traffic shaping module 166. Network interface driver 164 can be a network interface driver module running on a real operating system. Network interface driver 164 can communicate with one of software applications 150A-150C (e.g., application 265 in FIG. 2 ) directly (if running on the real operating system of network device 110), via a guest operating system of a virtual machine (if running in a virtual machine environment), or, in some embodiments, through a hypervisor and a guest operating system. In some embodiments, network interface driver 164 is included within the first layer of the Transmission Control Protocol (TCP) stack of the real operating system of network device 110 and communicates with software modules or applications included in upper layers of the TCP stack. In one example, network interface driver 164 is included within the transport layer of the TCP stack and communicates with software modules or applications included in the application layer of the TCP stack. In another example, network interface driver 164 is included within the link layer of the TCP stack and communicates with a TCP/IP module included in the internet/transport layer of the TCP stack.

再次参见图1,在某些实施方式中,数据业务整形模块166能够被实现为运行在真实OS上的网络接口驱动模块的一部分。在某些实施方式中,数据业务整形模块166能够作为网卡168的一部分而被包括。1 , in some embodiments, the data traffic shaping module 166 can be implemented as part of a network interface driver module running on a real OS. In some embodiments, the data traffic shaping module 166 can be included as part of a network card 168 .

参见图1,在某些实施方式中,能够将分组缓冲器169定位在网络设备110的共享存储器中,使得应用150、网卡168、网络接口驱动器164以及数据业务整形模块166中的某些或全部能够直接或间接地访问分组缓冲器169。例如,能够将分组缓冲器169定位在访客OS、真实OS、网络接口驱动器164、以及网卡168可访问的共享存储器中。为了通过网络发送分组,在传输到网卡168之前,能够将数据分组存储在分组缓冲器169中,其中分组缓冲器169能够由网络接口驱动器 164和网卡168访问。1 , in some embodiments, packet buffer 169 can be located in a shared memory of network device 110, such that some or all of application 150, network card 168, network interface driver 164, and data traffic shaping module 166 can directly or indirectly access packet buffer 169. For example, packet buffer 169 can be located in a shared memory accessible to a guest OS, a real OS, network interface driver 164, and network card 168. To send packets over the network, data packets can be stored in packet buffer 169 before being transmitted to network card 168, where packet buffer 169 is accessible to network interface driver 164 and network card 168.

图2示出了实现虚拟机环境的示例服务器200的框图。在某些实施方式中,服务器200包括硬件210、运行在硬件210上的真实操作系统(OS)220、管理程序250、具有访客操作系统(访客OS)260和 270的两个虚拟机。硬件210能够包括网络接口卡(NIC)215、以及其他组件。硬件210能够具有与如图9中所示的计算系统140的配置类似的配置。硬件210的NIC215能够具有与如图9中所示的网络接口控制器143或网络接口146 的配置类似的配置。在某些实施方式中,真实OS 220具有协议栈225(例如,TCP栈)并且具有运行在真实OS 220上的软件应用。在某些实施方式中,访客OS 260和270分别具有协议栈261和271。访客OS 260和270中的每个能够托管大量的应用,例如,软件应用265、266、275以及276。服务器200可以为文件服务器、应用服务器、web服务器、代理服务器、电器、网络电器、网关、网关服务器、虚拟服务器、部署服务器、SSL VPN服务器、或防火墙。FIG2 shows a block diagram of an example server 200 implementing a virtual machine environment. In certain embodiments, server 200 includes hardware 210, a real operating system (OS) 220 running on hardware 210, a hypervisor 250, and two virtual machines with guest operating systems (guest OSs) 260 and 270. Hardware 210 can include a network interface card (NIC) 215, among other components. Hardware 210 can have a configuration similar to that of computing system 140, as shown in FIG9 . NIC 215 of hardware 210 can have a configuration similar to that of network interface controller 143 or network interface 146, as shown in FIG9 . In certain embodiments, real OS 220 has a protocol stack 225 (e.g., a TCP stack) and software applications running on real OS 220. In certain embodiments, guest OSs 260 and 270 have protocol stacks 261 and 271, respectively. Each of guest OSs 260 and 270 can host a large number of applications, such as software applications 265, 266, 275, and 276. Server 200 may be a file server, an application server, a web server, a proxy server, an appliance, a network appliance, a gateway, a gateway server, a virtual server, a deployment server, an SSL VPN server, or a firewall.

再次参见图2,服务器200执行管理程序,所述管理程序实例化并且管理第一访客OS 260和第二访客OS 270。第一访客OS 260托管第一软件应用265和第二软件应用266。第二访客OS 270托管第三软件应用275和第四软件应用276。例如,应用能够包括数据库服务器、数据仓库程序、股市交易软件、网上银行应用、内容发布和管理系统、被托管的视频游戏、被托管的桌面、电子邮件服务器、旅行预定系统、客户关系管理应用、存货控制管理数据库、以及企业资源管理系统。在某些实施方式中,访客OS托管其他种类的应用。进一步在以下关于图3-5及图6A-6D描述服务器200的组件之间的交互。Referring again to FIG. 2 , server 200 executes a hypervisor that instantiates and manages a first guest OS 260 and a second guest OS 270. First guest OS 260 hosts a first software application 265 and a second software application 266. Second guest OS 270 hosts a third software application 275 and a fourth software application 276. For example, the applications can include a database server, a data warehouse program, stock trading software, an online banking application, a content publishing and management system, a hosted video game, a hosted desktop, an email server, a travel reservation system, a customer relationship management application, an inventory control management database, and an enterprise resource management system. In some embodiments, the guest OSes host other types of applications. The interactions between the components of server 200 are further described below with respect to FIG. 3-5 and FIG. 6A-6D .

图3为使用网络接口驱动器所执行的示例方法300来对网络业务进行整形的流程图,所述网络接口驱动器诸如图1中所示的网络接口驱动器164。按照概述,方法300开始于阶段310,其中网络接口驱动器能够接收由应用生成并且转发的第一数据分组集合,以由网卡传输,所述网卡诸如图1中所示的网卡168。在阶段320,网络接口驱动器能够在主传输队列中存储与所接收的第一数据分组集合相关联的描述符。在阶段330,网络接口驱动器能够传递与所接收的第一数据分组集合相关联的描述符到数据业务整形模块,诸如图1中所示的数据业务整形模块166。FIG3 is a flow chart of an example method 300 for shaping network traffic using a network interface driver, such as the network interface driver 164 shown in FIG1 . In summary, the method 300 begins at stage 310, where the network interface driver can receive a first set of data packets generated by an application and forwarded for transmission by a network interface card, such as the network interface card 168 shown in FIG1 . At stage 320, the network interface driver can store descriptors associated with the received first set of data packets in a primary transmit queue. At stage 330, the network interface driver can pass the descriptors associated with the received first set of data packets to a data traffic shaping module, such as the data traffic shaping module 166 shown in FIG1 .

现在,将参照图6A和6B来更详细地描述图3中的流程图,图6A 和6B为根据某些实施方式的表示数据业务整形系统的操作示例的框图。The flowchart in FIG. 3 will now be described in more detail with reference to FIGs. 6A and 6B , which are block diagrams representing examples of the operation of a data traffic shaping system according to certain embodiments.

在阶段310,网络接口驱动器能够接收由应用生成并且转发的第一数据分组集合,以由网卡传输。例如,参见图6A,网络接口驱动器 164接收由应用150A-150C的集合中的一个应用生成并且转发的一个数据分组集合,以由网卡168传输。在某些实施方式中,响应于接收到该数据分组集合,网络接口驱动器164在分组缓冲器(例如,图1 和6A-6D中的分组缓冲器169)中存储所接收的该数据分组集合。例如,作为共享的资源,能够将分组缓冲器169定位在访客OS与网络接口驱动器164之间的共享存储器中,使得能够将从运行在访客OS上的应用150发送的分组存储在分组缓冲器169中并且与分组相关联的描述符指向共享资源内的位置。在某些实施方式中,包含指向分组缓冲器中特定分组的指针(例如,存储器地址)的描述符与特定分组相关联。在某些实施方式中,描述符通常很小(例如,32个字节或者包括少数64比特的整数)并且易于处理,而分组通常为最小几百字节,并且经常为1500个字节。At stage 310, the network interface driver can receive a first set of data packets generated and forwarded by an application for transmission by the network interface card. For example, referring to FIG6A , network interface driver 164 receives a set of data packets generated and forwarded by one of the applications 150A-150C for transmission by network interface card 168. In some embodiments, in response to receiving the set of data packets, network interface driver 164 stores the received set of data packets in a packet buffer (e.g., packet buffer 169 in FIG1 and FIG6A-6D ). For example, packet buffer 169 can be located in a shared memory between the guest OS and network interface driver 164 as a shared resource, such that packets sent from application 150 running on the guest OS can be stored in packet buffer 169, and a descriptor associated with the packet can point to a location within the shared resource. In some embodiments, a descriptor containing a pointer (e.g., a memory address) to a specific packet in the packet buffer is associated with the specific packet. In some embodiments, descriptors are typically small (eg, 32 bytes or consisting of a few 64-bit integers) and easy to process, while packets are typically a minimum of a few hundred bytes, and often 1500 bytes.

在某些实施方式中,数据分组能够为流的一部分。应用150能够按照特定的顺序来发送每个流中的数据分组。每个流能够来自不同的应用(例如,在不同的访客OS上执行的应用)。在图6A中所示的示例中,应用150A按连续顺序来发送与描述符S1、S2以及S3相对应的第一流的三个分组。应用150B按照连续顺序来发送与描述符T1、T2 以及T3相对应的第二流的三个分组。应用150C发送与描述符U1和 U3相对应的第三流的两个分组。In some embodiments, a data packet can be part of a stream. Application 150 can send the data packets in each stream in a specific order. Each stream can come from a different application (e.g., an application executing on a different guest OS). In the example shown in FIG6A , application 150A sends three packets of a first stream corresponding to descriptors S1, S2, and S3 in a consecutive order. Application 150B sends three packets of a second stream corresponding to descriptors T1, T2, and T3 in a consecutive order. Application 150C sends two packets of a third stream corresponding to descriptors U1 and U3.

在阶段320,网络接口驱动器能够在主传输队列161中存储与所接收的第一数据分组集合相关联的描述符。参见图6A-6D,网络设备 110包括主传输队列161,用于包含与从应用150所接收的数据分组相关联的描述符。在某些实施方式中,主传输队列161为单个队列。在某些实施方式中,主传输队列161能够为硬件队列(例如,在专用硬件中实现的队列)或软件队列。在某些实施方式中,主传输队列161 为一个主传输队列集合。例如,主传输队列161为在多队列NIC中实现的多个队列。在某些实施方式中,该主传输队列集合的数目小于速率限制器(例如,业务整形队列)的数目。例如,为了对成千上万的流(flow)或流(stream)进行整形,网络设备110能够具有约10-约 32个硬件队列,同时具有安装于其中以对成千上万的流进行整形的众多更多的业务整形队列。响应于接收来自应用150的数据分组,网络接口驱动器164将与数据分组相关联的描述符写入单个队列,例如,主传输队列161。在某些实施方式中,网络接口驱动器164按照应用 150发送分组的顺序将与每个流中的数据分组相关联的描述符写入主传输队列161中。例如,如在图6A中所示,网络接口驱动器164接收来自应用150的八个数据分组并且将与分组相关联的描述符(例如,描述符T1、U1、T2、S1、U2、S2、S3、T3)写入主传输队列161,以用于经由网卡168的分组传输。在某些实施方式中,响应于接收来自应用150的数据分组,网络接口驱动器164能够将所接收的分组写入单个传输队列(而非存储与他们相关联的描述符)。At stage 320, the network interface driver can store descriptors associated with the received first set of data packets in a primary transmit queue 161. Referring to Figures 6A-6D, network device 110 includes a primary transmit queue 161 for containing descriptors associated with data packets received from application 150. In some embodiments, primary transmit queue 161 is a single queue. In some embodiments, primary transmit queue 161 can be a hardware queue (e.g., a queue implemented in dedicated hardware) or a software queue. In some embodiments, primary transmit queue 161 is a set of primary transmit queues. For example, primary transmit queue 161 is a plurality of queues implemented in a multi-queue NIC. In some embodiments, the number of primary transmit queues is less than the number of rate limiters (e.g., traffic shaping queues). For example, to shape tens of thousands of flows or streams, network device 110 can have approximately 10 to approximately 32 hardware queues, along with numerous additional traffic shaping queues installed therein to shape tens of thousands of flows. In response to receiving data packets from the application 150, the network interface driver 164 writes descriptors associated with the data packets to a single queue, e.g., the primary transmit queue 161. In some embodiments, the network interface driver 164 writes the descriptors associated with the data packets in each flow to the primary transmit queue 161 in the order in which the packets were sent by the application 150. For example, as shown in FIG6A , the network interface driver 164 receives eight data packets from the application 150 and writes the descriptors associated with the packets (e.g., descriptors T1, U1, T2, S1, U2, S2, S3, T3) to the primary transmit queue 161 for transmission of the packets via the network card 168. In some embodiments, in response to receiving data packets from the application 150, the network interface driver 164 can write the received packets to a single transmit queue (rather than storing the descriptors associated with them).

网络接口驱动器164接收来自应用150A的第一流的分组并且按照他们被传送的顺序来将描述符S1、S2以及S3写入主传输队列161,即, S1,接着S2,接着S3。类似地,网络接口驱动器164从应用150B接收第二流的分组并且按照他们被接收的顺序来将描述符T1、T2以及 T3写入主传输队列161,以及网络接口驱动器164接收来自应用150C 的第三流的分组并且将描述符U1和U2写入主传输队列161。在某些实施方式中,在主传输队列中,不同的流的分组能够被交织,同时维持每个流中的分组的接收顺序。例如,在图6A中所示的示例中,在主传输队列中,不同的流的分组被交织(即,按照T1、U1、T2、S1、 U2、S2、S3以及T3的顺序),同时维持每个流的分组的接收顺序(例如,对于第一流,维持S1->S2->S3的顺序;对于第二流,维持 T1->T2->T3的顺序;以及对于第三流,维持U1->U2的顺序)。Network interface driver 164 receives packets of a first flow from application 150A and writes descriptors S1, S2, and S3 to main transmit queue 161 in the order in which they were transmitted, i.e., S1, then S2, then S3. Similarly, network interface driver 164 receives packets of a second flow from application 150B and writes descriptors T1, T2, and T3 to main transmit queue 161 in the order in which they were received, and network interface driver 164 receives packets of a third flow from application 150C and writes descriptors U1 and U2 to main transmit queue 161. In some embodiments, packets of different flows can be interleaved in the main transmit queue while maintaining the order in which the packets in each flow were received. For example, in the example shown in Figure 6A, in the main transmission queue, packets of different streams are interleaved (i.e., in the order of T1, U1, T2, S1, U2, S2, S3 and T3) while maintaining the reception order of the packets of each stream (e.g., for the first stream, the order of S1->S2->S3 is maintained; for the second stream, the order of T1->T2->T3 is maintained; and for the third stream, the order of U1->U2 is maintained).

在阶段330,网络接口驱动器能够将与所接收的第一数据分组集合相关联的描述符传递到数据业务整形模块。例如,参见图6B,在某些实施方式中,网络接口驱动器164将与所接收的数据分组相关联的描述符(例如,T1、U1、T2、S1、U2、S2、S3、以及T3)传递到数据业务整形模块166。The network interface driver can pass descriptors associated with the received first set of data packets to the data traffic shaping module at stage 330. For example, referring to FIG6B , in some embodiments, the network interface driver 164 passes descriptors associated with the received data packets (e.g., T1, U1, T2, S1, U2, S2, S3, and T3) to the data traffic shaping module 166.

图4为使用由数据业务整形模块执行的示例方法400来对网络业务进行整形的流程图,所述数据业务整形模块诸如图1和图6A-6D中所示的数据业务 整形模块166。按照概述,所述方法400开始于阶段410,其中数据业务整形模块维持多个业务整形队列并且接收来自主传输队列的由网络接口驱动器所传递的数据分组的描述符,所述网络接口驱动器诸如图1和图6A-6D中所示的网络接口驱动器164。在阶段420,数据业务整形模块对与所接收的描述符相关联的数据分组进行分类。在阶段430,数据业务整形模块确定网卡对与所接收的第一描述符相关联的第一数据分组的传输是否将被延迟,其中,所述网卡诸如图1和图6A-6D中所示的网卡168。在阶段440,如果数据业务整形模块确定网卡对与所接收的第一描述符相关联的第一数据分组的传输将被延迟,数据业务整形模块从主传输队列中移除与第一数据分组相关联的第一描述符并且基于分类的结果来将第一描述符存储在对应的业务整形队列中。接着,在阶段450,数据业务整形模块使得网卡根据与相应的业务整形队列相关联的传输速率规则来传送与存储在业务整形队列中的描述符相关联的数据分组。在阶段460,如果数据业务整形模块确定网卡对与所接收的第一描述符相关联的第一数据分组的传输不会被延迟,数据业务整形模块使得网卡立即传送第一数据分组。在阶段470,数据业务整形模块向网络接口驱动器通知对数据分组的成功传输。注意,如本文中使用的,对数据分组的成功传输不一定要求接收方对数据分组的成功接收。也就是,对分组接收的确认的接收(例如,TCP ACK 消息)不是网络接口卡确定已经成功传送分组的先决条件。FIG4 is a flow chart illustrating an exemplary method 400 for shaping network traffic using a data traffic shaping module, such as the data traffic shaping module 166 shown in FIG1 and FIG6A-6D. In summary, the method 400 begins at stage 410, where the data traffic shaping module maintains a plurality of traffic shaping queues and receives descriptors of data packets from a primary transmit queue, delivered by a network interface driver, such as the network interface driver 164 shown in FIG1 and FIG6A-6D. At stage 420, the data traffic shaping module classifies the data packets associated with the received descriptors. At stage 430, the data traffic shaping module determines whether transmission of a first data packet associated with the received first descriptor by a network interface card, such as the network interface card 168 shown in FIG1 and FIG6A-6D, should be delayed. At stage 440, if the data traffic shaping module determines that the network card's transmission of the first data packet associated with the received first descriptor will be delayed, the data traffic shaping module removes the first descriptor associated with the first data packet from the main transmit queue and, based on the classification result, stores the first descriptor in the corresponding traffic shaping queue. Next, at stage 450, the data traffic shaping module causes the network card to transmit the data packet associated with the descriptor stored in the traffic shaping queue according to the transmission rate rules associated with the corresponding traffic shaping queue. At stage 460, if the data traffic shaping module determines that the network card's transmission of the first data packet associated with the received first descriptor will not be delayed, the data traffic shaping module causes the network card to immediately transmit the first data packet. At stage 470, the data traffic shaping module notifies the network interface driver of the successful transmission of the data packet. Note that, as used herein, successful transmission of a data packet does not necessarily require successful reception of the data packet by the recipient. That is, receipt of an acknowledgment of packet reception (e.g., a TCP ACK message) is not a prerequisite for the network interface card to determine that the packet has been successfully transmitted.

现在,将参照6A-6D来详细描述图4中的流程图,图6A-6D为根据某些实现的表示数据业务整形系统的示例操作的框图。The flowchart of FIG. 4 will now be described in detail with reference to FIGs. 6A-6D, which are block diagrams representing example operations of a data traffic shaping system according to certain implementations.

如以上给出的,在阶段410,数据业务整形模块维持多个业务整形队列并且接收来自主传输队列的由网络接口驱动器所传递的数据分组的描述符。例如,参见图6A-6D,数据业务整形模块166维持多个业务整形队列(例如,业务整形队列162、163以及165)。在某些实施方式中,每个业务整形队列能够维持对应的分组缓冲器(未示出),以用于存储由业务整形队列管理的分组。在某些实施方式中,业务整形队列中的至少某些共享对分组缓冲器169的访问并且因而不需要拥有他们自身的单独的分组缓冲器。参见图6A和6B,响应于网络接口驱动器164将与所接收的数据分组相关联的描述符传递到数据业务整形模块166(例如,T1、U1、T2、S1、U2、S2、S3、以及T3),数据业务整形模块166从主传输队列161接收所传递的数据分组描述符。As described above, at stage 410, the data traffic shaping module maintains multiple traffic shaping queues and receives descriptors of data packets delivered by the network interface driver from the main transmit queue. For example, referring to Figures 6A-6D, the data traffic shaping module 166 maintains multiple traffic shaping queues (e.g., traffic shaping queues 162, 163, and 165). In some embodiments, each traffic shaping queue can maintain a corresponding packet buffer (not shown) for storing packets managed by the traffic shaping queue. In some embodiments, at least some of the traffic shaping queues share access to the packet buffer 169 and thus do not need to have their own separate packet buffers. Referring to Figures 6A and 6B, in response to the network interface driver 164 delivering descriptors associated with received data packets to the data traffic shaping module 166 (e.g., T1, U1, T2, S1, U2, S2, S3, and T3), the data traffic shaping module 166 receives the delivered data packet descriptors from the main transmit queue 161.

在阶段420,数据业务整形模块对与所接收的描述符相关联的数据分组进行分类。在某些实施方式中,例如在图6B中所示,数据业务整形模块166基于用于将每个流的特性映射到对应的业务整形队列的分类规则集合来对与所接收的描述符相关联的数据分组进行分类。例如,业务整形模块能够基于分组报头中的数据的四元组或五元组来对分组进行分类,包括源和目标IP地址、源和目标端口号、以及服务指示符类型中的四个或五个。在某些实施方式中,能够更广泛地使用报头更少的数据字段来对分组进行分类。例如,在某些实施方式中,可以基于单个数据字段来对分组进行分类,诸如服务类型(ToS)或服务质量(QoS)字段(取决于使用的协议和协议版本)、文件类型字段、或端口号,这些字段中的每一个通常能够与优先级相关。在识别分组的相关特性之后,数据业务整形模块166将所识别的特性与分类规则进行比较并且将分组指派给满足分类规则的业务整形队列。在某些实施方式中,数据 业务整形模块166维持“兜底”业务整形队列,以用于处理基于他们的特定特性未指派给其他业务整形队列的所有分组。At stage 420, the data traffic shaping module classifies the data packets associated with the received descriptors. In some embodiments, such as shown in FIG. 6B , the data traffic shaping module 166 classifies the data packets associated with the received descriptors based on a set of classification rules that map the characteristics of each flow to a corresponding traffic shaping queue. For example, the traffic shaping module can classify packets based on a four- or five-tuple of data in the packet header, including four or five of the source and destination IP addresses, source and destination port numbers, and the type of service indicator. In some embodiments, fewer data fields in the header can be used more extensively to classify packets. For example, in some embodiments, packets can be classified based on a single data field, such as a Type of Service (ToS) or Quality of Service (QoS) field (depending on the protocol and protocol version used), a file type field, or a port number, each of which can generally be associated with a priority level. After identifying the relevant characteristics of the packet, the data traffic shaping module 166 compares the identified characteristics with the classification rules and assigns the packet to the traffic shaping queue that meets the classification rules. In some embodiments, the data traffic shaping module 166 maintains a "catch-all" traffic shaping queue for processing all packets that are not assigned to other traffic shaping queues based on their specific characteristics.

在某些实施方式中,每个业务整形队列具有至少一个相关联的传输速率规则。用于特定业务队列的传输速率规则能够指定网卡传送存储在特定业务队列中的分组的流速率限制。参见图6A-6D,数据业务整形模块166能够使得网卡168根据队列的传输速率规则来传送存储在特定业务整形队列中的分组。在某些实施方式中,传输速率规则能够为绝对的或有条件的。类似地,传输速率规则能够基于分组的数目或数据量。某些示例绝对传输速率规则包括1)无限制的传输;2)每秒传送的最大分组数目;3)每秒传送的平均分组数目;4)每秒传送的最大比特;或5)每秒传送的平均比特。在某些实施方式中,传输速率规则能够包括以上类型的规则中的任意组合。例如,传输速率规则可以指定每秒的平均可允许比特或分组、以及每秒的最大比特或分组数目,以允许和/或容纳业务的突发性。有条件的传输速率规则允许不同情形下的不同的绝对传输速率规则。例如,一个有条件的传输速率规则可以许可在与不同的业务整形队列为空相对的该不同的业务整形队列为满的情形下的一个传输速率。另一有条件的传输规则可以许可取决于队列中的分组的数目的不同的传输速率,例如,以允许在该队列变得非所期望地满的情形下更快地处理分组。以上规则为可以针对相应的业务整形队列中的每个业务整形队列而实现的广泛的规则的示例。具体规则能够例如由系统管理员来设置。In some embodiments, each traffic shaping queue has at least one associated transmission rate rule. The transmission rate rule for a particular traffic queue can specify a flow rate limit for the network interface card (NIC) to transmit packets stored in the particular traffic shaping queue. Referring to Figures 6A-6D, the data traffic shaping module 166 can cause the NIC 168 to transmit packets stored in the particular traffic shaping queue according to the queue's transmission rate rule. In some embodiments, transmission rate rules can be absolute or conditional. Similarly, transmission rate rules can be based on the number of packets or the amount of data. Some example absolute transmission rate rules include 1) unrestricted transmission; 2) a maximum number of packets transmitted per second; 3) an average number of packets transmitted per second; 4) a maximum number of bits transmitted per second; or 5) an average number of bits transmitted per second. In some embodiments, transmission rate rules can include any combination of the above types of rules. For example, a transmission rate rule can specify an average allowable number of bits or packets per second and a maximum number of bits or packets per second to allow for and/or accommodate bursty traffic. Conditional transmission rate rules allow for different absolute transmission rate rules in different situations. For example, a conditional transmission rate rule might grant a transmission rate when a different traffic shaping queue is full, as opposed to when the different traffic shaping queue is empty. Another conditional transmission rule might grant a different transmission rate depending on the number of packets in the queue, for example, to allow for faster processing of packets if the queue becomes undesirably full. The above rules are examples of broad rules that can be implemented for each of the corresponding traffic shaping queues. Specific rules can be set, for example, by a system administrator.

在阶段430,数据业务整形模块能够确定网卡对与所接收的第一描述符相关联的第一数据分组的传输是否将被延迟。如果分组的分类导致其被指派给已经存储未发送分组(或其描述符)的业务整形队列,则延迟分组的传输。At stage 430, the data traffic shaping module can determine whether transmission of the first data packet associated with the received first descriptor by the network card is to be delayed. If the classification of the packet results in its being assigned to a traffic shaping queue that already stores unsent packets (or their descriptors), transmission of the packet is delayed.

在阶段440,如果数据业务整形模块确定网卡对与所接收的第一描述符相关联的第一数据分组的传输将被延迟,数据业务整形模块从主传输队列中移除与第一数据分组相关联的第一描述符并且基于分类的结果在对应的业务整形队列中存储第一描述符。例如,参见图6A和 6B,响应于确定网卡168对与第二流的描述符T1相关联的数据分组的传输将被延迟,数据业务整形模块166从主传输队列161中移除描述符T1并且将描述符T1存储在业务整形队列165中。类似地,数据业务整形模块166从主传输队列161中移除第二流的描述符T2和T3并且将描述符T2和T3存储在业务整形队列165中。响应于确定网卡168 对与第一流的描述符S1相关联的数据分组的传输将被延迟,数据业务整形模块166从主传输队列161中移除描述符S1并且将描述符S1存储在业务整形队列163中。类似地,数据业务整形模块166从主传输队列161中移除第一流的描述符S2和S3并且将描述符S2和S3存储在业务整形队列163中。At stage 440, if the data traffic shaping module determines that the transmission of the first data packet associated with the received first descriptor by the network card will be delayed, the data traffic shaping module removes the first descriptor associated with the first data packet from the main transmit queue and stores the first descriptor in the corresponding traffic shaping queue based on the classification result. For example, referring to Figures 6A and 6B, in response to determining that the transmission of the data packet associated with descriptor T1 of the second flow by network card 168 will be delayed, data traffic shaping module 166 removes descriptor T1 from main transmit queue 161 and stores descriptor T1 in traffic shaping queue 165. Similarly, data traffic shaping module 166 removes descriptors T2 and T3 of the second flow from main transmit queue 161 and stores descriptors T2 and T3 in traffic shaping queue 165. In response to determining that the transmission of the data packet associated with descriptor S1 of the first flow by network card 168 will be delayed, data traffic shaping module 166 removes descriptor S1 from main transmission queue 161 and stores descriptor S1 in traffic shaping queue 163. Similarly, data traffic shaping module 166 removes descriptors S2 and S3 of the first flow from main transmission queue 161 and stores descriptors S2 and S3 in traffic shaping queue 163.

从单个传输队列中移除与被确定为将被延迟的业务流相关联的描述符能够解决称作“队头阻塞”的排队问题。如果先入先出(FIFO)队列的头处的分组的传输被延迟、但是仍然保持在传输队列中,该分组将阻塞与队列中它之后所存储的描述符相关联的所有其他分组的处理 (包括基于业务整形模块所实现的业务整形规则将不被延迟的分组),引起“队头阻塞”问题。相反,对于基于业务整形规则被确定为将被延迟传输的数据分组,数据业务整形模块166能够传递与来自传输队列的头的分组相关联的描述符。这一移除能够允许继续处理在队列中存储的描述符相关联的其他分组,由此解决“队头阻塞”问题。进而,响应于从传输队列中移除描述符,数据业务整形模块166能够将描述符转移到对应的业务整形队列,由此允许延迟的分组传输,而不丢弃描述符或其对应的分组。Removing descriptors associated with traffic flows determined to be delayed from a single transmit queue can resolve a queuing problem known as "head-of-line blocking." If the transmission of a packet at the head of a first-in, first-out (FIFO) queue is delayed but remains in the transmit queue, that packet will block the processing of all other packets associated with descriptors stored after it in the queue (including packets that would not be delayed based on the traffic shaping rules implemented by the traffic shaping module), causing a "head-of-line blocking" problem. Conversely, for data packets determined to be delayed based on traffic shaping rules, the data traffic shaping module 166 can transfer the descriptors associated with the head packet from the transmit queue. This removal can allow processing of other packets associated with the descriptors stored in the queue to continue, thereby resolving the "head-of-line blocking" problem. Furthermore, in response to removing a descriptor from a transmit queue, the data traffic shaping module 166 can transfer the descriptor to the corresponding traffic shaping queue, thereby allowing the delayed packet to be transmitted without discarding the descriptor or its corresponding packet.

再次参见图6B,在某些实施方式中,如果数据业务整形模块166 确定网卡168对第一流中的数据分组(例如,与描述符S1相对应的数据分组)的传输将被延迟,数据业务整形模块166将与第一流中的数据分组相关联的描述符存储在第一业务整形队列(即,业务整形队列 163)中。如果数据业务整形模块166确定网卡对不同于第一流的第二流中的数据分组(例如,与描述符T1相对应的数据分组)的传输将被延迟,数据业务整形模块166将与第二流中的数据分组相关联的描述符存储在第二业务整形队列(例如,业务整形队列165)中。在某些实施方式中,能够将与不同的流相关联的分组传递到相同的业务整形队列。也就是,数据业务整形模块166能够维持比数据 业务整形模块166所处理的流的数目更少的业务整形队列,并且在众多情况下,比其少得多的业务整形队列。Referring again to FIG. 6B , in some embodiments, if data traffic shaping module 166 determines that NIC 168 will delay transmission of data packets in a first flow (e.g., data packets corresponding to descriptor S1), data traffic shaping module 166 stores the descriptors associated with the data packets in the first flow in a first traffic shaping queue (i.e., traffic shaping queue 163). If data traffic shaping module 166 determines that NIC 168 will delay transmission of data packets in a second flow different from the first flow (e.g., data packets corresponding to descriptor T1), data traffic shaping module 166 stores the descriptors associated with the data packets in the second flow in a second traffic shaping queue (e.g., traffic shaping queue 165). In some embodiments, packets associated with different flows can be delivered to the same traffic shaping queue. That is, data traffic shaping module 166 can maintain fewer traffic shaping queues than the number of flows processed by data traffic shaping module 166, and in many cases, significantly fewer traffic shaping queues.

在阶段450,数据业务整形模块使得网卡根据与相应的业务整形队列相关联的传输速率规则来传送与存储在业务整形队列中的描述符相关联的数据分组。例如,参见图6B-6D,数据业务整形模块166使得网卡168根据与业务整形队列163相关联的传输速率规则来以延迟方式传送与存储在业务整形队列163中的描述符S1、S2以及S3相关联的数据分组。数据业务整形模块166还能够使得网卡168根据与业务整形队列165相关联的传输速率规则来以延迟方式传送与存储在业务整形队列165中的描述符T1、T2以及T3相关联的数据分组。At stage 450, the data traffic shaping module causes the network interface card (NIC) to transmit data packets associated with the descriptors stored in the traffic shaping queues according to the transmission rate rules associated with the corresponding traffic shaping queues. For example, referring to Figures 6B-6D, data traffic shaping module 166 causes NIC 168 to transmit data packets associated with descriptors S1, S2, and S3 stored in traffic shaping queue 163 in a delayed manner according to the transmission rate rules associated with traffic shaping queue 163. Data traffic shaping module 166 can also cause NIC 168 to transmit data packets associated with descriptors T1, T2, and T3 stored in traffic shaping queue 165 in a delayed manner according to the transmission rate rules associated with traffic shaping queue 165.

在阶段460,如果数据业务整形模块确定网卡对与所接收的第一描述符相关联的第一数据分组的传输不会被延迟,数据业务整形模块能够使得网卡立即传送与存储在业务整形队列中的描述符相关联的数据分组。例如,如果对数据分组进行分类使得将其指派给具有允许无限制的传输速率的传输速率规则的业务整形队列并且队列为空,可以无延迟地立即传送数据分组。按照图6A-6D中所示的示例中地处理与描述符U1和U2相关联的分组。类似地,如果将分组分类到为空并且没有超过在其对应的传输速率规则中所识别的传输速率的业务整形队列,可以立即传送分组。At stage 460, if the data traffic shaping module determines that the transmission of the first data packet associated with the received first descriptor by the network card will not be delayed, the data traffic shaping module can cause the network card to immediately transmit the data packet associated with the descriptor stored in the traffic shaping queue. For example, if the data packet is classified so that it is assigned to a traffic shaping queue with a transmission rate rule that allows an unlimited transmission rate and the queue is empty, the data packet can be transmitted immediately without delay. The packets associated with descriptors U1 and U2 are processed as in the example shown in Figures 6A-6D. Similarly, if the packet is classified into a traffic shaping queue that is empty and does not exceed the transmission rate identified in its corresponding transmission rate rule, the packet can be transmitted immediately.

在某些实施方式中,网卡168通过使用资源来传送数据分组。在某些实施方式中,资源为应用150、网络接口驱动器164以及网卡168 中的某些或全部所共享的存储器缓冲器(例如,图1和6A-6D中的分组缓冲器169)。例如,网卡168使用与数据分组相关联的描述符来识别(共享存储器中的)分组缓冲器169中的数据分组的地址,并且接着从分组缓冲器169传送数据分组。在某些实施方式中,响应于使用分组缓冲器169来传送数据分组,网卡168能够使得分组缓冲器释放用于存储所传送的分组的存储器空间,使得该空间能够用于存储新的分组。In some embodiments, the network card 168 transmits the data packet by using a resource. In some embodiments, the resource is a memory buffer (e.g., packet buffer 169 in Figures 1 and 6A-6D) shared by some or all of the application 150, the network interface driver 164, and the network card 168. For example, the network card 168 uses a descriptor associated with the data packet to identify the address of the data packet in the packet buffer 169 (in the shared memory) and then transmits the data packet from the packet buffer 169. In some embodiments, in response to transmitting the data packet using the packet buffer 169, the network card 168 can cause the packet buffer to release memory space used to store the transmitted packet so that the space can be used to store a new packet.

在阶段470,数据业务整形模块能够向网络接口驱动器通知对数据分组的成功传输。例如,参见图6C,响应于经由网卡168成功完成与描述符U1和U2相关联的数据分组的(立即)传输,数据业务整形模块166向网络接口驱动器164通知对数据分组的成功传输。在某些实施方式中,数据业务整形模块166能够通过向网络接口驱动器164 转发网卡168所生成的单个消息来向网络接口驱动器164通知对数据分组的成功传输,其中,所述单个消息指示对与描述符U1和U2相关联的数据分组的成功传输。在某些实施方式中,通过针对每个分组来将单独的传输完成消息转发到网络接口驱动器164,数据业务整形模块 166能够单独地向网络接口驱动器164通知与描述符U1和U2相关联的数据分组中的每个数据分组的成功传输。At stage 470, the data traffic shaping module can notify the network interface driver of the successful transmission of the data packets. For example, referring to FIG6C , in response to the successful completion of the (immediate) transmission of the data packets associated with descriptors U1 and U2 via network interface card 168, data traffic shaping module 166 notifies network interface driver 164 of the successful transmission of the data packets. In some embodiments, data traffic shaping module 166 can notify network interface driver 164 of the successful transmission of the data packets by forwarding a single message generated by network interface card 168 to network interface driver 164, wherein the single message indicates the successful transmission of the data packets associated with descriptors U1 and U2. In some embodiments, data traffic shaping module 166 can individually notify network interface driver 164 of the successful transmission of each of the data packets associated with descriptors U1 and U2 by forwarding a separate transmission completion message to network interface driver 164 for each packet.

针对延迟的传输,能够生成并且转发类似的通信。例如,参见图 6D,响应于经由网卡168成功完成与描述符T1、S1、T2、S2、T3以及S3相关联的数据分组的(延迟)传输,数据业务整形模块166向网络接口驱动器164通知对数据分组的成功传输。在某些实施方式中,通过向网络接口驱动器164转发网卡168所生成的单个消息,数据业务整形模块166能够向网络接口驱动器164通知对数据分组的成功传输,其中,所述单个消息指示对多个数据分组成功传输。在某些实施方式中,数据业务整形模块166能够单独地向网络接口驱动器164通知每个单独的数据分组的成功传输。Similar communications can be generated and forwarded for delayed transmissions. For example, referring to FIG6D , in response to the successful completion of the (delayed) transmission of the data packets associated with descriptors T1, S1, T2, S2, T3, and S3 via network interface card 168, data traffic shaping module 166 notifies network interface driver 164 of the successful transmission of the data packets. In some embodiments, data traffic shaping module 166 can notify network interface driver 164 of the successful transmission of the data packets by forwarding a single message generated by network interface card 168 to network interface driver 164, wherein the single message indicates the successful transmission of multiple data packets. In some embodiments, data traffic shaping module 166 can separately notify network interface driver 164 of the successful transmission of each individual data packet.

图5为使用网络接口驱动器执行的示例方法500来对网络业务进行整形的流程图。按照概述,所述方法500开始于阶段510,其中网络接口驱动器(诸如图1和6A-6D中所示的网络接口驱动器164)确定诸如网卡168的网卡是否成功传送所接收的第一分组集合中的分组。在阶段520,如果网络接口驱动器确定成功传送所接收的分组的第一集合中的分组,在将附加数据分组转发到网络接口驱动器之前,网络接口驱动器将分组传输完成消息传送到等待接收来自网络接口驱动器的分组传输完成消息的应用。FIG5 is a flow chart of an example method 500 performed by a network interface driver to shape network traffic. In summary, the method 500 begins at stage 510, where a network interface driver (such as the network interface driver 164 shown in FIG1 and FIG6A-6D) determines whether a network interface card (such as the network interface card 168) successfully transmits a packet from a first set of received packets. At stage 520, if the network interface driver determines that a packet from the first set of received packets was successfully transmitted, the network interface driver transmits a packet transmission complete message to an application waiting to receive the packet transmission complete message from the network interface driver before forwarding additional data packets to the network interface driver.

以下参照图6A-6D详细描述图5的流程图中所示的方法。The method shown in the flowchart of FIG. 5 is described in detail below with reference to FIG. 6A-6D .

详细参见图5,在阶段510,网络接口驱动器确定网卡是否成功传送所接收的第一分组集合中的分组。例如,参见图6C,响应于网卡168 成功完成与描述符U1和U2相关联的数据分组的传输,数据业务整形模块166通过通信单个消息或多个消息向网络接口驱动器164通知对数据分组的成功传输。基于来自数据业务整形模块166的对数据分组的成功传输的通知,网络接口驱动器164确定网卡168成功传送所接收的分组中的每个分组。5 , at stage 510, the network interface driver determines whether the network card 168 successfully transmitted packets from the received first set of packets. For example, referring to FIG6C , in response to network card 168 successfully completing transmission of the data packets associated with descriptors U1 and U2, data traffic shaping module 166 communicates a single message or multiple messages to network interface driver 164 notifying the network interface driver 164 of the successful transmission of the data packets. Based on the notification of the successful transmission of the data packets from data traffic shaping module 166, network interface driver 164 determines that network card 168 successfully transmitted each of the received packets.

在阶段520,响应于网络接口驱动器确定成功传送所接收的第一分组集合中的分组,在转发附加数据分组到网络接口驱动器之前,网络接口驱动器将分组传输完成消息传送到等待接收来自网络接口驱动器的分组传输完成消息的应用。例如,参见图6C,响应于确定网卡168 已经成功传送来源于应用150C所发送的第三流的描述符U1相关联的分组,网络接口驱动器164将与描述符U1相对应的分组传输完成消息 167(例如,图6C中的M-U1)通信到应用150C。类似地,响应于确定网卡168成功传送来源于应用150C发射的描述符U2相关联的分组,网络接口驱动器164将与描述符U2相对应的分组传输完成消息167(例如,图6C中的M-U2)通信到应用150C。在某些实施方式中,传输完成消息167能够较小(例如,32个字节或包括少数64比特的整数)。在某些实施方式中,响应于从数据业务整形模块166接收指示成功传输与描述符U1和U2相关联的数据分组的单个消息(未示出),网络接口驱动器164生成两个单独的传输完成消息(例如,图6C中的M-U1 和M-U2)并且按照成功传输数据分组的顺序来将每个消息通信到对应的分组源,例如,应用150C。在某些实施方式中,响应于从数据业务整形模块166接收指示成功传输与描述符U1和U2相关联的数据分组中的每个数据分组的消息(未示出),网络接口驱动器164能够向对应的分组源(例如,应用150C)转发所接收的消息作为传输完成消息。At stage 520, in response to the network interface driver determining that a packet from the received first set of packets was successfully transmitted, the network interface driver transmits a packet transmission completion message to the application waiting to receive the packet transmission completion message from the network interface driver before forwarding the additional data packet to the network interface driver. For example, referring to FIG6C , in response to determining that network card 168 has successfully transmitted a packet associated with descriptor U1 from the third stream sent by application 150C, network interface driver 164 communicates a packet transmission completion message 167 corresponding to descriptor U1 (e.g., M-U1 in FIG6C ) to application 150C. Similarly, in response to determining that network card 168 has successfully transmitted a packet associated with descriptor U2 from application 150C, network interface driver 164 communicates a packet transmission completion message 167 corresponding to descriptor U2 (e.g., M-U2 in FIG6C ) to application 150C. In some embodiments, transmission completion message 167 can be relatively small (e.g., 32 bytes or a small 64-bit integer). In some embodiments, in response to receiving a single message (not shown) from the data traffic shaping module 166 indicating the successful transmission of data packets associated with descriptors U1 and U2, the network interface driver 164 generates two separate transmission completion messages (e.g., M-U1 and M-U2 in FIG. 6C ) and communicates each message to a corresponding packet source, e.g., application 150C, in the order in which the data packets were successfully transmitted. In some embodiments, in response to receiving a message (not shown) from the data traffic shaping module 166 indicating the successful transmission of each of the data packets associated with descriptors U1 and U2, the network interface driver 164 can forward the received message to the corresponding packet source (e.g., application 150C) as a transmission completion message.

参见图6D,响应于确定网卡168已经成功传送起源于应用150B 所发送的第二流的描述符T1相关联的分组,网络接口驱动器164将与描述符T1相对应的分组传输完成消息167(例如,图6D中的M-T1) 通信到应用150B。类似地,响应于确定网卡168已经成功传送起源于应用150A所发送的第一流的描述符S1相关联的分组,网络接口驱动器164将与描述符S1相对应的分组传输完成消息167(例如,图6D 中的M-S1)通信到应用150B。在某些实施方式中,响应于从数据业务整形模块166接收指示成功传输与描述符T1、S1、T2、S2、T3以及 S3相关联的数据分组的单个消息(未示出),网络接口驱动器164能够生成六个单独的传输完成消息(例如,图6C中的M-T1、M-S1、M-T2、 M-S2、M-T3以及M-S3)并且按照成功传输数据分组的顺序(例如,按照T1、S1、T2、S2、T3以及S3的顺序)来将每个消息通信到对应的分组源(例如,对于第一流的描述符T1、T2、T3,应用150A;以及,对于第二流的描述符S1、S2、S3,应用150B)。或者,随着从数据业务整形模块166接收每个消息,能够仅发送一个消息到每个源(例如,一个消息到应用150A以及一个消息到应用150B),其中每个消息识别多个成功传送的分组。6D , in response to determining that network card 168 has successfully transmitted the packet associated with descriptor T1 of the second stream sent by application 150B, network interface driver 164 communicates a packet transmission completion message 167 (e.g., M-T1 in FIG. 6D ) corresponding to descriptor T1 to application 150B. Similarly, in response to determining that network card 168 has successfully transmitted the packet associated with descriptor S1 of the first stream sent by application 150A, network interface driver 164 communicates a packet transmission completion message 167 (e.g., M-S1 in FIG. 6D ) corresponding to descriptor S1 to application 150B. In some embodiments, in response to receiving a single message (not shown) from the data traffic shaping module 166 indicating the successful transmission of data packets associated with descriptors T1, S1, T2, S2, T3, and S3, the network interface driver 164 can generate six separate transmission completion messages (e.g., M-T1, M-S1, M-T2, M-S2, M-T3, and M-S3 in FIG. 6C ) and communicate each message to the corresponding packet source (e.g., application 150A for descriptors T1, T2, T3 of the first flow and application 150B for descriptors S1, S2, S3 of the second flow) in the order in which the data packets were successfully transmitted (e.g., in the order of T1, S1, T2, S2, T3, and S3). Alternatively, as each message is received from the data traffic shaping module 166, only one message can be sent to each source (e.g., one message to application 150A and one message to application 150B), where each message identifies multiple successfully transmitted packets.

在某些实施方式中,应用150中的每个应用能够被配置为在转发附加数据分组到网络接口驱动器164之前等待接收来自网络接口驱动器164的分组传输完成消息。在某些实施方式中,应用150中的每个应用能够被配置为在转发相同的流中的附加数据分组到网络接口驱动器164之前等待接收来自网络接口驱动器164的针对特定流的数据分组的传输完成消息。例如,如在图6C中所示,应用150C等待接收第三流中与来自网络接口驱动器164的描述符U1相对应的数据分组的传输完成消息。参见图6D,响应于应用150C接收与描述符U1相对应的传输完成消息,应用150C转发相同的第三流的附加数据分组(例如,与如图6D中所示的描述符U3和U4相对应的数据分组)到网络接口驱动器164。按照这一方式,通过仅在应用150C接收到指示网卡168 传送的相同流的分组的分组传输完成消息时发送附加分组到网络接口驱动器164,应用150C能够在主传输队列中维持针对每个流的少量的分组(例如,1或2或3个分组)。在某些实施方式中,响应于接收与特定流的描述符相对应的传输完成消息,应用能够转发与该特定流不同的流的附加数据分组到网络接口驱动器164。In some embodiments, each of the applications 150 can be configured to wait for a packet transfer completion message from the network interface driver 164 before forwarding additional data packets to the network interface driver 164. In some embodiments, each of the applications 150 can be configured to wait for a transfer completion message for data packets for a particular flow from the network interface driver 164 before forwarding additional data packets in the same flow to the network interface driver 164. For example, as shown in FIG6C , the application 150C waits for a transfer completion message for a data packet in the third flow corresponding to descriptor U1 from the network interface driver 164. Referring to FIG6D , in response to the application 150C receiving the transfer completion message corresponding to descriptor U1, the application 150C forwards additional data packets of the same third flow (e.g., data packets corresponding to descriptors U3 and U4 as shown in FIG6D ) to the network interface driver 164. In this manner, application 150C can maintain a small number of packets (e.g., 1, 2, or 3 packets) for each flow in the main transmit queue by sending additional packets to network interface driver 164 only when application 150C receives a packet transfer completion message indicating packets for the same flow transmitted by network card 168. In some embodiments, in response to receiving a transfer completion message corresponding to a descriptor for a particular flow, the application can forward additional data packets for flows other than the particular flow to network interface driver 164.

以下还参照图7A-7D来描述图3-5的流程图中所示的方法,图 7A-7D为根据某些实施方式的表示数据业务整形系统的操作示例的框图。在图7A-7D中,使用与图6A-6D的附图标记相同的附图标记,并且省略相同的描述。图7A-7D示出了当应用150D发送不同的流(stream)或流(flow)的分组(例如,第四流中与描述符V1、V2、V3 相对应的分组,以及第五流中与描述符W1、W2、W3相对应的分组) 到网络接口驱动器164时数据业务整形系统的操作。The methods shown in the flowcharts of Figures 3-5 are further described below with reference to Figures 7A-7D, which are block diagrams illustrating exemplary operations of a data traffic shaping system according to certain embodiments. In Figures 7A-7D, the same reference numerals as in Figures 6A-6D are used, and the same descriptions are omitted. Figures 7A-7D illustrate the operation of the data traffic shaping system when application 150D sends packets of different streams or flows (e.g., packets corresponding to descriptors V1, V2, and V3 in the fourth stream, and packets corresponding to descriptors W1, W2, and W3 in the fifth stream) to network interface driver 164.

在图3中的阶段310,网络接口驱动器能够接收由应用所生成并且转发的第一数据分组集合,以由网卡传输。例如,参见图7A,网络接口驱动器164接收由应用150D所生成并且转发的一个数据分组集合,以用于网卡168的传输。在图7A中所示的示例中,应用150D按照连续顺序来发送第四流中与描述符V1、V2以及V3相对应的三个分组。相同的应用150D按照连续顺序来发送第五流中与描述符W1、W2 以及W3相对应的三个分组。At stage 310 in FIG3 , the network interface driver can receive a first set of data packets generated and forwarded by an application for transmission by a network interface card. For example, referring to FIG7A , the network interface driver 164 receives a set of data packets generated and forwarded by an application 150D for transmission by a network interface card 168. In the example shown in FIG7A , application 150D transmits three packets corresponding to descriptors V1, V2, and V3 in a fourth stream in sequential order. The same application 150D transmits three packets corresponding to descriptors W1, W2, and W3 in a fifth stream in sequential order.

在图3中的阶段320,网络接口驱动器能够将与所接收的第一数据分组集合相关联的描述符存储在主传输队列161中。在某些实施方式中,网络接口驱动器164按照应用150D发送分组的顺序将与来自每个流的数据分组相关联的描述符写入主传输队列161。例如,如在图 7A中所示,网络接口驱动器164接收来自应用150D的六个数据分组并且将与分组相关联的描述符(例如,描述符W1、W2、V1、V2、V3、W3)写入主传输队列161,以用于经由网卡168来传输分组。网络接口驱动器164从应用150D接收第四和第五流的分组,并且按照传送他们的顺序(例如,W1,接着W2,接着V1,接着V2,接着V3,接着W3)将对应的描述符(例如,对于第四流,V1、V2、V3;以及对于第五流,W1、W2、W3)写入主传输队列161。在某些实施方式中,在主传输队列中,不同流的分组能够被交织,同时维持每个流中的分组的接收顺序。例如,在图7A中所示的示例中,在主传输队列中,不同流的分组被交织(即,按照W1、W2、V1、V2、V3、W3的顺序),同时维持每个流中的分组的接收顺序(例如,对于第四流,维持 V1->V2-V3的顺序;以及,对于第五流,维持W1->W2->W3的顺序)。At stage 320 in Figure 3, the network interface driver can store descriptors associated with the received first set of data packets in the main transmit queue 161. In some embodiments, the network interface driver 164 writes the descriptors associated with the data packets from each flow to the main transmit queue 161 in the order in which the packets were sent by application 150D. For example, as shown in Figure 7A, the network interface driver 164 receives six data packets from application 150D and writes the descriptors associated with the packets (e.g., descriptors W1, W2, V1, V2, V3, W3) to the main transmit queue 161 for transmission of the packets via the network card 168. The network interface driver 164 receives packets for the fourth and fifth flows from application 150D and writes the corresponding descriptors (e.g., V1, V2, V3 for the fourth flow; and W1, W2, W3 for the fifth flow) to the main transmit queue 161 in the order in which they were transmitted (e.g., W1, then W2, then V1, then V2, then V3, then W3). In some embodiments, packets from different flows can be interleaved in the primary transmit queue while maintaining the order in which the packets were received within each flow. For example, in the example shown in FIG7A , packets from different flows are interleaved in the primary transmit queue (i.e., in the order W1, W2, V1, V2, V3, W3) while maintaining the order in which the packets were received within each flow (e.g., for the fourth flow, the order V1->V2-V3 is maintained; and for the fifth flow, the order W1->W2->W3 is maintained).

在图3中的阶段330,网络接口驱动器能够将与所接收的第一数据分组集合相关联的描述符(例如,W1、W2、V1、V2、V3、W3)传递到数据业务整形模块166。At stage 330 in FIG. 3 , the network interface driver can pass descriptors (eg, W1 , W2 , V1 , V2 , V3 , W3 ) associated with the received first set of data packets to the data traffic shaping module 166 .

参见图4,在阶段410,数据业务整形模块维持多个业务整形队列并且从主传输队列接收由网络接口驱动器传递的数据分组的描述符。参见图7A和7B,响应于网络接口驱动器164将与所接收的数据分组相关联的描述符传递到数据业务整形模块166(例如,W1、W2、V1、 V2、V3、以及W3),数据业务整形模块166从主传输队列161接收所传递的数据分组的描述符。4 , at stage 410, the data traffic shaping module maintains a plurality of traffic shaping queues and receives descriptors of data packets delivered by the network interface driver from the main transmit queue. Referring to FIG7A and 7B , in response to the network interface driver 164 delivering descriptors associated with received data packets to the data traffic shaping module 166 (e.g., W1, W2, V1, V2, V3, and W3), the data traffic shaping module 166 receives the descriptors of the delivered data packets from the main transmit queue 161.

在图4中的阶段420,数据业务整形模块对与所接收的描述符相关联的数据分组进行分类。在某些实施方式中,例如,如在图7B中所示,数据业务整形模块166基于用于将每个流的特性映射到对应的业务整形队列的分类规则集合来对与所接收的描述符相关联的数据分组进行分类。At stage 420 in Figure 4, the data traffic shaping module classifies the data packets associated with the received descriptors. In some embodiments, for example, as shown in Figure 7B, the data traffic shaping module 166 classifies the data packets associated with the received descriptors based on a set of classification rules for mapping the characteristics of each flow to a corresponding traffic shaping queue.

在图4中的阶段430,数据业务整形模块能够确定网卡对与所接收的第一描述符相关联的第一数据分组的传输是否将被延迟。如果分组的传输导致将其指派给已经存储有未发送分组(或其描述符)的业务整形队列,则延迟分组的传输。At stage 430 in Figure 4, the data traffic shaping module can determine whether transmission of the first data packet associated with the received first descriptor by the network card will be delayed. If transmission of the packet results in its assignment to a traffic shaping queue that already stores unsent packets (or their descriptors), transmission of the packet is delayed.

在图4中的阶段440,如果数据业务整形模块确定网卡对与所接收的第一描述符相关联的第一数据分组的传输将被延迟,数据业务整形模块从主传输队列中移除与第一数据分组相关联的第一描述符,并且基于分类的结果在对应的业务整形队列中存储第一描述符。例如,参见图7A和7C,响应于确定网卡168对与第五流的描述符W1和W2 相关联的数据分组的传输将被延迟,数据业务整形模块166从主传输队列161中移除描述符W1和W2,并且将描述符W1和W2存储在业务整形队列163中。At stage 440 in FIG4 , if the data traffic shaping module determines that the transmission of the first data packet associated with the received first descriptor by the network interface card will be delayed, the data traffic shaping module removes the first descriptor associated with the first data packet from the main transmit queue and, based on the classification result, stores the first descriptor in a corresponding traffic shaping queue. For example, referring to FIG7A and FIG7C , in response to determining that the transmission of the data packets associated with descriptors W1 and W2 of the fifth flow by network interface card 168 will be delayed, data traffic shaping module 166 removes descriptors W1 and W2 from main transmit queue 161 and stores descriptors W1 and W2 in traffic shaping queue 163.

在图4中的阶段450,数据业务整形模块使得网卡根据与相应的业务整形队列相关联的传输速率规则来传送与存储在业务整形队列中的描述符相关联的数据分组。例如,参见图7B-7D,数据业务整形模块166使得网卡168根据与业务整形队列163相关联的传输速率规则来按照延迟方式传送与存储在业务整形队列163中的描述符W1、W2 以及W3相关联的数据分组。At stage 450 in FIG4 , the data traffic shaping module causes the network interface card (NIC) to transmit data packets associated with the descriptors stored in the traffic shaping queues according to the transmission rate rules associated with the corresponding traffic shaping queues. For example, referring to FIG7B-7D , data traffic shaping module 166 causes NIC 168 to transmit data packets associated with descriptors W1, W2, and W3 stored in traffic shaping queue 163 in a delayed manner according to the transmission rate rules associated with traffic shaping queue 163.

在图4中的阶段460,如果数据业务整形模块确定网卡对与所接收的第一描述符相关联的第一数据分组的传输不会被延迟,数据业务整形模块能够使得网卡立即传送与存储在业务整形队列中的描述符相关联的数据分组。例如,如果对数据分组进行分类以使得将其指派给具有允许无限制的传输速率的传输速率规则的业务整形队列并且队列为空,则可以立即在没有延迟的情况下传送数据分组。与描述符V1、 V2和V3相关联的分组如附图7A-7D中所示示例那样处理。At stage 460 in FIG. 4 , if the data traffic shaping module determines that the NIC's transmission of the first data packet associated with the received first descriptor will not be delayed, the data traffic shaping module can cause the NIC to immediately transmit the data packet associated with the descriptor stored in the traffic shaping queue. For example, if the data packet is classified so as to be assigned to a traffic shaping queue with a transmission rate rule that allows an unlimited transmission rate and the queue is empty, the data packet can be immediately transmitted without delay. Packets associated with descriptors V1, V2, and V3 are processed as shown in the examples in FIG. 7A-7D .

在图4中的阶段470,数据业务整形模块能够向网络接口驱动器通知对数据分组的成功传输。例如,参见图7C,响应于经由网卡168 (立即)成功完成与描述符V1、V2以及V3相关联的数据分组的传输,数据业务整形模块166向网络接口驱动器164通知对数据分组的成功传输。在某些实施方式中,如在图7C中所示,通过针对每个分组来转发单独的传输完成消息到网络接口驱动器164,数据业务整形模块166 能够单独地向网络接口驱动器164通知与描述符V1、V2以及V3相关联的数据分组中的每个数据分组的成功传输。At stage 470 in Figure 4 , the data traffic shaping module can notify the network interface driver of the successful transmission of the data packets. For example, referring to Figure 7C , in response to the (immediate) successful completion of the transmission of the data packets associated with descriptors V1, V2, and V3 via the network card 168, the data traffic shaping module 166 notifies the network interface driver 164 of the successful transmission of the data packets. In some embodiments, as shown in Figure 7C , the data traffic shaping module 166 can individually notify the network interface driver 164 of the successful transmission of each of the data packets associated with descriptors V1, V2, and V3 by forwarding a separate transmission completion message to the network interface driver 164 for each packet.

对于延迟的传输,能够生成并且转发类似的通信。例如,参见图 7D,响应于经由网卡168(延迟)成功完成与描述符W1、W2以及 W3相关联的数据分组的传输,数据业务整形模块166向网络接口驱动器164通知对数据分组的成功传输。For delayed transmissions, similar communications can be generated and forwarded. For example, referring to FIG7D , in response to the successful (delayed) completion of the transmission of the data packets associated with descriptors W1, W2, and W3 via network card 168, data traffic shaping module 166 notifies network interface driver 164 of the successful transmission of the data packets.

在图5中的阶段510,网络接口驱动器确定网卡是否成功传送所接收的第一分组集合中的分组。例如,参见图7C,响应于网卡168成功完成与描述符V1、V2以及V3相关联的数据分组的传输,数据业务整形模块166通过通信单个消息或多个消息向网络接口驱动器164通知对数据分组的成功传输。基于来自数据业务整形模块166的对数据分组的成功传输的通知,网络接口驱动器164确定网卡168成功传送所接收的分组中的每个分组。At stage 510 in Figure 5 , the network interface driver determines whether the network card successfully transmitted packets in the first set of received packets. For example, referring to Figure 7C , in response to network card 168 successfully completing the transmission of the data packets associated with descriptors V1, V2, and V3, data traffic shaping module 166 notifies network interface driver 164 of the successful transmission of the data packets by communicating a single message or multiple messages. Based on the notification of the successful transmission of the data packets from data traffic shaping module 166, network interface driver 164 determines that network card 168 successfully transmitted each of the received packets.

在图5中的阶段520,响应于网络接口驱动器确定成功传送所接收的第一分组集合中的分组,在转发附加数据分组到网络接口驱动器之前,网络接口驱动器将分组传输完成消息通信到等待接收来自网络接口驱动器的分组传输完成消息的应用。例如,参见图7C,响应于确定网卡168成功传送来源于应用150D发送的第四流中与描述符V1相关联的分组,网络接口驱动器164将与描述符V1相对应的分组传输完成消息167(例如,图7C中的M-V1)通信到应用150D。类似地,响应于确定网卡168成功传送来源于应用150D发送的第四流中与描述符 V2和V3相关联的分组,网络接口驱动器164将与描述符V2和V3相对应的两个分组传输完成消息167(例如,图7C中的M-V2和M-V3) 通信到应用150D。在某些实施方式中,应用150D能够被配置为在转发附加数据分组到网络接口驱动器164之前等待接收来自网络接口驱动器164的分组传输完成消息。在某些实施方式中,应用150D中的每一个应用能够被配置为在转发相同流中的附加数据分组到网络接口驱动器164之前等待接收来自网络接口驱动器164的针对特定流中的数据分组的传输完成消息。例如,如在图7C中所示,应用150D等待接收来自网络接口驱动器164的第三流中与描述符V1相对应的数据分组的传输完成消息。参见图7D,响应于应用150D接收与描述符V1相对应的传输完成消息,应用150D将相同的第四流中的附加数据分组(例如,如图7D中所示的与描述符V4和V5相对应的数据分组)转发到网络接口驱动器164。按照这一方式,通过仅在其接收指示网卡168传送相同流中的分组的分组传输完成消息时才发送附加分组到网络接口驱动器164,应用150D能够在主传输队列中针对每个流维持少量的分组(例如,1或2或3个分组)。At stage 520 in Figure 5 , in response to the network interface driver determining that a packet in the received first set of packets was successfully transmitted, the network interface driver communicates a packet transmission completion message to the application waiting to receive the packet transmission completion message from the network interface driver before forwarding the additional data packet to the network interface driver. For example, referring to Figure 7C , in response to determining that network card 168 successfully transmitted a packet associated with descriptor V1 in the fourth stream sent by application 150D, network interface driver 164 communicates a packet transmission completion message 167 corresponding to descriptor V1 (e.g., M-V1 in Figure 7C ) to application 150D. Similarly, in response to determining that network card 168 successfully transmitted a packet associated with descriptors V2 and V3 in the fourth stream sent by application 150D, network interface driver 164 communicates two packet transmission completion messages 167 corresponding to descriptors V2 and V3 (e.g., M-V2 and M-V3 in Figure 7C ) to application 150D. In some embodiments, the applications 150D can be configured to wait for a packet transfer completion message from the network interface driver 164 before forwarding additional data packets to the network interface driver 164. In some embodiments, each of the applications 150D can be configured to wait for a transfer completion message for data packets in a particular flow from the network interface driver 164 before forwarding additional data packets in the same flow to the network interface driver 164. For example, as shown in FIG7C , the application 150D waits for a transfer completion message for data packets corresponding to descriptor V1 in the third flow from the network interface driver 164. Referring to FIG7D , in response to the application 150D receiving the transfer completion message corresponding to descriptor V1, the application 150D forwards additional data packets in the same fourth flow (e.g., data packets corresponding to descriptors V4 and V5 as shown in FIG7D ) to the network interface driver 164. In this way, application 150D is able to maintain a small number of packets (e.g., 1 or 2 or 3 packets) for each flow in the main transmit queue by sending additional packets to network interface driver 164 only when it receives a packet transfer completion message instructing network card 168 to transmit packets in the same flow.

参见图7A-7D,通常,网络业务属于多个流(flow)或流(stream) (例如,第四流中与描述符V1、V2、V3相对应的分组,以及第五流中与W1、W2、W3相对应的分组)。每个流(flow)/流(stream)可以属于特定的应用(例如,应用150D)或者去往特定的远程位置。例如,多个流(flow)/流(stream)属于相同的应用(例如,图7A-7D中的应用150D)或者属于不同的应用(例如,图6A-6D中的应用 150A-150C)。在任意给定时间,网络设备可以处理成百或成千或成亿的不同的流(flow)/流(stream),并且有时,可能需要放慢针对特定目标的业务或针对特定应用的业务。参见图7A-7D,在某些实施方式中,通过附加与流(flow)/流(stream)相对应的队列(例如,业务整形队列162和163)并且放慢通过相同的队列发送的所有的业务(例如,放慢通过业务整形队列163发送的与描述符W1、W2、W3相关联的所有的分组),数据业务整形模块166能够在没有队头阻塞的情况下独立地对从相同的应用150D发送的不同的流(flow)/流(stream)进行速率限制或业务整形。使用这一配置,无论应用如何将流放到那些队列上(例如,从对应的不同的应用接收多个流,如在图6A-6D中所示,或者,从相同的应用接收多个流,如在图7A-7D中所示),都能够在不产生队头阻塞或放弃任何分组的情况下选择性地放慢流,并且不需要每个应用知晓从每个应用发送的业务如何能够被分类以及业务整形。7A-7D , typically, network traffic belongs to multiple flows or streams (e.g., the packets corresponding to descriptors V1, V2, and V3 in the fourth stream, and the packets corresponding to W1, W2, and W3 in the fifth stream). Each flow/stream can belong to a specific application (e.g., application 150D) or go to a specific remote location. For example, multiple flows/streams belong to the same application (e.g., application 150D in FIG. 7A-7D ) or to different applications (e.g., applications 150A-150C in FIG. 6A-6D ). At any given time, a network device can process hundreds or thousands or even millions of different flows/streams, and sometimes, it may be necessary to slow down traffic directed to a specific target or traffic directed to a specific application. 7A-7D , in some embodiments, the data traffic shaping module 166 can independently rate limit or traffic shape different flows/streams sent from the same application 150D without head-of-line blocking by attaching queues corresponding to flows/streams (e.g., traffic shaping queues 162 and 163) and slowing down all traffic sent through the same queue (e.g., slowing down all packets associated with descriptors W1, W2, and W3 sent through traffic shaping queue 163). With this configuration, regardless of how the applications place flows on those queues (e.g., receiving multiple flows from corresponding different applications, as shown in FIG6A-6D , or receiving multiple flows from the same application, as shown in FIG7A-7D ), flows can be selectively slowed down without incurring head-of-line blocking or dropping any packets, and without requiring each application to be aware of how traffic sent from each application can be classified and traffic shaped.

以下还参照图8A-8C来描述图3-5中的流程图中所示的方法,图 8A-8C为表示根据某些实施方式的数据业务整形系统的操作示例的框图。在图8A-8C中,使用与图6A-6D相同的附图标记,并且省略相同的描述。图8A-8C示出了当主传输队列161为主传输队列161A-161C 的集合时数据业务整形系统的操作。例如,主传输队列161能够为在多队列NIC中实现的多个队列。在某些实施方式中,主传输队列 161A-161C的集合的数目小于速率限制器或业务整形队列162A-162D 的数目。例如,为了对成千上万的流(flow)或流(stream)进行整形,网络设备110能够具有10~32个硬件队列,同时具有安装在其中的众多更多的业务整形队列以对成千上万的流进行整形。The methods illustrated in the flowcharts of Figures 3-5 are further described below with reference to Figures 8A-8C, which are block diagrams illustrating exemplary operations of a data traffic shaping system according to certain embodiments. In Figures 8A-8C, the same reference numerals as in Figures 6A-6D are used, and the same descriptions are omitted. Figures 8A-8C illustrate the operation of the data traffic shaping system when the primary transmit queue 161 is a collection of primary transmit queues 161A-161C. For example, primary transmit queue 161 can be a plurality of queues implemented in a multi-queue NIC. In certain embodiments, the number of primary transmit queues 161A-161C is less than the number of rate limiters or traffic shaping queues 162A-162D. For example, to shape tens of thousands of flows or streams, the network device 110 can have 10 to 32 hardware queues, while having numerous additional traffic shaping queues installed therein to shape tens of thousands of flows.

在图3中的阶段310,网络接口驱动器能够接收由应用150所生成并且转发的一个数据分组集合,以由网卡传输。例如,参见图8A,网络接口驱动器164接收由应用150A-150C所生成并且转发的一个数据分组集合,以由网卡168传输。在图8A中所示的示例中,应用150A 按照连续的顺序来发送第一流中的与描述符S1、S2以及S3相对应的三个分组。应用150B按照连续的顺序来发送第二流中的与描述符T1、 T2以及T3相对应的三个分组。应用150C发送第三流中的与描述符 U1和U3相对应的两个分组。在某些实施方式中,网络接口驱动器164 按照应用150发送分组的顺序来接收数据分组(例如,T1,接着U1,接着T2,接着S1,接着U2,接着S2,接着S3,接着T3)。At stage 310 in FIG3 , the network interface driver can receive a set of data packets generated and forwarded by application 150 for transmission by the network interface card. For example, referring to FIG8A , network interface driver 164 receives a set of data packets generated and forwarded by applications 150A-150C for transmission by network interface card 168. In the example shown in FIG8A , application 150A sends three packets corresponding to descriptors S1, S2, and S3 in a first stream in a sequential order. Application 150B sends three packets corresponding to descriptors T1, T2, and T3 in a second stream in a sequential order. Application 150C sends two packets corresponding to descriptors U1 and U3 in a third stream. In some embodiments, network interface driver 164 receives the data packets in the order in which application 150 sends the packets (e.g., T1, then U1, then T2, then S1, then U2, then S2, then S3, then T3).

在图3中的阶段320,网络接口驱动器能够将与所接收的第一数据分组集合相关联的描述符存储在主传输队列161A-161C的集合中。在某些实施方式中,网络接口驱动器164为每个所接收的数据分组随机选择主传输队列161A-161C中的一个,并且将对应的描述符写入主传输队列161中的所选择的传输队列中。例如,参见图8A,网络接口驱动器164将描述符T1、S1以及S3(按照T1、S1以及S3的顺序) 写入主传输队列161A,将描述符U1、T2以及U2(按照U1、T2以及 U2的顺序)写入主传输队列161B,以及将描述符T2、S2以及T3(按照S2和T3的顺序)写入主传输队列161C。在某些实施方式中,在每个主传输队列中,不同的流的分组能够被交织,同时维持每个流中的分组的接收顺序。例如,在图8A中所示的示例中,在主传输队列161A 中,不同的流的分组被交织(即,按照T1、S1、S3的顺序),同时维持每个流中的分组的接收顺序(例如,对于第三流,维持S1->S3的顺序)。At stage 320 in FIG3 , the network interface driver can store descriptors associated with the received first set of data packets in a set of primary transmit queues 161A-161C. In some embodiments, the network interface driver 164 randomly selects one of the primary transmit queues 161A-161C for each received data packet and writes the corresponding descriptors to the selected transmit queue in the primary transmit queues 161. For example, referring to FIG8A , the network interface driver 164 writes descriptors T1, S1, and S3 (in the order of T1, S1, and S3) to the primary transmit queue 161A, descriptors U1, T2, and U2 (in the order of U1, T2, and U2) to the primary transmit queue 161B, and descriptors T2, S2, and T3 (in the order of S2 and T3) to the primary transmit queue 161C. In some embodiments, within each primary transmit queue, packets from different flows can be interleaved while maintaining the order in which the packets in each flow were received. For example, in the example shown in Figure 8A, in the main transmission queue 161A, packets of different flows are interleaved (i.e., in the order of T1, S1, S3) while maintaining the reception order of packets in each flow (e.g., for the third flow, the order of S1->S3 is maintained).

在图3中的阶段330,网络接口驱动器164能够将与所接收的第一数据分组集合相关联并且存储在每个主传输队列中的描述符(例如,主传输队列161A中存储的T1、S1、S3)传递到数据业务整形模块166。At stage 330 in Figure 3, the network interface driver 164 is capable of passing the descriptors associated with the received first set of data packets and stored in each main transmit queue (e.g., T1, S1, S3 stored in the main transmit queue 161A) to the data traffic shaping module 166.

参见图4,在阶段410,数据业务整形模块维持多个业务整形队列并且从主传输队列161A-161C中的每个接收由网络接口驱动器所传递的数据分组的描述符。参见图8A和8B,响应于网络接口驱动器164 将与所接收的数据分组相关联的描述符传递到数据业务整形模块166,数据业务整形模块166从主传输队列161A接收数据分组的描述符(例如,描述符T1、S1、S3),从主传输队列161B接收数据分组的描述符(例如,描述符U1、T2、U2),以及从主传输队列161C接收数据分组的描述符(例如,描述符S2、T3)。在某些实施方式中,数据业务整形模块维持多个业务整形队列并且从每个主传输队列接收网络接口驱动器所传递的数据分组的描述符。例如,参见图8A-8C,数据业务整形模块166维持多个业务整形队列(例如,业务整形队列 162A-162D)。4 , at stage 410, the data traffic shaping module maintains a plurality of traffic shaping queues and receives descriptors of data packets delivered by the network interface driver from each of the primary transmit queues 161A-161C. Referring to FIGS. 8A and 8B , in response to the network interface driver 164 delivering descriptors associated with received data packets to the data traffic shaping module 166, the data traffic shaping module 166 receives descriptors of data packets (e.g., descriptors T1, S1, S3) from the primary transmit queue 161A, descriptors of data packets (e.g., descriptors U1, T2, U2) from the primary transmit queue 161B, and descriptors of data packets (e.g., descriptors S2, T3) from the primary transmit queue 161C. In some embodiments, the data traffic shaping module maintains a plurality of traffic shaping queues and receives descriptors of data packets delivered by the network interface driver from each of the primary transmit queues. For example, referring to Figures 8A-8C, the data traffic shaping module 166 maintains a plurality of traffic shaping queues (eg, traffic shaping queues 162A-162D).

在图4中的阶段420,数据业务整形模块166对与来自每个主传输队列的所接收的描述符相关联的数据分组进行分类。在阶段430,数据业务整形模块166能够确定网卡对与所接收的第一描述符相关联的第一数据分组的传输是否将被延迟。如果其分类导致其被指派给已经存储有未发送的分组(或其描述符),分组的传输被延迟。At stage 420 in Figure 4, data traffic shaping module 166 classifies the data packets associated with the received descriptors from each primary transmit queue. At stage 430, data traffic shaping module 166 can determine whether the transmission of the first data packet associated with the received first descriptor by the network card should be delayed. If its classification results in it being assigned to a packet (or its descriptor) that already has an unsent packet stored, the transmission of the packet is delayed.

在图4中的阶段440,如果数据业务整形模块确定网卡对与所接收的第一描述符相关联的第一数据分组的传输将被延迟,数据业务整形模块从每个主传输队列中移除与第一数据分组相关联的第一描述符,并且基于分类的结果将第一描述符存储在对应的业务整形队列中。例如,参见图8A和8B,对于主传输队列161A,数据业务整形模块确定网卡168对与存储在主传输队列161A中的描述符T1、S1、S3相关联的数据分组的传输将被延迟。响应于确定网卡168对与第二流的描述符T1相关联的数据分组的传输将被延迟,数据业务整形模块166从主传输队列161A中移除描述符T1,并且将描述符T1存储在业务整形队列162C中。类似地,数据业务整形模块166从主传输队列161A中移除第一流的描述符S1并且将描述符S1存储在业务整形队列162B 中。数据业务整形模块166还从主传输队列161A中移除描述符S3并且将描述符S3存储在业务整形队列162B中。按照类似的方式,如在图8A和8B中所示,对于主传输队列161B,数据业务整形模块166从主传输队列161B中移除第三流的描述符U1并且将描述符U1存储在业务整形队列162A中,从主传输队列161B中移除第二流的描述符T2 并且将描述符T2存储在业务整形队列162C中,以及从主传输队列 161B中移除第三流的描述符U2并且将描述符U2存储在业务整形队列 162A中。按照类似的方式,如在图8A和8B中所示,对于主传输队列 161C,数据业务整形模块166从主传输队列161C中移除第一流的描述符S2并且将描述符S2存储在业务整形队列162B中,以及从主传输队列161C中移除第二流的描述符T3并且将描述符T3存储在业务整形队列162C中。At stage 440 in FIG. 4 , if the data traffic shaping module determines that the NIC's transmission of the first data packet associated with the received first descriptor will be delayed, the data traffic shaping module removes the first descriptor associated with the first data packet from each primary transmit queue and, based on the classification result, stores the first descriptor in the corresponding traffic shaping queue. For example, referring to FIG. 8A and 8B , for primary transmit queue 161A, the data traffic shaping module determines that NIC 168's transmission of the data packets associated with descriptors T1, S1, and S3 stored in primary transmit queue 161A will be delayed. In response to determining that NIC 168's transmission of the data packet associated with descriptor T1 of the second flow will be delayed, data traffic shaping module 166 removes descriptor T1 from primary transmit queue 161A and stores it in traffic shaping queue 162C. Similarly, data traffic shaping module 166 removes descriptor S1 of the first flow from primary transmit queue 161A and stores it in traffic shaping queue 162B. Data traffic shaping module 166 also removes descriptor S3 from main transmission queue 161A and stores it in traffic shaping queue 162B. Similarly, as shown in Figures 8A and 8B , for main transmission queue 161B, data traffic shaping module 166 removes descriptor U1 of the third stream from main transmission queue 161B and stores it in traffic shaping queue 162A, removes descriptor T2 of the second stream from main transmission queue 161B and stores it in traffic shaping queue 162C, and removes descriptor U2 of the third stream from main transmission queue 161B and stores it in traffic shaping queue 162A. In a similar manner, as shown in Figures 8A and 8B, for the main transmission queue 161C, the data traffic shaping module 166 removes the descriptor S2 of the first stream from the main transmission queue 161C and stores the descriptor S2 in the traffic shaping queue 162B, and removes the descriptor T3 of the second stream from the main transmission queue 161C and stores the descriptor T3 in the traffic shaping queue 162C.

在图4中的阶段450,数据业务整形模块使得网卡根据与相应的业务整形队列相关联的传输速率规则来传送与存储在业务整形队列中的描述符相关联的数据分组。例如,参见图8B-8C,数据业务整形模块 166使得网卡168根据与业务整形队列162B相关联的传输速率规则来按照延迟方式传送与存储在业务整形队列162B中的描述符S1、S2以及S3相关联的数据分组。数据业务整形模块166还能够使得网卡168 根据与业务整形队列162C相关联的传输速率规则来按照延迟方式传送与存储在业务整形队列162C中的描述符T1、T2以及T3相关联的数据分组。At stage 450 in FIG4 , the data traffic shaping module causes the network interface card (NIC) to transmit data packets associated with the descriptors stored in the traffic shaping queues according to the transmission rate rules associated with the corresponding traffic shaping queues. For example, referring to FIG8B-8C , data traffic shaping module 166 causes NIC 168 to transmit data packets associated with descriptors S1, S2, and S3 stored in traffic shaping queue 162B in a delayed manner according to the transmission rate rules associated with traffic shaping queue 162B. Data traffic shaping module 166 can also cause NIC 168 to transmit data packets associated with descriptors T1, T2, and T3 stored in traffic shaping queue 162C in a delayed manner according to the transmission rate rules associated with traffic shaping queue 162C.

在图4中的阶段460,如果数据业务整形模块确定网卡对与所接收的第一描述符相关联的第一数据分组的传输不会被延迟,数据业务整形模块能够使得网卡立即传送与存储在业务整形队列中的描述符相关联的数据分组。例如,如果对数据分组进行分类以使得将其指派给具有允许无限制的传输速率的传输速率规则的业务整形队列并且队列为空,则可以在没有延迟的情况下立即传送数据分组。按照图8A-8C 中所示的示例来处理与描述符U1和U2相关联的分组。At stage 460 in FIG4 , if the data traffic shaping module determines that the NIC's transmission of the first data packet associated with the received first descriptor will not be delayed, the data traffic shaping module can cause the NIC to immediately transmit the data packet associated with the descriptor stored in the traffic shaping queue. For example, if the data packet is classified so as to be assigned to a traffic shaping queue with a transmission rate rule that allows an unlimited transmission rate and the queue is empty, the data packet can be immediately transmitted without delay. Packets associated with descriptors U1 and U2 are processed according to the example shown in FIG8A-8C .

在图4中的阶段470,数据业务整形模块能够向网络接口驱动器通知对数据分组的成功传输。例如,参见图8B和8C,响应于经由网卡168(立即)成功完成与描述符U1和U2相关联的数据分组的传输,数据业务整形模块166向网络接口驱动器164通知对数据分组的成功传输。例如,参见图8B和8C,响应于经由网卡168来(延迟)成功完成与描述符T1、S1、T2、T3以及S3相关联的数据分组的传输,数据业务整形模块166向网络接口驱动器164通知对数据分组的成功传输。At stage 470 in Figure 4 , the data traffic shaping module can notify the network interface driver of the successful transmission of the data packets. For example, referring to Figures 8B and 8C , in response to the (immediate) successful completion of the transmission of the data packets associated with descriptors U1 and U2 via the network interface card 168, the data traffic shaping module 166 notifies the network interface driver 164 of the successful transmission of the data packets. For example, referring to Figures 8B and 8C , in response to the (delayed) successful completion of the transmission of the data packets associated with descriptors T1, S1, T2, T3, and S3 via the network interface card 168, the data traffic shaping module 166 notifies the network interface driver 164 of the successful transmission of the data packets.

参见图5,在阶段510,网络接口驱动器确定网卡是否成功传送所接收的第一分组集合中的分组。5 , at stage 510 , the network interface driver determines whether the network card successfully transmits the packets in the received first set of packets.

在阶段520,响应于网络接口驱动器确定成功传送所接收的第一分组集合中的分组,在转发附加数据分组到网络接口驱动器之前,网络接口驱动器将分组传输完成消息通信到等待接收来自网络接口驱动器的分组传输完成消息的应用。例如,参见图8C,响应于确定网卡168 成功传送来源于应用150C发送的第三流中与描述符U1相关联的分组,网络接口驱动器164将与描述符U1相对应的分组传输完成消息167(例如,图8C中的M-U1)通信到应用150C。类似地,响应于确定网卡 168成功传送来源于应用150C发送的第三流中与描述符U2相关联的分组,网络接口驱动器164将与描述符U2相对应的分组传输完成消息 167(例如,图8C中的M-U2)通信到应用150C。类似地,在某些实施方式中,响应于从数据业务整形模块166接收指示成功传输与描述符T1、S1、T2、S2、T3以及S3相关联的数据分组的消息(未示出),网络接口驱动器164能够生成六个单独的传输完成消息(例如,图8C 中的M-T1、M-S1、M-T2、M-S2、M-T3以及M-S3),并且按照成功传输数据分组的顺序(例如,按照T1、S1、T2、S2、T3以及S3的顺序)来将每个消息通信到对应的分组源。At stage 520, in response to the network interface driver determining that a packet in the received first set of packets was successfully transmitted, the network interface driver communicates a packet transmission completion message to an application waiting to receive a packet transmission completion message from the network interface driver before forwarding the additional data packet to the network interface driver. For example, referring to FIG8C , in response to determining that network card 168 successfully transmitted a packet associated with descriptor U1 in the third stream sent by application 150C, network interface driver 164 communicates a packet transmission completion message 167 corresponding to descriptor U1 (e.g., M-U1 in FIG8C ) to application 150C. Similarly, in response to determining that network card 168 successfully transmitted a packet associated with descriptor U2 in the third stream sent by application 150C, network interface driver 164 communicates a packet transmission completion message 167 corresponding to descriptor U2 (e.g., M-U2 in FIG8C ) to application 150C. Similarly, in some embodiments, in response to receiving a message (not shown) from the data traffic shaping module 166 indicating successful transmission of data packets associated with descriptors T1, S1, T2, S2, T3, and S3, the network interface driver 164 is capable of generating six separate transmission completion messages (e.g., M-T1, M-S1, M-T2, M-S2, M-T3, and M-S3 in FIG. 8C ) and communicating each message to the corresponding packet source in the order in which the data packets were successfully transmitted (e.g., in the order of T1, S1, T2, S2, T3, and S3).

参见图8C,在某些实施方式中,应用150中的每个应用能够被配置为在将附加数据分组转发到网络接口驱动器164之前等待接收来自网络接口驱动器164的分组传输完成消息。在某些实施方式中,应用 150中的每个应用能够被配置为在将相同的流中的附加数据分组转发到网络接口驱动器164之前等待接收来自网络接口驱动器164的针对特定流中的数据分组的传输完成消息。8C , in some embodiments, each of the applications 150 can be configured to wait to receive a packet transfer completion message from the network interface driver 164 before forwarding additional data packets to the network interface driver 164. In some embodiments, each of the applications 150 can be configured to wait to receive a transfer completion message for data packets in a particular flow from the network interface driver 164 before forwarding additional data packets in the same flow to the network interface driver 164.

参见图8A-8C,在某些实施方式中,应用150或网络接口驱动器 164可以按照配置他们的任意方式在主传输队列161A-161C的集合上散布流(flow)/流(stream)以及他们对应的分组(例如,在队列上随机散布,或者,在队列上循环散布)。在某些实施方式中,应用150 或网络接口驱动器164可以按照相同的方式在该主传输队列的集合上散布流(flow)/流(stream)以及他们的对应的分组,而不论主传输队列的数目。在某些实施方式中,应用150或网络接口驱动器164被配置成不知晓数据业务整形模块166、业务整形队列162A-162D、以及在那些队列中如何对业务进行分类的实施方式细节。例如,来自在虚拟机中执行的应用的业务能够被整形或限制速率,而没有队头阻塞并且不用向虚拟机的管理员通知业务整形队列以及每个队列上的分类规则的细节。利用图8A-8C中图示的配置,分组能够尽快离开主传输队列并且在分组离开主传输队列之后能够被分类在业务整形队列中,而不返回完成消息。在某些实施方式中,如在图8A-8C中所示,不返回完成消息,直到分组离开业务整形队列,使得完成消息被无序返回,即,按照与将分组保存在主传输队列中的顺序不同的顺序,并且不在FIFO 中,由此允许发送更快的流的应用发送比发送更慢的流的另一应用更多的附加分组。参见图8A-8C,其中数据业务整形模块166在具有多个主传输队列161A-161C的系统中实现,网络接口驱动器164能够返回“无序”的完成消息(例如,完成消息M-U1、M-U2、M-T2的顺序不同于将对应的分组保存在主传输队列161B中的顺序,即,U1、T2、 U2;参见图8A和8C),指示每个分组是基于预定的队列指派规则而放在正确的队列中,还是分组业务“随机”散布在队列上。8A-8C , in some embodiments, the application 150 or network interface driver 164 can distribute flows/streams and their corresponding packets across the set of primary transmit queues 161A-161C in any manner configured (e.g., randomly across the queues, or in a round-robin fashion). In some embodiments, the application 150 or network interface driver 164 can distribute flows/streams and their corresponding packets across the set of primary transmit queues in the same manner, regardless of the number of primary transmit queues. In some embodiments, the application 150 or network interface driver 164 is configured to be unaware of the implementation details of the data traffic shaping module 166, the traffic shaping queues 162A-162D, and how traffic is classified within those queues. For example, traffic from an application executing in a virtual machine can be shaped or rate-limited without head-of-line blocking and without informing the virtual machine administrator of the details of the traffic shaping queues and the classification rules for each queue. Utilizing the configuration illustrated in Figures 8A-8C, packets can leave the primary transmit queue as quickly as possible and can be sorted into the traffic shaping queue after leaving the primary transmit queue without returning a completion message. In some embodiments, as shown in Figures 8A-8C, completion messages are not returned until the packet leaves the traffic shaping queue, such that completion messages are returned out of order, i.e., in an order different from the order in which the packets were stored in the primary transmit queue and not in the FIFO, thereby allowing an application sending a faster stream to send more additional packets than another application sending a slower stream. 8A-8C , where the data traffic shaping module 166 is implemented in a system having multiple main transmission queues 161A-161C, the network interface driver 164 is capable of returning “unordered” completion messages (e.g., the order of the completion messages M-U1, M-U2, M-T2 is different from the order in which the corresponding packets are stored in the main transmission queue 161B, i.e., U1, T2, U2; see FIGURES 8A and 8C ), indicating whether each packet is placed in the correct queue based on predetermined queue assignment rules, or whether the packet traffic is “randomly” spread across the queues.

图9为示例计算系统140的框图。按照说明性的实施方式,示例计算系统140适于实现本文中所描述的计算机化的组件中使用。按照概述,计算系统140包括用于根据指令来执行动作的至少一个处理器 148,以及用于存储指令和数据的一个或多个存储器设备144或149。图示的示例计算系统140包括经由总线142来与存储器144通信的一个或多个处理器148,具有用于连接到网络(未示出)的网络接口端口 146的至少一个网络接口控制器143,以及其他组件145(例如,输入/ 输出(“I/O”)组件147)。通常,处理器148将执行从存储器所接收的指令。所图示的处理器148并入或直接连接到高速缓存存储器149。在某些实例中,从存储器144读取指令到高速缓存存储器149中并且由处理器148通过高速缓存存储器149执行。FIG9 is a block diagram of an example computing system 140. According to an illustrative embodiment, the example computing system 140 is suitable for use in implementing the computerized components described herein. In general terms, the computing system 140 includes at least one processor 148 for performing actions according to instructions, and one or more memory devices 144 or 149 for storing instructions and data. The illustrated example computing system 140 includes one or more processors 148 communicating with memory 144 via a bus 142, at least one network interface controller 143 having a network interface port 146 for connecting to a network (not shown), and other components 145 (e.g., input/output ("I/O") components 147). Typically, the processor 148 executes instructions received from memory. The illustrated processor 148 incorporates or is directly connected to a cache memory 149. In some instances, instructions are read from memory 144 into cache memory 149 and executed by the processor 148 via cache memory 149.

更详细地,处理器148可以为处理指令的任意逻辑电路,例如,从存储器144或高速缓存149中提取的指令。在众多实施方式中,处理器148为微处理器单元或专用处理器。计算设备140可以基于任意处理器、或处理器集合,其能够如本文中所述的操作。处理器148可以为单核或多核处理器。处理器148可以为多个不同的处理器。More specifically, processor 148 can be any logic circuit that processes instructions, such as instructions retrieved from memory 144 or cache 149. In various embodiments, processor 148 is a microprocessor unit or a dedicated processor. Computing device 140 can be based on any processor, or collection of processors, capable of operating as described herein. Processor 148 can be a single-core or multi-core processor. Processor 148 can be a plurality of different processors.

存储器144可以为适于存储计算机可读数据的任意设备。存储器 144可以为具有固定储存器的设备或者用于读取可移动存储介质的设备。示例包括以下中的所有形式,非易失性存储器、介质和存储器设备、半导体存储器设备(例如,EPROM、EEPROM、SDRAM、以及闪存设备)、磁盘、磁光盘、以及光盘(例如,CD ROM、DVD-ROM、或盘)。计算系统140可以具有任意数目的存储器设备144。Memory 144 can be any device suitable for storing computer-readable data. Memory 144 can be a device with fixed storage or a device for reading removable storage media. Examples include all of the following: non-volatile memory, media and memory devices, semiconductor memory devices (e.g., EPROM, EEPROM, SDRAM, and flash memory devices), magnetic disks, magneto-optical disks, and optical disks (e.g., CD ROM, DVD-ROM, or disk). Computing system 140 can have any number of memory devices 144.

高速缓存存储器149通常是为了快速读取时间而放置在非常接近处理器148的计算机存储器的形式。在某些实施方式中,高速缓存存储器149为处理器148的一部分或者与其在相同的芯片上。在某些实施方式中,存在多级高速缓存存储器149,例如,L2和L3高速缓存层。Cache memory 149 is typically a form of computer memory placed very close to processor 148 for fast read times. In some embodiments, cache memory 149 is part of or on the same chip as processor 148. In some embodiments, there are multiple levels of cache memory 149, such as L2 and L3 cache layers.

网络接口控制器143经由网络接口146(有时称作网络接口端口) 来管理数据交换。网络接口控制器143为网络通信而处理OSI模型的物理层和数据链路层。在某些实施方式中,网络接口控制器的任务中的某些任务由处理器148中的一个或多个来处理。在某些实施方式中,网络接口控制器143为处理器148的一部分。在某些实施方式中,计算系统140具有由单个控制器143控制的多个网络接口146。在某些实施方式中,计算系统140具有多个网络接口控制器143。在某些实施方式中,每个网络接口146为物理网络链路(例如,5类以太网链路)的连接点。在某些实施方式中,网络接口控制器143支持无线网络连接并且接口端口146为无线(例如,无线电)接收机/传送机(例如,用于IEEE 802.11协议、近场通信“NFC”、蓝牙、ANT、或任意其他无线协议中的任意者)。在某些实施方式中,网络接口控制器143实现诸如以太网的一个或多个网络协议。通常,计算系统 140通过网络接口146经由物理或无线链路来与其他计算设备交换数据。网络接口146可以直接链接到另一设备,或者经由例如为网络设备(诸如集线器、网桥、交换机、或路由器)的中间设备来链接到另一设备,将计算设备140连接到诸如互联网的数据网络。The network interface controller 143 manages data exchange via a network interface 146 (sometimes referred to as a network interface port). The network interface controller 143 handles the physical and data link layers of the OSI model for network communications. In some embodiments, some of the network interface controller's tasks are handled by one or more of the processors 148. In some embodiments, the network interface controller 143 is part of the processor 148. In some embodiments, the computing system 140 has multiple network interfaces 146 controlled by a single controller 143. In some embodiments, the computing system 140 has multiple network interface controllers 143. In some embodiments, each network interface 146 is a connection point for a physical network link (e.g., a Category 5 Ethernet link). In some embodiments, the network interface controller 143 supports wireless network connections, and the interface port 146 is a wireless (e.g., radio) receiver/transmitter (e.g., for any of the IEEE 802.11 protocol, near-field communication (NFC), Bluetooth, ANT, or any other wireless protocol). In some embodiments, the network interface controller 143 implements one or more network protocols, such as Ethernet. Typically, computing system 140 exchanges data with other computing devices via physical or wireless links through network interface 146. Network interface 146 may be linked to another device directly or via an intermediary device, such as a network device (such as a hub, bridge, switch, or router), connecting computing device 140 to a data network, such as the Internet.

计算系统140可以包括或者提供用于一个或多个输入或输出 (“I/O”)设备的接口。输入设备包括但不限于键盘、麦克风、触摸屏、脚踏开关、传感器、MIDI设备、以及诸如鼠标或轨迹球的指针设备。输出设备包括但不限于视频显示器、扬声器、点字终端、灯、MIDI设备、以及2维或3维打印机。Computing system 140 may include or provide interfaces for one or more input or output ("I/O") devices. Input devices include, but are not limited to, keyboards, microphones, touch screens, foot switches, sensors, MIDI devices, and pointing devices such as mice or trackballs. Output devices include, but are not limited to, video displays, speakers, Braille terminals, lights, MIDI devices, and 2D or 3D printers.

其他组件145可以包括I/O接口、外部串行设备端口、以及任意附加的协同处理器。例如,计算系统140可以包括接口(例如,通用串行总线(USB)接口),以用于连接输入设备、输出设备、或附加的存储器设备(例如,便携式闪驱或外部介质驱动)。在某些实施方式中,计算设备140包括诸如协同处理器的附加设备145,例如,数学协同处理器能够辅助处理器148进行高准确性或复杂的计算。Other components 145 may include I/O interfaces, external serial device ports, and any additional co-processors. For example, computing system 140 may include interfaces (e.g., Universal Serial Bus (USB) interfaces) for connecting input devices, output devices, or additional storage devices (e.g., portable flash drives or external media drives). In some embodiments, computing device 140 includes additional devices 145 such as co-processors, for example, mathematical co-processors that can assist processor 148 in performing high-precision or complex calculations.

本说明书中描述的主题以及操作的实施方式能够在数字电子电路中、或者嵌入为有形介质、固件、或硬件的计算机软件中实现,包括本说明书中公开的结构及其结构上的等价物、或者他们中的一个或多个的组合。本说明书中描述的主题的实施方式能够被实现为嵌入在有形介质上的一个或多个计算机程序,即,编码在一个或多个计算机存储介质上以由数据处理装置执行或者用于控制数据处理装置的操作的计算机程序指令的一个或多个模块。计算机存储介质能够为计算机可读存储设备、计算机可读存储基底、随机或顺序存取存储器阵列或设备、或他们中的一个或多个的组合,或者包括在其中。计算机存储介质还能够为一个或多个单独的组件或介质(例如,多CD、盘、或其他存储设备),或者包括在其中。计算机存储介质还可以为有形的以及非暂时性的。The subject matter described in this specification and the implementation of the operation can be implemented in a digital electronic circuit, or in a computer software embedded as a tangible medium, firmware, or hardware, including the structure disclosed in this specification and its structural equivalent, or a combination of one or more of them. The implementation of the subject matter described in this specification can be implemented as one or more computer programs embedded in a tangible medium, that is, one or more modules of computer program instructions encoded on one or more computer storage media to be executed by a data processing device or for controlling the operation of a data processing device. The computer storage medium can be a computer-readable storage device, a computer-readable storage substrate, a random or sequential access memory array or device, or a combination of one or more of them, or included therein. The computer storage medium can also be one or more separate components or media (e.g., multiple CDs, disks, or other storage devices), or included therein. The computer storage medium can also be tangible and non-temporary.

本说明书中描述的操作能够被实现为数据处理装置对存储在一个或多个计算机可读存储设备上的数据或者从其他源接收的数据执行的操作。The operations described in this specification can be implemented as operations performed by a data processing apparatus on data stored on one or more computer-readable storage devices or received from other sources.

计算机程序(还被称为程序、软件、软件应用、脚本、或代码) 能够以任意形式的编程语言来编写,包括经编译或解释型的语言、声明或过程语言,并且其能够以任意形式来部署,包括独立程序或者包括模块、组件、子例程、对象、或适于在计算环境中使用的其他单元。计算机程序可以但不需要与文件系统中的文件相对应。程序能够被存储在托管其他程序或数据的文件的一部分中(例如,存储在标记语言文档中的一个或多个脚本),能够存储在专用于所讨论的程序的单个文件中,或者能够存储在多个协同文件中(例如,存储一个或多个模块、子程序、或部分代码的文件)。能够部署计算机程序以在一个计算机上或多个计算机上执行,所述一个计算机或多个计算机位于一个地点或者分布在多个地点并且由通信网络互连。通信网络的示例包括局域网(“LAN”)和广域网(“WAN”)、互连网络(例如,互联网)、以及对等网络(例如,对等点对点网络)。A computer program (also referred to as a program, software, software application, script, or code) can be written in any form of programming language, including compiled or interpreted languages, declarative or procedural languages, and can be deployed in any form, including standalone programs or including modules, components, subroutines, objects, or other units suitable for use in a computing environment. A computer program can, but need not, correspond to a file in a file system. A program can be stored in a portion of a file hosting other programs or data (e.g., one or more scripts stored in a markup language document), can be stored in a single file dedicated to the program in question, or can be stored in multiple collaborative files (e.g., files storing one or more modules, subroutines, or partial codes). A computer program can be deployed to execute on one or more computers, the one or more computers being located in one location or distributed in multiple locations and interconnected by a communication network. Examples of communication networks include local area networks ("LANs") and wide area networks ("WANs"), interconnected networks (e.g., the Internet), and peer-to-peer networks (e.g., peer-to-peer networks).

本说明书中描述的过程和逻辑流程能够由一个或多个可编程处理器执行,所述一个或多个可编程处理器执行一个或多个计算机程序以通过操作输入数据并且生成输出来执行动作。过程和逻辑流程还能够由同样能够实现为专用逻辑电路的装置来执行,例如,FPGA(现场可编程门阵列)或ASIC(专用集成电路)。这样的特殊用途电路可以称作计算机处理器,即使其不是通用处理器。The processes and logic flows described in this specification can be performed by one or more programmable processors executing one or more computer programs to perform actions by operating on input data and generating output. The processes and logic flows can also be performed by devices that can also be implemented as special-purpose logic circuits, such as FPGAs (field programmable gate arrays) or ASICs (application-specific integrated circuits). Such special-purpose circuits may be referred to as computer processors, even though they are not general-purpose processors.

虽然本说明书包含众多特定的实施方式细节,但是,不应该将这些解释为限制可以要求保护的任意发明的范围,而是应该解释为对特定于特定发明的特定实施方式的特征的描述。在单独的实施方式的场境中在本说明书中描述的某些特征在单个实施方式中还能够以组合的方式来实现。相反地,在单个实施方式的场境中描述的各种特征还能够分别在多个实施方式中实现或者在任意合适的子组合中实现。此外,尽管可以如上地将特征描述为以某些组合来起作用并且甚至初始地这样要求,来自要求保护的组合的一个或多个特征能够在某些情况下从组合中删除,并且要求保护的组合可以指向子组合或子组合的变型。While this specification contains numerous specific implementation details, these should not be construed as limiting the scope of any invention that may be claimed, but rather as descriptions of features specific to particular implementations of particular inventions. Certain features described in this specification in the context of separate implementations can also be implemented in combination in a single implementation. Conversely, various features described in the context of a single implementation can also be implemented separately in multiple implementations or in any suitable subcombination. Furthermore, while features may be described above as functioning in certain combinations and even initially claimed as such, one or more features from a claimed combination can be deleted from the combination in certain circumstances, and a claimed combination can be directed to a subcombination or variations of a subcombination.

类似地,虽然按照特定顺序在附图中描绘了各操作,不应该将这理解为要求这样的操作按照所示的特定顺序或连续顺序来执行,或者理解为要求执行所有图示的操作,以达到期望的结果。在某些情形下,多任务以及并行处理可以是有利的。此外,以上描述的实施方式中的各种系统组件的分离不应该被理解为在所有的实施方式中要求这样的分离,并且应该理解,所描述的程序组件和系统通常能够一起集成在单个软件产品中或者封装成多个软件产品。Similarly, although operations are depicted in the accompanying drawings in a particular order, this should not be understood as requiring that such operations be performed in the particular order shown or in a sequential order, or that all illustrated operations be performed in order to achieve the desired results. In some cases, multitasking and parallel processing may be advantageous. Furthermore, the separation of various system components in the embodiments described above should not be understood as requiring such separation in all embodiments, and it should be understood that the described program components and systems can generally be integrated together in a single software product or packaged into multiple software products.

对“或”的引用可以解释为包括性的,使得使用“或”描述的任意术语可以指示所描述的术语中的单个、多个、以及全部中的任意者。标记“第一”、“第二”、“第三”等等不一定意指指示排序并且通常仅用于在相同或类似的项或元素之间进行区分。References to "or" can be interpreted as inclusive, such that any term described using "or" can refer to any of the described terms, singly, plurally, and all. The labels "first," "second," "third," etc. are not necessarily intended to indicate an order and are generally used only to distinguish between identical or similar items or elements.

因而,已经描述了主题的特定实施方式。其他实施方式在以下权利要求的范围内。在某些情况下,在权利要求中记载的动作能够按照不同的顺序来执行并且仍然达到期望的结果。除此之外,在所附附图中描绘的过程不一定要求所示的特定顺序、或者按照连续的顺序,以达到期望的结果。在某些实施方式中,可以利用多任务或并行处理。Thus, specific embodiments of the subject matter have been described. Other embodiments are within the scope of the following claims. In some cases, the actions recited in the claims can be performed in a different order and still achieve the desired results. Furthermore, the processes depicted in the accompanying figures do not necessarily require the specific order shown, or sequential order, to achieve the desired results. In some embodiments, multitasking or parallel processing may be utilized.

Claims (15)

1.一种网络设备,包括:1. A network device, comprising: 网卡;Network card; 至少一个处理器;At least one processor; 存储器;Memory; 在所述至少一个处理器上执行的网络接口驱动器,所述网络接口驱动器被配置为:A network interface driver executing on the at least one processor, the network interface driver being configured to: 接收数据分组集合,所述数据分组集合包括由第一软件应用所生成并且转发的第一数据分组子集以由所述网卡传输和由第二软件应用所生成并且转发的第二数据分组子集以由所述网卡传输;Receive a set of data packets, the set of data packets including a first subset of data packets generated and forwarded by a first software application for transmission by the network interface card (NIC) and a second subset of data packets generated and forwarded by a second software application for transmission by the NIC; 按照第一顺序在主传输队列中存储与所述数据分组集合相关联的描述符;Descriptors associated with the set of data packets are stored in the main transmission queue in a first order; 将与所述数据分组集合相关联的所述描述符传递到在所述至少一个处理器和所述网卡中的一者上执行的数据业务整形模块;以及The descriptor associated with the set of data packets is passed to a data service shaping module that executes on one of the at least one processor and the network interface card; and 响应于确定所述网卡已经成功传送所述数据分组集合中的数据分组,在将附加数据分组子集转发到所述网络接口驱动器之前,将分组传输完成消息通信到已经生成并且转发所述分组以由所述网卡传输并且已经等待接收来自所述网络接口驱动器的所述分组传输完成消息的软件应用,所述软件应用包括所述第一软件应用或所述第二软件应用;以及In response to determining that the network interface card (NIC) has successfully transmitted data packets from the data packet set, before forwarding an additional subset of data packets to the network interface driver, a packet transmission completion message is communicated to a software application that has generated and forwarded the packets for transmission by the NIC and is waiting to receive the packet transmission completion message from the network interface driver, the software application including either the first software application or the second software application; and 所述数据业务整形模块被配置为:The data service shaping module is configured as follows: 维持多个业务整形队列,其中所述多个业务整形队列包括至少第一业务整形队列和第二业务整形队列,并且其中每个业务整形队列具有至少一个相关联的传输速率规则;Maintain multiple service shaping queues, wherein the multiple service shaping queues include at least a first service shaping queue and a second service shaping queue, and wherein each service shaping queue has at least one associated transmission rate rule; 接收与来自所述主传输队列的由所述网络接口驱动器所传递的数据分组集合相关联的所述描述符;Receive the descriptor associated with the set of data packets transmitted by the network interface driver from the main transmission queue; 对与所接收的描述符相关联的所述数据分组集合进行分类;The data packets associated with the received descriptors are classified. 对于所述数据分组集合中的每个数据分组,确定所述数据分组的传输是否将被所述网卡延迟;For each data packet in the data packet set, determine whether the transmission of the data packet will be delayed by the network interface card; 如果确定了所述数据分组被延迟:If it is determined that the data packets are delayed: 从所述主传输队列中移除与所述数据分组相关联的第一描述符并且基于所述数据分组的分类的结果将所述第一描述符存储在所述多个业务整形队列中的特定业务整形队列中;Remove the first descriptor associated with the data packet from the main transmission queue and store the first descriptor in a specific service shaping queue among the plurality of service shaping queues based on the classification result of the data packet; 使得所述网卡根据与所述特定业务整形队列相关联的所述传输速率控制规则来传送与存储在所述相应的业务整形队列中的第一描述符相关联的所述数据分组;以及The network interface card (NIC) transmits the data packets associated with the first descriptor stored in the corresponding service shaping queue according to the transmission rate control rules associated with the specific service shaping queue; and 如果确定了所述数据分组未被延迟,使得所述网卡传送所述数据分组;以及If it is determined that the data packet was not delayed, the network interface card (NIC) transmits the data packet; and 向所述网络接口驱动器通知按照不同于所述第一顺序的第二顺序对所述数据分组集合的成功传输。The network interface driver is notified of the successful transmission of the data packet set in a second order different from the first order. 2.根据权利要求1所述的网络设备,其中所述网络接口驱动器被包括在所述至少一个处理器上执行的操作系统的传输控制协议(TCP)栈的第一层内,并且被配置为与被包括在所述TCP栈的上层中的软件应用通信,所述上层包括所述TCP栈的应用层或者互联网/传输层。2. The network device of claim 1, wherein the network interface driver is included within a first layer of the Transmission Control Protocol (TCP) stack of an operating system executing on the at least one processor, and is configured to communicate with a software application included in an upper layer of the TCP stack, the upper layer including the application layer or the Internet/transport layer of the TCP stack. 3.根据权利要求1所述的网络设备,其中所述网卡被配置为:3. The network device according to claim 1, wherein the network interface card is configured as follows: 通过使用第一资源来传送第一数据分组,所述第一资源存储所述第一数据分组;以及Transmitting a first data packet using a first resource, wherein the first resource stores the first data packet; and 响应于传送所述第一数据分组,使得所述第一资源释放用于存储所述第一数据分组的内存空间以用于存储新数据分组,所述软件应用可访问所述第一资源。In response to transmitting the first data packet, the first resource releases the memory space used to store the first data packet to store the new data packet, and the software application can access the first resource. 4.根据权利要求3所述的网络设备,其中所述第一资源为内存缓冲器的一部分。4. The network device of claim 3, wherein the first resource is part of a memory buffer. 5.根据权利要求1所述的网络设备,其中确定为不会被延迟的所述数据分组在确定为被延迟的所述数据分组之前被传送。5. The network device of claim 1, wherein the data packets determined not to be delayed are transmitted before the data packets determined to be delayed are transmitted. 6.根据权利要求1所述的网络设备,其中所述网卡被配置为相对于在所述主传输队列中存储一个或多个描述符的顺序而言打乱的顺序来传送与在所述主传输队列中存储的所述一个或多个描述符相关联的所述一个或多个数据分组。6. The network device of claim 1, wherein the network interface card is configured to transmit the one or more data packets associated with the one or more descriptors stored in the main transmission queue in a shuffled order relative to the order in which the one or more descriptors are stored in the main transmission queue. 7.根据权利要求1所述的网络设备,其中所述第一数据分组子集属于第一流,以及其中所述第二数据分组子集属于第二流。7. The network device of claim 1, wherein the first subset of data packets belongs to a first flow, and wherein the second subset of data packets belongs to a second flow. 8.根据权利要求7所述的网络设备,其中所述网卡被配置为:8. The network device according to claim 7, wherein the network interface card is configured as follows: 按照在所述第一业务整形队列中存储一个或多个描述符的顺序来传送与存储在所述第一业务整形队列中的所述一个或多个描述符相关联的一个或多个数据分组;以及Transmit one or more data packets associated with the one or more descriptors stored in the first service shaping queue in the order in which they are stored; and 按照在所述第二业务整形队列中存储一个或多个描述符的顺序来传送与存储在所述第二业务整形队列中的所述一个或多个描述符相关联的一个或多个数据分组。One or more data packets associated with the one or more descriptors stored in the second service shaping queue are transmitted in the order in which they are stored in the second service shaping queue. 9.一种用于多流业务整形的方法,包括:9. A method for multi-stream service shaping, comprising: 由在至少一个处理器上执行的网络接口驱动器接收数据分组集合,所述数据分组集合包括由第一软件应用所生成并且转发的第一数据分组子集以由网卡传输和由第二软件应用所生成并且转发的第二数据分组子集以由所述网卡传输;A set of data packets is received by a network interface driver executing on at least one processor, the set of data packets including a first subset of data packets generated and forwarded by a first software application for transmission by a network interface card (NIC) and a second subset of data packets generated and forwarded by a second software application for transmission by the NIC; 由所述网络接口驱动器按照第一顺序在主传输队列中存储与所述数据分组集合相关联的描述符;The network interface driver stores descriptors associated with the set of data packets in the main transmission queue in a first order; 由所述网络接口驱动器将与所述数据分组集合相关联的所述描述符传递到在所述至少一个处理器和所述网卡中的一者上执行的数据业务整形模块;The network interface driver passes the descriptor associated with the data packet set to a data service shaping module that is executed on one of the at least one processor and the network interface card; 响应于确定所述网卡已经成功传送所述数据分组集合中的数据分组,在将附加数据分组子集转发到所述网络接口驱动器之前,由所述网络接口驱动器将分组传输完成消息通信到已经生成并且转发所述分组以由所述网卡传输并且已经等待接收来自所述网络接口驱动器的所述分组传输完成消息的软件应用,所述软件应用包括所述第一软件应用或所述第二软件应用;In response to determining that the network interface card has successfully transmitted data packets in the data packet set, before forwarding an additional subset of data packets to the network interface driver, the network interface driver communicates a packet transmission completion message to a software application that has generated and forwarded the packets for transmission by the network interface card and is waiting to receive the packet transmission completion message from the network interface driver, the software application including the first software application or the second software application. 由所述数据业务整形模块维持多个业务整形队列,其中所述多个业务整形队列包括至少第一业务整形队列和第二业务整形队列,并且其中每个业务整形队列具有至少一个相关联的传输速率规则;The data service shaping module maintains multiple service shaping queues, wherein the multiple service shaping queues include at least a first service shaping queue and a second service shaping queue, and wherein each service shaping queue has at least one associated transmission rate rule; 由所述数据业务整形模块接收与来自所述主传输队列的由所述网络接口驱动器所传递的数据分组集合相关联的所述描述符;The data service shaping module receives the descriptor associated with the set of data packets transmitted by the network interface driver from the main transmission queue; 由所述数据业务整形模块对与所接收的描述符相关联的所述数据分组集合进行分类;The data service shaping module classifies the set of data packets associated with the received descriptors. 对于所述数据分组集合中的每个数据分组,由所述数据业务整形模块确定所述数据分组的传输是否将被所述网卡延迟;For each data packet in the data packet set, the data service shaping module determines whether the transmission of the data packet will be delayed by the network card; 如果确定了所述数据分组被延迟:If it is determined that the data packets are delayed: 从所述主传输队列中移除与所述数据分组相关联的第一描述符并且基于所述数据分组的分类的结果将所述第一描述符存储在所述多个业务整形队列中的特定业务整形队列中;Remove the first descriptor associated with the data packet from the main transmission queue and store the first descriptor in a specific service shaping queue among the plurality of service shaping queues based on the classification result of the data packet; 由所述数据业务整形模块使得所述网卡根据与所述特定业务整形队列相关联的所述传输速率控制规则来传送与存储在所述相应的业务整形队列中的所述第一描述符相关联的所述数据分组;以及The data service shaping module causes the network interface card (NIC) to transmit the data packets associated with the first descriptor stored in the corresponding service shaping queue, according to the transmission rate control rules associated with the specific service shaping queue; and 如果确定了所述数据分组未被延迟,使得所述网卡传送所述数据分组;以及If it is determined that the data packet was not delayed, the network interface card (NIC) transmits the data packet; and 由所述数据业务整形模块向所述网络接口驱动器通知按照不同于所述第一顺序的第二顺序对数据分组集合的成功传输。The data service shaping module notifies the network interface driver of the successful transmission of the data packet set in a second order different from the first order. 10.根据权利要求9所述的方法,其中所述网络接口驱动器被包括在所述至少一个处理器上执行的操作系统的传输控制协议(TCP)栈的第一层内,以及被配置为与被包括在所述TCP栈的上层中的软件应用通信,所述上层包括所述TCP栈的应用层或者互联网/传输层。10. The method of claim 9, wherein the network interface driver is included within a first layer of a Transmission Control Protocol (TCP) stack of an operating system executing on the at least one processor, and is configured to communicate with a software application included in an upper layer of the TCP stack, the upper layer including the application layer or Internet/transport layer of the TCP stack. 11.根据权利要求9所述的方法,进一步包括:11. The method of claim 9, further comprising: 由所述网卡使用第一资源来传送第一数据分组,所述第一资源存储所述第一数据分组;以及The network interface card (NIC) uses a first resource to transmit a first data packet, the first resource storing the first data packet; and 响应于传送所述第一数据分组,使得所述第一资源释放用于存储所述第一数据分组的内存空间以用于存储新数据分组,所述软件应用可访问所述第一资源。In response to transmitting the first data packet, the first resource releases the memory space used to store the first data packet to store the new data packet, and the software application can access the first resource. 12.根据权利要求11所述的方法,其中所述第一资源为内存缓冲器的一部分。12. The method of claim 11, wherein the first resource is a portion of a memory buffer. 13.根据权利要求9所述的方法,其中,确定为不会被延迟的所述数据分组在确定为被延迟的所述数据分组之前被传送;和/或13. The method of claim 9, wherein the data packets determined not to be delayed are transmitted before the data packets determined to be delayed; and/or 其中,所述方法进一步包括:The method further includes: 由所述网卡相对于在所述主传输队列中存储一个或多个描述符的顺序而言打乱的顺序来传送与在所述主传输队列中存储的所述一个或多个描述符相关联的所述一个或多个数据分组。The network interface card (NIC) transmits the one or more data packets associated with the one or more descriptors stored in the main transmission queue in a shuffled order relative to the order in which the descriptors are stored in the main transmission queue. 14.根据权利要求13所述的方法,其中,所述第一数据分组子集属于第一流,以及其中所述第二数据分组子集属于第二流;和/或14. The method of claim 13, wherein the first subset of data packets belongs to a first stream, and wherein the second subset of data packets belongs to a second stream; and/or 其中,所述方法进一步包括:The method further includes: 由所述网卡按照在所述第一业务整形队列中存储一个或多个描述符的顺序来传送与存储在所述第一业务整形队列中的所述一个或多个描述符相关联的一个或多个数据分组;以及The network interface card (NIC) transmits one or more data packets associated with one or more descriptors stored in the first service shaping queue in the order in which they are stored in the first service shaping queue; and 由所述网卡按照在所述第二业务整形队列中存储一个或多个描述符的顺序来传送与存储在所述第二业务整形队列中的所述一个或多个描述符相关联的一个或多个数据分组。The network interface card (NIC) transmits one or more data packets associated with one or more descriptors stored in the second service shaping queue in the order in which they are stored in the second service shaping queue. 15.一种包括指令的非暂时性计算机可读存储介质,所述指令在被至少一个处理器执行时使得所述至少一个处理器执行权利要求9至14中的任一项所述的方法。15. A non-transitory computer-readable storage medium comprising instructions that, when executed by at least one processor, cause the at least one processor to perform the method of any one of claims 9 to 14.
HK18101465.4A 2016-03-10 2018-01-30 Systems and method for single queue multi-stream traffic shaping HK1243565B (en)

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
US15/066,411 2016-03-10

Publications (2)

Publication Number Publication Date
HK1243565A1 HK1243565A1 (en) 2018-07-13
HK1243565B true HK1243565B (en) 2022-05-06

Family

ID=

Similar Documents

Publication Publication Date Title
CN107181698B (en) System and method for single queue multi-stream traffic shaping
CN108337186B (en) Apparatus and method for scalable traffic shaping
CN107925677B (en) Method and switch for offloading data object replication and service function chain management
US10454835B2 (en) Device and method for scalable traffic shaping with a time-indexed data structure
US11831550B2 (en) Fine grain traffic shaping offload for a network interface card
CN113711547A (en) System and method for facilitating efficient packet forwarding in a Network Interface Controller (NIC)
US9014005B2 (en) Low-latency lossless switch fabric for use in a data center
US10909067B2 (en) Multi-node zero-copy mechanism for packet data processing
JP2009506618A (en) System and method for processing and transferring transmission information
US11153221B2 (en) Methods, systems, and devices for classifying layer 4-level data from data queues
TW202450279A (en) Transport layer network recovery for packet-switched computer networks
US10171354B2 (en) Communication processing system, communication processing apparatus, communication processing method, and storage medium
HK1243565B (en) Systems and method for single queue multi-stream traffic shaping
HK1243565A1 (en) Systems and method for single queue multi-stream traffic shaping
HK40108452B (en) Fine grain traffic shaping offload for a network interface card
HK40108452A (en) Fine grain traffic shaping offload for a network interface card
HK1259547A1 (en) Device and method for scalable traffic shaping with a time-indexed data structure
HK1259547B (en) Device and method for scalable traffic shaping with a time-indexed data structure
Li et al. AQC: Achieving Precise Bandwidth Allocation with Augmented Queues for Credit-Based Proactive Congestion Control
HK1259197A1 (en) Device and method for scalable traffic shaping
HK40038518B (en) Fine grain traffic shaping offload for a network interface card
WO2018098767A1 (en) Device and method for performing network interface bonding
HK40038518A (en) Fine grain traffic shaping offload for a network interface card
Chen et al. Inspecting the performance of packet schedulers over a large-scale OpenFlow-based network