in postgresql_metrics/metrics_gatherer.py [0:0]
def get_stats_heap_hit_statistics(_data_dir, db_connection):
db_name, heap_read, heap_hit, heap_hit_ratio = get_heap_hit_statistics(db_connection)
metrics = []
if heap_hit_ratio is not None:
metrics.append(metric_blocks_read_from_disk(db_name, heap_read))
metrics.append(metric_blocks_read_from_buffer(db_name, heap_hit))
metrics.append(metric_blocks_heap_hit_ratio(db_name, heap_hit_ratio))
return metrics