Use Kubernetes informer and cache in router (#376)

Use Kubernetes client's informer and cache to watch functions and triggers in the router. This replaces the polling loop we were using so far.
This commit is contained in:
Ta-Ching Chen
2017-10-25 15:10:44 -07:00
committed by Soam Vasani
parent 8abb0005f6
commit 439e7d4535
7 changed files with 150 additions and 70 deletions
+1 -1
View File
@@ -58,7 +58,7 @@ func TestRouter(t *testing.T) {
frr.refCache.Set(nfr, rr)
// HTTP trigger set with a trigger for this function
triggers := makeHTTPTriggerSet(fmap, nil, nil, frr)
triggers := makeHTTPTriggerSet(fmap, nil, nil, frr, nil)
triggerUrl := "/foo"
triggers.triggers = append(triggers.triggers,
tpr.Httptrigger{