|
82 | 82 | MAIN_PROCESS_UNIX_SOCKET_PRIVATE_PATH = "/run/main_private.sock" |
83 | 83 |
|
84 | 84 |
|
85 | | -# Workers with exposed endpoints needs either "client", "federation", or "media" listener_resources |
86 | | -# Watching /_matrix/client needs a "client" listener |
87 | | -# Watching /_matrix/federation needs a "federation" listener |
88 | | -# Watching /_matrix/media and related needs a "media" listener |
89 | | -# Stream Writers require "client" and "replication" listeners because they |
90 | | -# have to attach by instance_map to the master process and have client endpoints. |
91 | 85 | @dataclass |
92 | 86 | class WorkerTemplate: |
93 | 87 | listener_resources: Set[str] = field(default_factory=set) |
94 | 88 | endpoint_patterns: Set[str] = field(default_factory=set) |
95 | | - # (worker_name) -> {} |
| 89 | + # (worker_name) -> {config} |
96 | 90 | shared_extra_conf: Callable[[str], Dict[str, Any]] = lambda _worker_name: {} |
97 | 91 | worker_extra_conf: str = "" |
98 | 92 |
|
99 | 93 |
|
| 94 | +# Workers with exposed endpoints needs either "client", "federation", or "media" listener_resources |
| 95 | +# Watching /_matrix/client needs a "client" listener |
| 96 | +# Watching /_matrix/federation needs a "federation" listener |
| 97 | +# Watching /_matrix/media and related needs a "media" listener |
| 98 | +# Stream Writers require "client" and "replication" listeners because they |
| 99 | +# have to attach by instance_map to the master process and have client endpoints. |
100 | 100 | WORKERS_CONFIG: Dict[str, WorkerTemplate] = { |
101 | 101 | "pusher": WorkerTemplate(), |
102 | 102 | "user_dir": WorkerTemplate( |
|
0 commit comments