MCPcopy Create free account
hub / github.com/apache/impala / print_metrics

Function print_metrics

tests/run-tests.py:245–257  ·  view source on GitHub ↗

Prints metrics with the given substring in the name

(substring)

Source from the content-addressed store, hash-verified

243
244
245def print_metrics(substring):
246 """Prints metrics with the given substring in the name"""
247 for impalad in ImpalaCluster.get_e2e_test_cluster().impalads:
248 print(">" * 80)
249 port = impalad.get_webserver_port()
250 cert = impalad._get_webserver_certificate_file()
251 print("connections metrics for impalad at port {0}:".format(port))
252 debug_info = json.loads(ImpaladService(impalad.hostname, webserver_port=port,
253 webserver_certificate_file=cert).read_debug_webpage('metrics?json'))
254 for metric in debug_info['metric_group']['metrics']:
255 if substring in metric['name']:
256 print(json.dumps(metric, indent=1))
257 print("<" * 80)
258
259
260def detect_and_remove_flag(flag):

Callers 1

run-tests.pyFile · 0.85

Calls 6

ImpaladServiceClass · 0.90
get_e2e_test_clusterMethod · 0.80
get_webserver_portMethod · 0.80
read_debug_webpageMethod · 0.80
formatMethod · 0.45

Tested by

no test coverage detected