Merge pull request #3382 from matrix-org/rav/optimise_state_groups

Optimise state_group_cache update
This commit is contained in:
Richard van der Hoff 2018-06-22 11:20:20 +01:00 committed by GitHub
commit 240f192523
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -567,11 +567,7 @@ class StateGroupWorkerStore(SQLBaseStore):
# from the database.
for group, group_state_dict in iteritems(group_to_state_dict):
state_dict = results[group]
state_dict.update(
((intern_string(k[0]), intern_string(k[1])), to_ascii(v))
for k, v in iteritems(group_state_dict)
)
state_dict.update(group_state_dict)
self._state_group_cache.update(
cache_seq_num,