diff --git a/synapse/config/server.py b/synapse/config/server.py
index 2d169ef5ca..0844475b15 100644
--- a/synapse/config/server.py
+++ b/synapse/config/server.py
@@ -43,12 +43,6 @@ from ._util import validate_config
logger = logging.Logger(__name__)
-DIRECT_TCP_ERROR = """
-Using direct TCP replication for workers is no longer supported.
-
-Please see https://element-hq.github.io/synapse/latest/upgrade.html#direct-tcp-replication-is-no-longer-supported-migrate-to-redis
-"""
-
# by default, we attempt to listen on both '::' *and* '0.0.0.0' because some OSes
# (Windows, macOS, other BSD/Linux where net.ipv6.bindv6only is set) will only listen
# on IPv6 when '::' is set.
@@ -903,9 +897,6 @@ def parse_listener_def(num: int, listener: Any) -> ListenerConfig:
raise ConfigError("Expected a dictionary", ("listeners", str(num)))
listener_type = listener["type"]
- # Raise a helpful error if direct TCP replication is still configured.
- if listener_type == "replication":
- raise ConfigError(DIRECT_TCP_ERROR, ("listeners", str(num), "type"))
port = listener.get("port")
socket_path = listener.get("path")
diff --git a/synapse/config/workers.py b/synapse/config/workers.py
index 2dfeb47c2e..1685468773 100644
--- a/synapse/config/workers.py
+++ b/synapse/config/workers.py
@@ -42,7 +42,6 @@ from synapse.config._base import (
)
from synapse.config._util import parse_and_validate_mapping
from synapse.config.server import (
- DIRECT_TCP_ERROR,
TCPListenerConfig,
parse_listener_def,
)
@@ -245,10 +244,6 @@ class WorkerConfig(Config):
raise ConfigError("worker_log_config must be a string")
self.worker_log_config = worker_log_config
- # The port on the main synapse for TCP replication
- if "worker_replication_port" in config:
- raise ConfigError(DIRECT_TCP_ERROR, ("worker_replication_port",))
-
# The shared secret used for authentication when connecting to the main synapse.
worker_replication_secret = config.get("worker_replication_secret", None)
if worker_replication_secret and not allow_secrets_in_config:
|