From 94463bf5fb76e1baa9409f8faf53055a68083209 Mon Sep 17 00:00:00 2001 From: "Olivier Wilkinson (reivilibre)" Date: Thu, 18 Jul 2019 13:25:35 +0100 Subject: Disuse `room_stats.state_events` (relates to #5690) since it is tricky to maintain and has no known use case (for now). Signed-off-by: Olivier Wilkinson (reivilibre) --- synapse/handlers/stats.py | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'synapse/handlers') diff --git a/synapse/handlers/stats.py b/synapse/handlers/stats.py index d3b1db4951..f595de1537 100644 --- a/synapse/handlers/stats.py +++ b/synapse/handlers/stats.py @@ -148,10 +148,6 @@ class StatsHandler(StateDeltasHandler): # quantise time to the nearest bucket now = (now // 1000 // self.stats_bucket_size) * self.stats_bucket_size - yield self.store.update_stats_delta( - now, "room", room_id, "state_events", +1 - ) - if prev_event_id is None: # this state event doesn't overwrite another, # so it is a new effective/current state event @@ -277,7 +273,9 @@ class StatsHandler(StateDeltasHandler): "invited_members": 0, "left_members": 0, "banned_members": 0, - "state_events": 1, + # this column is disused but not yet removed from the + # schema, so fill with -1. + "state_events": -1, }, ) -- cgit 1.4.1