Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Commit

Permalink
Merge pull request #1616 from matrix-org/erikj/worker_frozen_dict
Browse files Browse the repository at this point in the history
Respect use_frozen_dicts option in workers
  • Loading branch information
erikjohnston authored Nov 8, 2016
2 parents d24197b + 24772ba commit 34449cf
Show file tree
Hide file tree
Showing 6 changed files with 22 additions and 0 deletions.
4 changes: 4 additions & 0 deletions synapse/app/appservice.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@
from synapse.util.rlimit import change_resource_limit
from synapse.util.versionstring import get_version_string

from synapse import events

from twisted.internet import reactor, defer
from twisted.web.resource import Resource

Expand Down Expand Up @@ -151,6 +153,8 @@ def start(config_options):

setup_logging(config.worker_log_config, config.worker_log_file)

events.USE_FROZEN_DICTS = config.use_frozen_dicts

database_engine = create_engine(config.database_config)

if config.notify_appservices:
Expand Down
4 changes: 4 additions & 0 deletions synapse/app/client_reader.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@
from synapse.util.versionstring import get_version_string
from synapse.crypto import context_factory

from synapse import events


from twisted.internet import reactor, defer
from twisted.web.resource import Resource
Expand Down Expand Up @@ -165,6 +167,8 @@ def start(config_options):

setup_logging(config.worker_log_config, config.worker_log_file)

events.USE_FROZEN_DICTS = config.use_frozen_dicts

database_engine = create_engine(config.database_config)

tls_server_context_factory = context_factory.ServerContextFactory(config)
Expand Down
4 changes: 4 additions & 0 deletions synapse/app/federation_reader.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@
from synapse.federation.transport.server import TransportLayerServer
from synapse.crypto import context_factory

from synapse import events


from twisted.internet import reactor, defer
from twisted.web.resource import Resource
Expand Down Expand Up @@ -156,6 +158,8 @@ def start(config_options):

setup_logging(config.worker_log_config, config.worker_log_file)

events.USE_FROZEN_DICTS = config.use_frozen_dicts

database_engine = create_engine(config.database_config)

tls_server_context_factory = context_factory.ServerContextFactory(config)
Expand Down
4 changes: 4 additions & 0 deletions synapse/app/media_repository.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@
)
from synapse.crypto import context_factory

from synapse import events


from twisted.internet import reactor, defer
from twisted.web.resource import Resource
Expand Down Expand Up @@ -162,6 +164,8 @@ def start(config_options):

setup_logging(config.worker_log_config, config.worker_log_file)

events.USE_FROZEN_DICTS = config.use_frozen_dicts

database_engine = create_engine(config.database_config)

tls_server_context_factory = context_factory.ServerContextFactory(config)
Expand Down
4 changes: 4 additions & 0 deletions synapse/app/pusher.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@
from synapse.util.rlimit import change_resource_limit
from synapse.util.versionstring import get_version_string

from synapse import events

from twisted.internet import reactor, defer
from twisted.web.resource import Resource

Expand Down Expand Up @@ -239,6 +241,8 @@ def start(config_options):

setup_logging(config.worker_log_config, config.worker_log_file)

events.USE_FROZEN_DICTS = config.use_frozen_dicts

if config.start_pushers:
sys.stderr.write(
"\nThe pushers must be disabled in the main synapse process"
Expand Down
2 changes: 2 additions & 0 deletions synapse/app/synchrotron.py
Original file line number Diff line number Diff line change
Expand Up @@ -446,6 +446,8 @@ def start(config_options):

setup_logging(config.worker_log_config, config.worker_log_file)

synapse.events.USE_FROZEN_DICTS = config.use_frozen_dicts

database_engine = create_engine(config.database_config)

ss = SynchrotronServer(
Expand Down

0 comments on commit 34449cf

Please sign in to comment.