File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -149,6 +149,7 @@ def get_info(self):
149
149
verify = False ,
150
150
timeout = 1
151
151
)
152
+ logger .trace (state )
152
153
if state .status_code == 200 :
153
154
if state .json ()['APIConnectGatewayService' ].get ('V5CompatibilityMode' , 'off' ) == 'on' :
154
155
self .v5c = True
@@ -283,10 +284,10 @@ def fetch_document_cache_summary(self, suffix=''):
283
284
""" fetch data from a status provider """
284
285
if self .v5c :
285
286
provider = "DocumentCachingSummary"
286
- key = "XMLManager"
287
+ status_key = "XMLManager"
287
288
else :
288
289
provider = "APIDocumentCachingSummary"
289
- key = "APIGateway"
290
+ status_key = "APIGateway"
290
291
try :
291
292
logger .debug ("Retrieving cache summary" )
292
293
url = "https://{}:{}/mgmt/status/{}/{}" .format (
@@ -301,12 +302,11 @@ def fetch_document_cache_summary(self, suffix=''):
301
302
data = status .get (provider , {})
302
303
if type (data ) is not list :
303
304
data = [data ]
304
-
305
305
for item in data :
306
306
try :
307
- name = item [key ]['value' ]
307
+ name = item [status_key ]['value' ]
308
308
if name in ['webapi' , 'webapi-internal' , 'apiconnect' ]:
309
- del item [key ]
309
+ del item [status_key ]
310
310
logger .debug (item )
311
311
for key in item :
312
312
self .trawler .set_gauge (
You can’t perform that action at this time.
0 commit comments