This repository was archived by the owner on Apr 26, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +6
-11
lines changed Expand file tree Collapse file tree 2 files changed +6
-11
lines changed Original file line number Diff line number Diff line change 9
9
{% if using_unix_sockets %}
10
10
path: /tmp/redis.sock
11
11
{% endif %}
12
+
13
+ outbound_federation_restricted_to:
14
+ - federation_sender1
12
15
{% endif %}
13
16
14
17
{% if appservice_registrations is not none %}
Original file line number Diff line number Diff line change 136
136
},
137
137
"federation_sender" : {
138
138
"app" : "synapse.app.generic_worker" ,
139
- "listener_resources" : [],
139
+ "listener_resources" : ["replication" ],
140
140
"endpoint_patterns" : [],
141
141
"shared_extra_conf" : {},
142
142
"worker_extra_conf" : "" ,
@@ -409,16 +409,6 @@ def add_worker_roles_to_shared_config(
409
409
worker_name
410
410
)
411
411
412
- # Map of stream writer instance names to host/ports combos
413
- if os .environ .get ("SYNAPSE_USE_UNIX_SOCKET" , False ):
414
- instance_map [worker_name ] = {
415
- "path" : f"/run/worker.{ worker_port } " ,
416
- }
417
- else :
418
- instance_map [worker_name ] = {
419
- "host" : "localhost" ,
420
- "port" : worker_port ,
421
- }
422
412
# Update the list of stream writers. It's convenient that the name of the worker
423
413
# type is the same as the stream to write. Iterate over the whole list in case there
424
414
# is more than one.
@@ -428,6 +418,8 @@ def add_worker_roles_to_shared_config(
428
418
worker , []
429
419
).append (worker_name )
430
420
421
+ # Force adding a replication listener if a worker type is defined as having one
422
+ if "replication" in WORKERS_CONFIG [worker ].get ("listener_resources" , []):
431
423
# Map of stream writer instance names to host/ports combos
432
424
# For now, all stream writers need http replication ports
433
425
if os .environ .get ("SYNAPSE_USE_UNIX_SOCKET" , False ):
You can’t perform that action at this time.
0 commit comments