Today, we discuss traffic management at the Flow Level and a focus on Leaky Bucket Policing. How congesting occurs in network car? It occurs when a surge of traffic overloads network resources in transmitting and buffering. For example, consider the packet switching network shown in the figure. Suppose the nodes 1, 2 and 5 continuously transmit packets to their respective destination by node 4. If the aggregate incoming rate of the packet flows to node 4 is greater that it's transmission capacity, buffer in node 4 will build up and eventually start packet discarding. If the protocol requires real transmission on missing packets, the congestion becomes even worse. The purpose of traffic management at the flow level is to control the flows of traffic and maintain performance even in the presence of traffic congestion. The process is called congestion control, which aims to achieve desirable performance as illustrated in the figure. Congestion control is a very hard problem as is packet routing. There are two main categories of approach. One is called Preventive Approach. That is open-loop, based on scheduling and resource reservation. The other is called a Reactive Approach. That it is closed-loop, based on detection and discarding. In open-loop control, it doesn't rely on feedback information to react to a congestion. Instead, it aims to guarantee network performance during the lifetime of admitted flows. Key mechanism are admission control, policing and traffic shaping. Admission control was initially developed for connection-oriented virtual circuit packet networks. Flows negotiate a contract with the network, specifying requirements in peak, average and minimum balance, maximum burst size, delay and loss. The maximum burst size determines the maximum length of time the traffic can be generated and at a peak rate. Network computes the resource. Typically bandwidth and buffered requirements of a new flow and determines whether the resource is along the path to be followed by the flow available. To prevent as a source from violating its contract, the network monitors the traffic flows continuously to ensure they meet their traffic contract. When a packet violates the contract, network can discard or tag the packet giving its lower priority. If congestion occurs, tagged packets are discarded first. The process of monitoring and enforcing the traffic flow is called policing. Most implementations of a policing device are based on the concept of a leaky bucket. How it all works. Imagine the traffic flow to a policing device as water being poured into a bucket that has a hole at the bottom. A leaky bucket has specified a leakage rate for average contractor rate. The bucket has specified depths to accommodate the variations in arrival rate. Arriving packet is conforming if it doesn't result in overflow. In the network scenario, please note that the drain is per packet rather than in fluid. We look at a leaky bucket specified by ATM. All packets are of same fixed length. A counter records the content of the leaky bucket. When a packet arrives, the counter is incremented by I if a bucket wouldn't exceed the limit. In this case, the packet is the clearer to be conforming. Value I indicates the average inter arrival time of packets being policed. Let's look an example of the operation of the leaky bucket algorithm. The bucket adapts is L plus I. Well, L typically depends on the traffic briskness. In this example, L equals to six I. The average inter arrival time of our arriving packets is four. The top part of the figure shows the packet arrivals at a different time. The lower part of the figure shows the behavior of the leaky bucket in terms of the bucket content. At a time t2, the first packet comes and are stored in the bucket. The depths of the bucket is instantly increased by I, that is four. One unit time later, when unit or packet is transmitted and the depths of the bucket becomes three. As the packets keep coming at different times, the bucket content keeps changing. The first non-conforming packet is packet five arriving at the time t5. In that moment, the bucket content is at a seven adding packet five into the bucket. The bucket would overflow. At t7, the bucket is empty as all previous packets are eventually drained out. Then, packet's seven, eight, nine, and 10 arrive back to back. I hope you can find that packets seven, eight and nine are conforming, but packet 10 is nonconforming. If the peak rate is one packet a [inaudible] time, then the maximum number of packets that can be transmitted as a peak rate is called the maximum burst rate. In this case it is three packets. This example concludes today's class.