@@ -139,7 +139,7 @@ def __init__(self, **kwargs):
139
139
dynamic_config = Dict ()
140
140
141
141
traefik_providers_throttle_duration = Unicode (
142
- "0s " ,
142
+ "0.1s " ,
143
143
config = True ,
144
144
help = """
145
145
throttle traefik reloads of configuration.
@@ -300,7 +300,9 @@ async def _check_for_traefik_service(self, routespec, kind):
300
300
json .loads (resp .body )
301
301
except HTTPClientError as e :
302
302
if e .code == 404 :
303
- self .log .debug (f"traefik { expected } not yet in { kind } " )
303
+ self .log .debug (
304
+ "Traefik route for %s: %s not yet in %s" , routespec , expected , kind
305
+ )
304
306
return False
305
307
self .log .exception (f"Error checking traefik api for { kind } { routespec } " )
306
308
return False
@@ -312,7 +314,7 @@ async def _check_for_traefik_service(self, routespec, kind):
312
314
return True
313
315
314
316
async def _wait_for_route (self , routespec ):
315
- self .log .debug ("Waiting for %s to register with traefik " , routespec )
317
+ self .log .debug ("Traefik route for %s: waiting to register" , routespec )
316
318
317
319
async def _check_traefik_dynamic_conf_ready ():
318
320
"""Check if traefik loaded its dynamic configuration yet"""
@@ -325,10 +327,11 @@ async def _check_traefik_dynamic_conf_ready():
325
327
326
328
await exponential_backoff (
327
329
_check_traefik_dynamic_conf_ready ,
328
- f"Traefik route for { routespec } configuration not available " ,
330
+ f"Traefik route for { routespec } : not ready " ,
329
331
scale_factor = 1.2 ,
330
332
timeout = self .check_route_timeout ,
331
333
)
334
+ self .log .debug ("Treafik route for %s: registered" , routespec )
332
335
333
336
async def _traefik_api_request (self , path ):
334
337
"""Make an API request to traefik"""
@@ -494,7 +497,6 @@ async def _setup_traefik_dynamic_config(self):
494
497
"middlewares" : {},
495
498
}
496
499
}
497
- dynamic_config ["http" ]
498
500
routers = dynamic_config ["http" ]["routers" ]
499
501
middlewares = dynamic_config ["http" ]["middlewares" ]
500
502
routers ["route_api" ] = {
0 commit comments