|
The Leaky Bucket Operation
By convention the leaky bucket starts initially empty.
Upon packet arrival ‘fluid’ (i.e. ‘tokens’) is poured into the bucket, by an amount equivalent to the size of the packet. If upon arrival the packet is able to pour fluid equivalent to its complete size into the bucket then the packet is conforming, otherwise non-conforming. The filling of the bucket is governed by traffic arrival, and there is no delay involved in it. If the bucket is empty traffic equivalent to the bucket size can pass at infinite speed.
Fluid is leaking from the bucket at constant pace.
The Leaky Bucket defines a similar traffic envelope as a Token Bucket.
The Leaky Bucket is equivalent to a token bucket in the sense that both of them would find the same packets in and out of profile of the same traffic stream, if the following conditions are met:
The leaky bucket and the token bucket have the same bucket size
The token accumulation rate of the token bucket is equal to the fluid leaking rate of the leaky bucket
At time zero the leaky bucket starts empty and the token bucket starts full
When the leaky bucket assist and algorithmic dropper, it is equivalent to a Token Bucket policer.
The leaky bucket (just like the token bucket) can be used also in conjunction with a shaper, see CBR shaping and VBR shaping. In that context it assist the release of packets from the shaped queue. A leaky bucket with a burst tolerance larger than one MTU-sized frame (or one cell) is used to implement a variable bit-rate shaper, otherwise it is a constant bit rate shaper.
|