Serve only one request and garbage collect (#1978)

Adding once only execution pattern to pool manager based functions. This is for use cases where you don't want to share the samne pod for another execution instance!
This commit is contained in:
Rahul Bhati
2021-05-19 22:48:49 +05:30
committed by GitHub
parent f523f8b2e3
commit 462b7d861d
8 changed files with 20 additions and 2 deletions
+4
View File
@@ -357,6 +357,10 @@ type (
// RequestsPerPod indicates the maximum number of concurrent requests that can be served by a specialized pod
// This is optional. If not specified default value will be taken as 1
RequestsPerPod int `json:"requestsPerPod,omitempty"`
// OnceOnly specifies if specialized pod will serve exactly one request in its lifetime and would be garbage collected after serving that one request
// This is optional. If not specified default value will be taken as false
OnceOnly bool `json:"onceOnly,omitempty"`
}
// InvokeStrategy is a set of controls over how the function executes.