^{1}

^{2}

^{*}

Weighted priority queueing is a modification of priority queueing that eliminates the possibility of blocking lower priority traffic. The weights assigned to priority classes determine the fractions of the bandwith that are guaranteed for individual traffic classes, similarly as in weighted fair queueing. The paper describes a timed Petri net model of weighted priority queueing and uses discrete-event simulation of this model to obtain performance characteristics of simple queueing systems. The model is also used to analyze the effects of finite queue capacity on the performance of queueing systems.

Although the internet was originally intended for non-time-critical transport [

The strategy for mixing real-time and bulk traffic is to use, at the nodes of the network, separate queues for different classes of traffic, so the real-time traffic can get the service it requires. Priority queueing [

Modern communication networks [

In inhibitor Petri nets, in addition to directed arcs, inhibitor arcs provide “test if zero” condition which does not exist in “standard” Petri nets. Inhibitor arcs are needed for modeling priority mechanisms.

In order to study performance aspects of systems modeled by Petri nets, the durations of modeled activities must also be taken into account. This can be done in different ways, resulting in different types of temporal nets. In timed Petri nets [

Timed Petri nets are used in this paper to develop models of weighted priority queueing and then performance characteristics of simple queueing systems are obtained by discrete-event simulation of developed models.

Section 2 recalls basic concepts of Petri nets and timed Petri nets. Section 3 describes the net model of weighted priority queueing while Section 4 uses the developed model to analyze the performance of simple weighted priority queueing systems. Section 5 concludes the paper.

Petri nets [

In Petri nets the distribution of tokens over places changes by occurrences (or firings) of transitions. A transition t is enabled by a marking function m if all places connected to t by directed arcs are marked and all places connected to t by inhibitor arcs are unmarked. When an enabled transition t occurs (or fires), one token is removed from each place connected to t by a directed arc and one token is deposited to each place connected to t by an outgoing arc. An occurrence of a transition creates a new marking function, a new set of enables transitions, and so on. The set of all marking functions that can be created starting from the initial marking m 0 is called the reachability set of a net. This set can be finite or infinite.

A place is shared if it is connected to more than one transition. A shared place p is free-choice if the sets of places connected by directed arcs and inhibitor arcs to all transitions sharing p are identical. All transitions sharing a free-choice place constitute a free-choice class of transitions. For each marking function, either all transitions in each free-choice class are enabled or none of these transitions is enabled. It is assumed that a choice of an occurring transition in each free-choice class is random and can be described by probabilities associated with transitions. A shared place which is not free-choice is a conflict place and transitions sharing it are conflicting transitions.

Temporal behavior can be introduced in Petri nets in several ways, resulting in different classes of Petri nets “with time” [

Formally, a timed Petri net is a triple, T = ( M , c , f ) , where M is a marked net, c is a choice function which assigns probabilities to transitions in free-choice classes and relative frequencies of occurrences to conflicting transitions, c → [ 0,1 ] , and f is a timing function which assigns an (average) occurrence time to each transition of the net, f : T → R + , where R + is the set of nonnegative real numbers.

The occurrence times of transitions can be either deterministic or stochastic (i.e., described by some probability distribution function); in the first case, the corresponding timed nets are referred to as D-timed nets [

In timed nets, it is convenient to have a possibility of some events to occur “immediately”, i.e., in zero time; all transitions with zero occurrence times are called immediate (while the others are called timed). Since the immediate transitions have no tangible effects on the (timed) behavior of the model, it is convenient to “split” the set of transitions into two parts, the set of immediate and the set of timed transitions, and to first perform all occurrences of the (enabled) immediate transitions, and then (still in the same time instant), when no more immediate transitions are enabled, to start the occurrences of (enabled) timed transitions. It should be noted that such a convention effectively introduces the priority of immediate transitions over the timed ones, so the conflicts of immediate and timed transitions are not allowed in timed nets. Detailed characterization of the behavior or timed nets with immediate and timed transitions is given in [

In priority queueing [

Weighted priority scheduling limits the number of consecutive packets of the same class that can be transmitted over the channel; when the scheduler reaches this limit, it switches to the next nonempty priority queue and follows the same rule. These limits are called weights, and are denoted w 1 . With k classes of traffic, if there are sufficient numbers of packets in all classes, the scheduler selects w 1 packets of class 1, then w 2 packets of class 2, …, then w k packets of class k, and again w 1 packets of class 1, and so on. Consequently, in such a situation (i.e., for sufficient supply of packets in all classes), the channel is shared by the packets of all priority classes, and the proportions are:

u i = w i / s i ∑ j = 1 , ⋯ , k w j / s j , i = 1 , 2 , ⋯ , k

where s i , i = 1 , ⋯ , k is the transmission rate for packets of class i. If the transmission rates are the same for packets of all classes (as is assumed for simplicity in the illustrating examples), the proportions are:

u i = w i ∑ j = 1 , ⋯ , k w j , i = 1 , ⋯ , k .

For an example with 3 priority classes and the weights equal to 4, 2 and 1 for classes 1, 2 and 3, respectively, these “utilizations bounds” are equal to 4/7, 2/7 and 1/7, for classes 1, 2 and 3, respectively.

A Petri net model of weighted priority scheduling for three classes of packets with weights 4, 2 and 1 is shown in

The main elements of the model are the three queues represented by places p 1 , p 2 and p 3 for traffic class 1, 2 and 3, respectively, and timed transitions t 1 , t 2 and t 3 modeling the transmission of selected packets through the communication channel. The three classes of packets are generated (independently) by transitions t 01 , t 02 and t 03 with places p 01 , p 02 and p 03 . The occurrence times f ( t 01 ) , f ( t 02 ) and f ( t 03 ) determine the arrival rates for queues 1, 2 and 3, respectively.

The scheduling is based on repeated selection of queues in order of priorities (first class 1, then 2, and so on) for the transmission of queued packets. This selection operation is represented by a loop with places r 0 , r 1 , r 2 and r 3 , and q 1 , q 2 and q 3 . There is a single “control token” in this loop (shown in place r 0 in

Let r 0 be marked. If all three queues are empty, the next packet arriving to one of the queues enables one of the transitions s 1 , s 2 or s 3 , the control token is moved from r 0 to place r i corresponding to the nonempty queue, and an occurrence of transition a i selects a token from p i for transmission. At the same time, one token from place w i is moved to place u i . When the channel becomes available for transmission (which is indicated by an occurrence of t i 0 ), the control token is returned to r i . Now there are three possibilities:

・ if the queue (place p i ) is nonempty and the weight ( w i ) is nonempty, another token is selected from p i and forwarded for transmission;

・ if the queue is empty, an occurrence of transition d i moves the control token from r i to q i ;

・ if the weight is empty, an occurrence of transition c i also moves the control token from r i to q i .

A token in q i moves (by repeated occurrences of b i ) all tokens from place u i back to w i , and when u i becomes empty, an occurrence of transition e i moves the control token to the next class represented by r i + 1 . If the queue for this class is empty, occurrences of transitions d i + 1 and e i + 1 move the control token to a subsequent class until r 0 is reached, and then the highest priority nonempty class is selected by an occurrence of one of transitions s 1 , s 2 or s 3 .

The model shown in

The (finite) capacity of the queue is represented by the initial marking of place p 14 (shown in

Finally, when a packet is selected for transmission and is removed from the queue, each occurrence of transition t 10 returns a token to p 14 , indicating that the queue can store another packet.

The model shown in

For ρ 1 ≤ 0.25 , channel utilizations for classes 2 and 3 are constant at the levels of 0.5 and 0.25, respectively (all service rates are equal to 1 for simplicity, so the utilizations are equal to traffic intensities and also the arrival rates are equal to traffic intensities); for class 1, the utilization changes linearly with ρ 1 . It should be noted that traffic intensities ρ 2 and ρ 3 are significantly greater that the performance levels guaranteed by the weights 4-2-1 (equal to 2/7 and 1/7 for classes 2 and 3, respectively). For ρ 1 = 0.25 , the channel becomes fully utilized ( ρ 1 + ρ 2 + ρ 3 = 1 ), so further increases of ρ 1 result in decreasing utilizations of the channel for classes 2 and 3, until the levels guaranteed by the weights are reached (these levels are 2/7 or 0.286 and 1/7 or 0.143). This occurs at ρ 1 = 4 / 7 or 0.571.

Average waiting times for classes 1, 2 and 3, as functions of traffic intensity ρ 1 with ρ 2 = 0.5 and ρ 3 = 0.25 (i.e., consistent with

For ρ 1 > 0.25 , queues 2 and 3 are nonstationary because their arrival rates are greater than departure rates. Similarly, for ρ 1 > 0.571 , queue 1 is nonstationary. In practical queueing systems the capacities of queues are finite, so the nonstationary regions correspond to dropping of some arriving packets because they cannot be queued.

If, however, the (constant) traffic intensities ρ 2 and ρ 3 do not exceed the levels of traffic determined by the weights, the behavior of the queueing system is different, as shown in

In this case queue 1 becomes nonstationary at ρ 1 = 1 − ρ 2 − ρ 3 = 0.65 . Moreover, the waiting times for classes 2 and 3 depend rather insignificantly on the traffic of class 1, as shown in

When the capacity of a queue is finite, packets which arrive when the queue is full are dropped as they cannot be queued. The percentage of dropped packets is an important metric of the system.

Average waiting times are shown in

Results shown in

It should be observed that from performance point of view, it is not beneficial to have long queues for packets waiting for service. For high intensity traffic these queues will be practically full, and then the average waiting time will simply increase proportionally with the queue length.

The average waiting times in

Finally,

For class 1, the increase of the fraction of dropped packets is caused by queue 1 which is becoming full; all arriving packets which cannot be queued, are dropped.

For classes 2 and 3, the fraction of dropped packets is very small and the average waiting times are also rather small.

Efficient use of modern networks requires detailed knowledge of network characteristics, traffic statistics, transmission media types, and so on. Some of this information can be obtained by measurements performed under real traffic, but other can only be provided by detailed models, verified by comparisons with measurement data. On the basis of these characteristics, specific methods can be developed to determine the optimal numbers of links, the transmission capacity of links, the management strategy for resources shared among traffic classes, and others.

The goal of this paper is to provide insight into the behavior of weighted priority queueing, a modification of (strict) priority queueing that eliminates blocking of lower priority traffic that is typical for priority-based traffic management schemes. The paper shows that when the weights match the characteristics of lower priority traffic, the performance provided by the analyzed scheme is actually quite good. However, since in real communication networks the characteristics often change, a dynamic weight selection method may be needed for adjusting the performance to the changing character of the traffic. Some ideas for such a dynamic weighted queueing can be found in [

The weighted priority queueing exhibits several similarities to the weighted fair queueing [

The authors declare no conflicts of interest regarding the publication of this paper.

Strzeciwilk, D. and Zuberek, W.M. (2018) Modeling and Performance Analysis of Weighted Priority Queueing for Packet-Switched Networks. Journal of Computer and Communications, 6, 195-208. https://doi.org/10.4236/jcc.2018.611019