Skip to content
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
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ synapse:
enabled: true
client-reader:
enabled: true
device-lists:
enabled: true
encryption:
enabled: true
event-creator:
Expand Down
2 changes: 2 additions & 0 deletions charts/matrix-stack/ci/synapse-worker-example-values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ synapse:
enabled: true
client-reader:
enabled: true
device-lists:
enabled: true
encryption:
enabled: true
event-creator:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,9 @@ We don't want MAS to change data in Synapse
*/}}
{{- if and .syn2mas.enabled .syn2mas.dryRun }}
kind: synapse_read_only
{{- else }}
{{- /* Switch to synapse_modern after a release or 2 so that we're more likely to have a Synapse that supports this API on redeploying MAS. */}}
kind: synapse_legacy
{{- end }}
{{- end }}

Expand Down
6 changes: 0 additions & 6 deletions charts/matrix-stack/configs/synapse/path_map_file_get.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,4 @@ workers instead if these requests path are under high load.
^/\_matrix/client/(api/v1|r0|v3|unstable)/presence/
*/}}
^/_matrix/client/unstable/org.matrix.msc4140/delayed_events client-reader
^/_matrix/client/(api/v1|r0|v3|unstable)/devices/ client-reader
{{- end }}
{{ if dig "sso-login" "enabled" false $root.Values.synapse.workers }}
{{- if (and $root.Values.matrixAuthenticationService.enabled (not $root.Values.matrixAuthenticationService.preMigrationSynapseHandlesAuth)) }}
^/_synapse/admin/v1/users/[^/]+/devices$ sso-login
{{- end }}
{{- end }}
3 changes: 3 additions & 0 deletions charts/matrix-stack/source/synapse.json
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,9 @@
"encryption": {
"$ref": "file://synapse/single_worker.json"
},
"device-lists": {
"$ref": "file://synapse/scalable_worker.json"
},
"event-creator": {
"$ref": "file://synapse/scalable_worker.json"
},
Expand Down
3 changes: 2 additions & 1 deletion charts/matrix-stack/source/synapse.yaml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ workers:
{{- synapse_sub_schema_values.single_worker('appservice') | indent(2) }}
{{- synapse_sub_schema_values.single_worker('background') | indent(2) }}
{{- synapse_sub_schema_values.scalable_worker('client-reader') | indent(2) }}
{{- synapse_sub_schema_values.scalable_worker('device-lists') | indent(2) }}
{{- synapse_sub_schema_values.single_worker('encryption') | indent(2) }}
{{- synapse_sub_schema_values.scalable_worker('event-creator') | indent(2) }}
{{- synapse_sub_schema_values.scalable_worker('event-persister') | indent(2) }}
Expand Down Expand Up @@ -83,7 +84,7 @@ logging:
## levelOverrides:
## synapse.util.caches.lrucache: WARNING
levelOverrides: {}
{{- sub_schema_values.image(registry='ghcr.io', repository='element-hq/synapse', tag='v1.134.0') }}
{{- sub_schema_values.image(registry='ghcr.io', repository='element-hq/synapse', tag='v1.135.0') }}
{{- sub_schema_values.ingress() }}
{{- sub_schema_values.labels() }}
{{- sub_schema_values.workloadAnnotations() }}
Expand Down
37 changes: 26 additions & 11 deletions charts/matrix-stack/templates/synapse/_synapse_details.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ SPDX-License-Identifier: AGPL-3.0-only
{{ $hasHttp := (list "main"
"account-data"
"client-reader"
"device-lists"
"encryption"
"event-creator"
"federation-inbound"
Expand All @@ -35,6 +36,7 @@ hasHttp
{{- with required "element-io.synapse.process.hasReplication missing context" .context -}}
{{- $hasReplication := (list "main"
"account-data"
"device-lists"
"encryption"
"event-persister"
"push-rules"
Expand Down Expand Up @@ -134,6 +136,8 @@ responsibleForMedia
{{- with required "element-io.synapse.process.streamWriters missing context" .context -}}
{{- if eq . "account-data" }}
{{ list "account_data" | toJson }}
{{- else if eq . "device-lists" }}
{{ list "device_lists" | toJson }}
{{- else if eq . "encryption" }}
{{ list "to_device" | toJson }}
{{- else if eq . "event-persister" }}
Expand Down Expand Up @@ -257,6 +261,7 @@ responsibleForMedia
"^/_matrix/client/unstable/im.nheko.summary/summary/.*$"
"^/_matrix/client/(r0|v3|unstable)/account/3pid$"
"^/_matrix/client/(r0|v3|unstable)/account/whoami$"
"^/_matrix/client/(r0|v3|unstable)/account/deactivate$"
"^/_matrix/client/(r0|v3|unstable)/devices$"
"^/_matrix/client/versions$"
"^/_matrix/client/(api/v1|r0|v3|unstable)/voip/turnServer$"
Expand Down Expand Up @@ -293,14 +298,23 @@ responsibleForMedia
{{ $workerPaths = concat $workerPaths (list
"^/_matrix/client/(r0|v3|unstable)/keys/claim$"
"^/_matrix/client/(r0|v3|unstable)/room_keys/"
) }}
{{- end }}
{{- if eq .workerType "device-lists" }}
{{ $workerPaths = concat $workerPaths (list
"^/_matrix/client/(r0|v3)/delete_devices$"
"^/_matrix/client/(api/v1|r0|v3|unstable)/devices(/|$)"
"^/_matrix/client/(r0|v3|unstable)/keys/upload"
"^/_matrix/client/(api/v1|r0|v3|unstable)/keys/device_signing/upload$"
"^/_matrix/client/(api/v1|r0|v3|unstable)/keys/signatures/upload$"
) }}
{{- end }}
{{- if eq .workerType "encryption" }}
{{ $workerPaths = append $workerPaths
{{ $workerPaths = concat $workerPaths (list
"^/_matrix/client/(r0|v3|unstable)/sendToDevice/"
}}
) }}
{{- end }}
{{- if eq .workerType "event-creator" }}
Expand Down Expand Up @@ -373,9 +387,9 @@ responsibleForMedia
{{- end }}
{{- if eq .workerType "presence-writer" }}
{{ $workerPaths = append $workerPaths
{{ $workerPaths = concat $workerPaths (list
"^/_matrix/client/(api/v1|r0|v3|unstable)/presence/"
}}
) }}
{{- end }}
{{- if eq .workerType "push-rules" }}
Expand All @@ -392,9 +406,9 @@ responsibleForMedia
{{- end }}
{{- if eq .workerType "sliding-sync" }}
{{ $workerPaths = append $workerPaths
{{ $workerPaths = concat $workerPaths (list
"^/_matrix/client/unstable/org.matrix.simplified_msc3575/.*"
}}
) }}
{{- end }}
{{- if eq .workerType "sso-login" }}
Expand All @@ -408,11 +422,12 @@ responsibleForMedia
"^/_synapse/client/saml2/authn_response$"
"^/_matrix/client/(api/v1|r0|v3|unstable)/login/cas/ticket$"
) }}
{{- if (and $root.Values.matrixAuthenticationService.enabled (not $root.Values.matrixAuthenticationService.preMigrationSynapseHandlesAuth)) }}
{{- if include "element-io.matrix-authentication-service.readyToHandleAuth" (dict "root" $root) }}
{{ $workerPaths = concat $workerPaths (list
"^/_synapse/admin/v2/users/[^/]+$"
"^/_synapse/admin/v1/username_available$"
"^/_synapse/admin/v1/users/[^/]+/_allow_cross_signing_replacement_without_uia$"
"^/_synapse/admin/v1/users/[^/]+/devices$"
) }}
{{- end }}
{{- end }}
Expand All @@ -428,15 +443,15 @@ responsibleForMedia
{{- end }}
{{- if eq .workerType "typing-persister" }}
{{ $workerPaths = append $workerPaths
{{ $workerPaths = concat $workerPaths (list
"^/_matrix/client/(api/v1|r0|v3|unstable)/rooms/.*/typing"
}}
) }}
{{- end }}
{{- if eq .workerType "user-dir" }}
{{ $workerPaths = append $workerPaths
{{ $workerPaths = concat $workerPaths (list
"^/_matrix/client/(r0|v3|unstable)/user_directory/search$"
}}
) }}
{{- end }}
{{ $workerPaths | toJson }}
{{- end }}
Expand Down
Loading
Loading