From 408391175f41e014cfbc9cfe244926a00eb320f8 Mon Sep 17 00:00:00 2001 From: Manuel de Brito Fontes Date: Sun, 17 Jun 2018 12:27:12 -0400 Subject: [PATCH] Do not wait informer initialization to read configuration --- internal/ingress/controller/store/store.go | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/internal/ingress/controller/store/store.go b/internal/ingress/controller/store/store.go index ea697179b..7ef02359d 100644 --- a/internal/ingress/controller/store/store.go +++ b/internal/ingress/controller/store/store.go @@ -494,6 +494,13 @@ func New(checkOCSP bool, store.informers.ConfigMap.AddEventHandler(cmEventHandler) store.informers.Service.AddEventHandler(cache.ResourceEventHandlerFuncs{}) + // do not wait for informers to read the configmap configuration + cm, err := client.CoreV1().ConfigMaps(namespace).Get(configmap, metav1.GetOptions{}) + if err != nil { + glog.Warningf("Unexpected error reading configuration configmap: %v", err) + } + store.setConfig(cm) + return store }