Skip to content

Commit

Permalink
[REVERT THIS] Hardwire testing the proxy agent into Complement tempor…
Browse files Browse the repository at this point in the history
…arily
  • Loading branch information
realtyem committed Jul 6, 2023
1 parent cd1579b commit 4f079d8
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 11 deletions.
3 changes: 3 additions & 0 deletions docker/conf-workers/shared.yaml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ redis:
{% if using_unix_sockets %}
path: /tmp/redis.sock
{% endif %}

outbound_federation_restricted_to:
- federation_sender1
{% endif %}

{% if appservice_registrations is not none %}
Expand Down
14 changes: 3 additions & 11 deletions docker/configure_workers_and_start.py
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@
},
"federation_sender": {
"app": "synapse.app.generic_worker",
"listener_resources": [],
"listener_resources": ["replication"],
"endpoint_patterns": [],
"shared_extra_conf": {},
"worker_extra_conf": "",
Expand Down Expand Up @@ -409,16 +409,6 @@ def add_worker_roles_to_shared_config(
worker_name
)

# Map of stream writer instance names to host/ports combos
if os.environ.get("SYNAPSE_USE_UNIX_SOCKET", False):
instance_map[worker_name] = {
"path": f"/run/worker.{worker_port}",
}
else:
instance_map[worker_name] = {
"host": "localhost",
"port": worker_port,
}
# Update the list of stream writers. It's convenient that the name of the worker
# type is the same as the stream to write. Iterate over the whole list in case there
# is more than one.
Expand All @@ -428,6 +418,8 @@ def add_worker_roles_to_shared_config(
worker, []
).append(worker_name)

# Force adding a replication listener if a worker type is defined as having one
if "replication" in WORKERS_CONFIG[worker].get("listener_resources", []):
# Map of stream writer instance names to host/ports combos
# For now, all stream writers need http replication ports
if os.environ.get("SYNAPSE_USE_UNIX_SOCKET", False):
Expand Down

0 comments on commit 4f079d8

Please sign in to comment.