File tree 1 file changed +3
-3
lines changed
1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -174,7 +174,7 @@ def get_multixact_members_per_mxid(data_dir, db_connection):
174
174
175
175
def get_multixact_members_usage_ratio (data_dir , _db_connection ):
176
176
members = _get_multixact_members (data_dir )
177
- ratio = members // MAX_MULTIXACT_MEMBERS
177
+ ratio = round ( members / MAX_MULTIXACT_MEMBERS , 2 )
178
178
percentage_remaining = (1.0 - ratio ) * 100
179
179
return [metric_multixact_members_remaining_ratio (percentage_remaining )]
180
180
@@ -183,7 +183,7 @@ def get_multixact_remaining_ratio(_data_dir, db_connection):
183
183
mxid_age = get_max_mxid_age (db_connection )
184
184
if not mxid_age :
185
185
return []
186
- ratio = mxid_age // WRAPAROUND_LIMIT
186
+ ratio = round ( mxid_age / WRAPAROUND_LIMIT , 2 )
187
187
percentage_remaining = (1.0 - ratio ) * 100
188
188
return [metric_multixact_remaining_ratio (percentage_remaining )]
189
189
@@ -192,7 +192,7 @@ def get_xid_remaining_ratio(_data_dir, db_connection):
192
192
xid_age = get_max_xid_age (db_connection )
193
193
if not xid_age :
194
194
return []
195
- ratio = xid_age // WRAPAROUND_LIMIT
195
+ ratio = round ( xid_age / WRAPAROUND_LIMIT , 2 )
196
196
percentage_remaining = (1.0 - ratio ) * 100
197
197
return [metric_xid_remaining_ratio (percentage_remaining )]
198
198
You can’t perform that action at this time.
0 commit comments