element-hq / element-hq/synapse
Python entrypoints vs `worker_app` are very confusing
- Dominant language
- Python
- Stars
- 4.6k
- Forks
- 600
- Avg merge
- 5d 22h
- Merged PRs (30d)
- 51
Description
This issue has been migrated from [#13644](https://github.com/matrix-org/synapse/issues/13644).
---
We define various "application worker types", such as `synapse.app.generic_worker` and `synapse.app.federation_sender`. Which you get is determined by the `worker_app` configuration setting.
However, for historical reasons, we also have a bunch of entrypoints with matching names: `python -m synapse.app.generic_worker` or `python -m synapse.app.federation_sender`. **These all do the same thing**, but the fact that they exist, and have the same names as the workers, makes the interaction very confusing. We don't make it clear which entrypoint you should use. Possibly we could recommend `synapse.app.generic_worker`, but that's still confusing.
I think the easiest way out of it is to create a new entrypoint - `synapse.app.worker`, maybe - which is yet another copy of the existing entrypoints. Then we can deprecate the old names.
Contributor guide
Assessment
This issue has not been assessed yet.