summary refs log tree commit diff
diff options
context:
space:
mode:
authorNeil Johnson <neil@matrix.org>2018-05-29 17:47:55 +0100
committerNeil Johnson <neil@matrix.org>2018-05-29 17:47:55 +0100
commit558f3d376a5a6f111bfd277528a510c8157aa99c (patch)
treef7d8857b8fd2b6876463631614744dc987a2b590
parentbump version (diff)
downloadsynapse-558f3d376a5a6f111bfd277528a510c8157aa99c.tar.xz
create index in background
-rw-r--r--synapse/storage/registration.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/synapse/storage/registration.py b/synapse/storage/registration.py
index d8e60d2e87..c0bf5e9ed6 100644
--- a/synapse/storage/registration.py
+++ b/synapse/storage/registration.py
@@ -101,6 +101,13 @@ class RegistrationStore(RegistrationWorkerStore,
             columns=["user_id", "device_id"],
         )
 
+        self.register_background_index_update(
+            "users_creation_ts",
+            index_name="users_creation_ts",
+            table="users",
+            columns=["creation_ts"],
+        )
+
         # we no longer use refresh tokens, but it's possible that some people
         # might have a background update queued to build this index. Just
         # clear the background update.