Fission workflow env integration (#336)

Add a flag to the environment to control multiple specialization -- the max number of functions per container. This can be set to 1 or infinity. 

Add an api proxy to workflow apiserver from the controller.

Add function metadata to FunctionLoadRequest; every v2 environment now knows which function it's loading (but can ignore that information if it wants to).

Add function identity headers to router. This is useful for multiple specialization, so the router can disambiguate between different function calls. (If this turns out to be a non-trivial perf overhead, we could add these headers conditionally, but for now they are always added.)
This commit is contained in:
Erwin van Eyk
2017-09-26 18:36:07 -07:00
committed by Soam Vasani
parent 3f58247b59
commit 33f967b61b
8 changed files with 115 additions and 20 deletions
+3
View File
@@ -98,6 +98,9 @@ func (fh *functionHandler) handler(responseWriter http.ResponseWriter, request *
request.Header.Add(fmt.Sprintf("X-Fission-Params-%v", k), v)
}
// System Params
MetadataToHeaders(HEADERS_FISSION_FUNCTION_PREFIX, fh.function, request)
// cache lookup
serviceUrl, err := fh.fmap.lookup(fh.function)
if err != nil {