The router forwards HTTP requests to function pods. If there’s no running service for a function, it requests one from executor, while holding on to the request; the router will forward the request to the pod once the function service is ready.
The router is the only stateless component and can be scaled up if needed, according to load.
- Client sends requests to a specific URL on the Router.
- Router returns 404 if there is no matching HTTP Trigger exists. If a trigger exists, then check whether the function service record exists in cache. If cache hits, go to step 4; otherwise, go to step 3.
- Ask Executor to provide the service address of the Function.
- Router redirects requests to the address just returned.