Platform SDK: Quality of Service |
The FLOWSPEC structure provides QOS parameters to the RSVP SP. This allows QOS-aware applications to invoke, modify, or remove QOS settings for a given flow.
Some members of FLOWSPEC can be set to default values. See Remarks for more information.
typedef struct _flowspec { uint32 TokenRate; // In bytes/second uint32 TokenBucketSize; // In bytes uint32 PeakBandwidth; // In bytes/second uint32 Latency; // In microseconds uint32 DelayVariation; // In microseconds SERVICETYPE ServiceType; // Guaranteed, predictive, etc. uint32 MaxSduSize; // In bytes uint32 MinimumPolicedSize // In bytes } FLOWSPEC, *PFLOWSPEC, FAR * LPFLOWSPEC;
With this model, applications can transmit data only when sufficient credits are available. If sufficient credits are not available, the application must either wait or discard the traffic (based on the value of QOS_OBJECT_SD_MODE). Therefore it is important that applications base their TokenRate requests on reasonable expectations for transmission requirements. For example, in video applications, TokenRate is typically set to the average bit rate from peak to peak.
If TokenRate is set to QOS_NOT_SPECIFIED on the receiver only, the maximum transmission unit (MTU) is used for TokenRate, and limits on the transmission rate (the token bucket model) will not be put into effect. TokenRate is expressed in bytes per second.
TokenRate cannot be set to zero. TokenRate cannot be set as a default (that is, set to QOS_NOT_SPECIFIED) in a sending FLOWSPEC.
Value | Meaning |
---|---|
SERVICETYPE_NOTRAFFIC | Indicates that no traffic will be transmitted in the specified direction. On duplex-capable media, this value signals underlying software to set up unidirectional connections only. This service type is not valid for the TC API. |
SERVICETYPE_BESTEFFORT | Results in no action taken by the RSVP SP. Traffic control does create a BESTEFFORT flow, however, and traffic on the flow will be handled by traffic control similarly to other BESTEFFORT traffic. |
SERVICETYPE_CONTROLLEDLOAD | Provides an end-to-end QOS that closely approximates transmission quality provided by best-effort service, as expected under unloaded conditions from the associated network components along the data path.
Applications that use SERVICETYPE_CONTROLLEDLOAD may therefore assume the following:
|
SERVICETYPE_GUARANTEED | Guarantees that datagrams will arrive within the guaranteed delivery time and will not be discarded due to queue overflows, provided the flow's traffic stays within its specified traffic parameters. This service is intended for applications that need a firm guarantee that a datagram will arrive no later than a certain time after it was transmitted by its source. |
SERVICETYPE_QUALITATIVE | Indicates that the application requires better than BESTEFFORT transmission, but cannot quantify its transmission requirements. Applications that use SERVICETYPE_QUALITATIVE can supply an application ID policy object. The application ID policy object enables policy servers on the network to identify the application, and accordingly, assign an appropriate QOS to the request. For more information on application ID, consult the IETF Internet Draft draft-ietf-rap-rsvp-appid-00.txt, or the Microsoft white paper on Application ID. Traffic control treats flows of this type with the same priority as BESTEFFORT traffic on the local computer. However, application programmers can get boosted priority for such flows by modifying the Layer 2 settings on the associated flow using the QOS_OBJECT_TRAFFIC_CLASS QOS object. |
SERVICETYPE_NETWORKCONTROL | Used only for transmission of control packets (such as RSVP signaling messages). This ServiceType has the highest priority. |
SERVICETYPE_GENERAL_INFORMATION | Specifies that all service types are supported for a flow. Can be used on sender side only. |
SERVICETYPE_NOCHANGE | Indicates that the QOS in the transmission using this ServiceType value is not changed. SERVICETYPE_NOCHANGE can be used when requesting a change in the QOS for one direction only, or when requesting a change only within the ProviderSpecific parameters of a QOS specification, and not in the SendingFlowspec or ReceivingFlowspec. |
SERVICE_NO_TRAFFIC_CONTROL | Indicates that traffic control should not be invoked in the specified direction. |
SERVICE_NO_QOS_SIGNALING | Suppresses RSVP signaling in the specified direction. |
The following list identifies the relative priority of ServiceType settings:
SERVICETYPE_NETWORKCONTROL
SERVICETYPE_GUARANTEED
SERVICETYPE_CONTROLLED_LOAD
SERVICETYPE_BESTEFFORT, SERVICETYPE_QUALITATIVE
Non-conforming traffic
For a simple example, if a given network device were resource-bounded and had to choose among transmitting a packet from one of the above ServiceType settings, it would first send a packet of SERVICETYPE_NETWORKCONTROL, and if there were no packets of that ServiceType requiring transmission it would send a packet of ServiceType SERVICETYPE_GUARANTEED, and so on.
Many members of the FLOWSPEC structure can be set to default values by setting the member to QOS_NOT_SPECIFIED. Note that the members that can be set to default values differ depending on whether the FLOWSPEC is a receiving FLOWSPEC or a sending FLOWSPEC.
There are a handful of considerations you should keep in mind when using FLOWSPEC with traffic control:
Many settings can be defaulted in a receiving FLOWSPEC except ServiceType, with the following considerations:
The following list specifies the values that are applied when a receiving FLOWSPEC sets the corresponding values to default:
When the value of the ServiceType is set to SERVICETYPE_GUARANTEED, the following also applies:
In a sending FLOWSPEC, everything can be defaulted except ServiceType and TokenRate. The following list specifies the values that are applied when a sending FLOWSPEC sets the corresponding values to default:
Notes for Traffic Control: The following ServiceTypes are invalid when specifically working with Traffic Control. If you are unsure whether you are working directly with Traffic Control (and thereby need to be concerned about whether the following ServiceTypes are applicable in your situation), you probably are not:
SERVICETYPE_NOTRAFFIC
SERVICETYPE_NETWORK_UNAVAILABLE
SERVICETYPE_GENERAL_INFORMATION
SERVICETYPE_NOCHANGE
SERVICE_NO_TRAFFIC_CONTROL
SERVICE_NO_QOS_SIGNALING
Windows NT/2000: Requires Windows 2000.
Windows 95/98: Requires Windows 98.
Header: Declared in Qos.h.