mirror of
https://git.anonymousland.org/anonymousland/synapse-product.git
synced 2024-10-01 08:25:44 -04:00
5c705f70c9
First of all, fix the logic which looks for identical input state groups so that we actually use them. This turned out to be most easily done by factoring the relevant code out to a separate function so that we could do an early return. Secondly, avoid building the whole `conflicted_state` dict (which was only ever used as a boolean flag). Thirdly, replace the construction of the `state` dict (which mapped from keys to events that set them), with an optimistic construction of the resolution result assuming there will be no conflicts. This should be no slower than building the old `state` dict, and: - in the conflicted case, we'll short-cut it, saving part of the work - in the unconflicted case, it saves rebuilding the resolution from the `state` dict. Finally, do a couple of s/values/itervalues/. |
||
---|---|---|
.. | ||
api | ||
app | ||
appservice | ||
config | ||
crypto | ||
events | ||
federation | ||
groups | ||
handlers | ||
http | ||
metrics | ||
module_api | ||
push | ||
replication | ||
rest | ||
server_notices | ||
static/client | ||
storage | ||
streams | ||
util | ||
__init__.py | ||
event_auth.py | ||
notifier.py | ||
python_dependencies.py | ||
secrets.py | ||
server.py | ||
server.pyi | ||
state.py | ||
types.py | ||
visibility.py |