Fix context Deadlines by using a new context on each loop

master
René Jochum 2 years ago
parent d8df9f2429
commit 748cc2dac1
Signed by: jochum
GPG Key ID: F7D906F5E51E8E5E

@ -48,9 +48,9 @@ func (h *Handler) Init(service micro.Service, engine *gin.Engine, routerAuth aut
// Refresh routes for the proxy every 10 seconds
go func() {
ctx := context.Background()
for {
ctx := context.Background()
services, err := util.FindByEndpoint(h.service, "RouterClientService.Routes")
if err != nil {
ilogger.Logrus().Error(err)

Loading…
Cancel
Save