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

Replace federation_reader with generic_worker in docs #12457

Merged
merged 2 commits into from
Apr 14, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions changelog.d/12457.doc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Update worker documentation and replace old `federation_reader` with `generic_worker`.
10 changes: 5 additions & 5 deletions docs/systemd-with-workers/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,15 @@ See the folder [system](https://github.com/matrix-org/synapse/tree/develop/docs/
for the systemd unit files.

The folder [workers](https://github.com/matrix-org/synapse/tree/develop/docs/systemd-with-workers/workers/)
contains an example configuration for the `federation_reader` worker.
contains an example configuration for the `generic_worker` worker.

## Synapse configuration files

See [the worker documentation](../workers.md) for information on how to set up the
configuration files and reverse-proxy correctly.
Below is a sample `federation_reader` worker configuration file.
Below is a sample `generic_worker` worker configuration file.
```yaml
{{#include workers/federation_reader.yaml}}
{{#include workers/generic_worker.yaml}}
```

Systemd manages daemonization itself, so ensure that none of the configuration
Expand Down Expand Up @@ -61,9 +61,9 @@ systemctl stop matrix-synapse.target
# Restart the master alone
systemctl start matrix-synapse.service

# Restart a specific worker (eg. federation_reader); the master is
# Restart a specific worker (eg. generic_worker); the master is
# unaffected by this.
systemctl restart matrix-synapse-worker@federation_reader.service
systemctl restart matrix-synapse-worker@generic_worker.service

# Add a new worker (assuming all configs are set up already)
systemctl enable matrix-synapse-worker@federation_writer.service
Expand Down
13 changes: 0 additions & 13 deletions docs/systemd-with-workers/workers/federation_reader.yaml

This file was deleted.

13 changes: 13 additions & 0 deletions docs/systemd-with-workers/workers/generic_worker.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
worker_app: synapse.app.generic_worker
worker_name: generic_worker1

worker_replication_host: 127.0.0.1
worker_replication_http_port: 9093

worker_listeners:
- type: http
port: 8011
resources:
- names: [client, federation]

worker_log_config: /etc/matrix-synapse/generic-worker-log.yaml
10 changes: 4 additions & 6 deletions docs/workers.md
Original file line number Diff line number Diff line change
Expand Up @@ -146,12 +146,10 @@ worker_replication_host: 127.0.0.1
worker_replication_http_port: 9093

worker_listeners:
- type: http
port: 8083
resources:
- names:
- client
- federation
- type: http
port: 8083
resources:
- names: [client, federation]

worker_log_config: /home/matrix/synapse/config/worker1_log_config.yaml
```
Expand Down