summary refs log tree commit diff
path: root/synapse/metrics/process_collector.py
diff options
context:
space:
mode:
Diffstat (limited to 'synapse/metrics/process_collector.py')
-rw-r--r--synapse/metrics/process_collector.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/synapse/metrics/process_collector.py b/synapse/metrics/process_collector.py
index 6fec3de399..50e5b48a2b 100644
--- a/synapse/metrics/process_collector.py
+++ b/synapse/metrics/process_collector.py
@@ -15,6 +15,7 @@
 
 import os
 
+from six import iteritems
 
 TICKS_PER_SEC = 100
 BYTES_PER_PAGE = 4096
@@ -55,7 +56,7 @@ def update_resource_metrics():
             # line is PID (command) more stats go here ...
             raw_stats = line.split(") ", 1)[1].split(" ")
 
-            for (name, index) in STAT_FIELDS.iteritems():
+            for (name, index) in iteritems(STAT_FIELDS):
                 # subtract 3 from the index, because proc(5) is 1-based, and
                 # we've lost the first two fields in PID and COMMAND above
                 stats[name] = int(raw_stats[index - 3])