Stabilize the threads API. (#14175)
Stabilize the threads API (MSC3856) by supporting (only) the v1
path for the endpoint.
This also marks the API as safe for workers since it is a read-only
API.
2 files changed, 2 insertions, 10 deletions
diff --git a/synapse/config/experimental.py b/synapse/config/experimental.py
index 1860006536..f44655516e 100644
--- a/synapse/config/experimental.py
+++ b/synapse/config/experimental.py
@@ -101,9 +101,6 @@ class ExperimentalConfig(Config):
# MSC3848: Introduce errcodes for specific event sending failures
self.msc3848_enabled: bool = experimental.get("msc3848_enabled", False)
- # MSC3856: Threads list API
- self.msc3856_enabled: bool = experimental.get("msc3856_enabled", False)
-
# MSC3852: Expose last seen user agent field on /_matrix/client/v3/devices.
self.msc3852_enabled: bool = experimental.get("msc3852_enabled", False)
diff --git a/synapse/rest/client/relations.py b/synapse/rest/client/relations.py
index d1aa1947a5..9dd59196d9 100644
--- a/synapse/rest/client/relations.py
+++ b/synapse/rest/client/relations.py
@@ -82,11 +82,7 @@ class RelationPaginationServlet(RestServlet):
class ThreadsServlet(RestServlet):
- PATTERNS = (
- re.compile(
- "^/_matrix/client/unstable/org.matrix.msc3856/rooms/(?P<room_id>[^/]*)/threads"
- ),
- )
+ PATTERNS = (re.compile("^/_matrix/client/v1/rooms/(?P<room_id>[^/]*)/threads"),)
def __init__(self, hs: "HomeServer"):
super().__init__()
@@ -126,5 +122,4 @@ class ThreadsServlet(RestServlet):
def register_servlets(hs: "HomeServer", http_server: HttpServer) -> None:
RelationPaginationServlet(hs).register(http_server)
- if hs.config.experimental.msc3856_enabled:
- ThreadsServlet(hs).register(http_server)
+ ThreadsServlet(hs).register(http_server)
|