diff options
author | Amber Brown <hawkowl@atleastfornow.net> | 2018-08-10 23:50:21 +1000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-08-10 23:50:21 +1000 |
commit | b37c4724191995eec4f5bc9d64f176b2a315f777 (patch) | |
tree | 7f8e79c27d1993c4355844017b2d12a2f2bea656 /synapse/federation | |
parent | Merge pull request #3439 from vojeroen/send_sni_for_federation_requests (diff) | |
download | synapse-b37c4724191995eec4f5bc9d64f176b2a315f777.tar.xz |
Rename async to async_helpers because `async` is a keyword on Python 3.7 (#3678)
Diffstat (limited to 'synapse/federation')
-rw-r--r-- | synapse/federation/federation_server.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/synapse/federation/federation_server.py b/synapse/federation/federation_server.py index 2b62f687b6..a23136784a 100644 --- a/synapse/federation/federation_server.py +++ b/synapse/federation/federation_server.py @@ -40,7 +40,7 @@ from synapse.federation.persistence import TransactionActions from synapse.federation.units import Edu, Transaction from synapse.http.endpoint import parse_server_name from synapse.types import get_domain_from_id -from synapse.util import async +from synapse.util.async_helpers import Linearizer, concurrently_execute from synapse.util.caches.response_cache import ResponseCache from synapse.util.logutils import log_function @@ -67,8 +67,8 @@ class FederationServer(FederationBase): self.auth = hs.get_auth() self.handler = hs.get_handlers().federation_handler - self._server_linearizer = async.Linearizer("fed_server") - self._transaction_linearizer = async.Linearizer("fed_txn_handler") + self._server_linearizer = Linearizer("fed_server") + self._transaction_linearizer = Linearizer("fed_txn_handler") self.transaction_actions = TransactionActions(self.store) @@ -200,7 +200,7 @@ class FederationServer(FederationBase): event_id, f.getTraceback().rstrip(), ) - yield async.concurrently_execute( + yield concurrently_execute( process_pdus_for_room, pdus_by_room.keys(), TRANSACTION_CONCURRENCY_LIMIT, ) |