Académique Documents
Professionnel Documents
Culture Documents
P.F. Chimento
May 18, 2000
X
Simple Token Bucket Configuration
Figure 1: A simple Token Bucket
nism from the left in quanta called packets. Token flow into the bucket (green) from the top at rate γ.
When the bucket is full of tokens, new tokens are thrown away. Each token is worth a defined number of
bytes. It is easier if we think of each token as being worth one byte.
When a packet arrives from the left, if there are a number of tokens in the bucket at least equal to
the number of bytes in the packet, the packet may exit the system immediately. If there are not enough
tokens in the bucket, then one of a number of things may happen, depending on how the token bucket is
being used:
1. The packet may be thrown away.
2. The packet may be marked in a particular way.
3. The packet may be buffered (by inserting a buffer between the inflow and the decision point) and
not released until a sufficient number of tokens arrive in the bucket.
There are a number of things to note about this picture:
1. The rate γ is the long-term rate at which the data flows out of the bucket.
2. The bucket depth τ is the maximum amount of information that can flow out of the bucket back-
to-back (i.e. with arbitrary spacing).
1
3. When the bucket is being used as a shaper, the outflow rate is usually termed the peak rate which
can in fact be much faster than the rate denoted by γ. This rate can be controlled to be a particular
rate β by inserting another buffer/decision point after the token bucket. If no special notations or
adjustments are made, β is assumed to be the physical line rate of the output link.
You can think of γ as the sustained rate at which the data can exit the token bucket system and you
can think of τ as the size of the burst which can flow out of the system at the peak rate β.
Note that the device has a memory by reason of the bucket.
3 Proposal
In order to keep to more or less accepted terminology and concepts, I suggest that the token bucket model,
as described in [2] for example, be adopted as the traffic descriptor for QPS and for the Bandwidth Broker
design. Further, I think that a good model for us is the TSPEC as described in [4] and [3]. These RFCs
have good descriptions of the parameters necessary to describe traffic streams in terms of token buckets.
If this proposal is accepted, we can work out some detailed definitions and format descriptions.
References
[1] Rüdiger Geib, QPS Traffic Conditioning, unpublished working document, May 2000