So, first let's talk about virtual network functions. And what we said is that network functions should be really implemented user-space on top of hypervisor. And we motivated the need for doing that, primarily because of the fact that these network functions, you want them to be portable. And if you want it to be portable, you should not be tied down to any particular operating system. And therefore, putting on top of hypervisor is a good idea. And we also introduced load balancer as a concrete example of a network function. And the idea behind a load balancer is regardless of what the enterprise wants to do, what it is doing is, it is having a pool of back end service instances. For example, if you think about an HTTP server. There may be several instances of HTTP server and user requests may be directed to different servers. And there is a need for sort of horizontally scale the number of several instances so that you can cater to the needs of the user community. So what this particular network function is doing, it is distributing the incoming packet flows to specific instance, to exploit the inherent parallelism that may be there in the hardware, as well as balance the load across all the server instances. So if you think in terms of how to implement it, we gave a little preview of that in the previous lecture also. If you think about the architecture of a load balancer network function, what is gonna look like is this load balancer entity that is sitting in the middle, the software entity. And what he's gonna do is we're gonna look at Incoming requests, and when the incoming request is looked at by the load balancer, it will extract from the incoming request the 5-tuple. What is the 5-tuple? That is the source address, the destination address, the source port, the destination port and the protocol, right? That's your 5-tuple and using that there is a table that this load balancer maintains. And using that 5-tuple it's gonna look up whether this particular flow is already being handled. If it is handled, then there'll be an entry for it in the table. And so it can direct this traffic to that particular back end instance. On the other hand, if there's a brand new flow that is coming in, then maybe it has to create a new entry. And then and say that this particular entry is gonna be served by this back end instance. And of course it will be there's a finite number of back end instances and therefore, what the load balancer is doing is, when the number of external requests exceeds the number of backend service instances it has, it's gonna loose the load balancing here across all of you back end instances. So that's the rule of this particular network function. So what it is doing it is providing connection level affinity for the incoming requests. And the same connection is being sent to the same back end instance. So that's what we're doing with this particular function. By the way one thing that I wanna mention is that most of the network functions tend to be implemented on top of an operating system such as Linux. And that's a favorite for most network functions. And that's how the middleboxes came about. And and so now we are when we are trying to migrate these network functions or software entities, we wanna do it on top of Linux Operating System. So what you're doing is in this particular example of a load balancer. What the load balancer is doing, it is reading packets from the network using a Unix socket. So it can use something like the recvfrom reads the packet, and once it reads the packet, it can extract the header. And the header information is gonna give you the 5-tuple. And once you have the header information, then the load balancer can look up this table to see if there is a match. If a match is found, then you send the packet to the particular instance. That's what the load balancer is doing. On the other hand, if an instance is not there already associated with this particular 5-tuple that we extracted, then we're going to create a new instance. And or send it to one of the existing instances, but we're creating a new entry in this table. And then you're gonna send it the same way to the particular instance that is gonna handle that. So, that's sort of how you would implement this load balancer network function.