diff --git a/synapse/config/tracer.py b/synapse/config/tracer.py
index ae68a3dd1a..c19270c6c5 100644
--- a/synapse/config/tracer.py
+++ b/synapse/config/tracer.py
@@ -15,7 +15,7 @@
from typing import Any, List, Set
from synapse.types import JsonDict
-from synapse.util.check_dependencies import DependencyException, check_requirements
+from synapse.util.check_dependencies import check_requirements
from ._base import Config, ConfigError
@@ -40,12 +40,7 @@ class TracerConfig(Config):
if not self.opentracer_enabled:
return
- try:
- check_requirements("opentracing")
- except DependencyException as e:
- raise ConfigError(
- e.message # noqa: B306, DependencyException.message is a property
- )
+ check_requirements("opentracing")
# The tracer is enabled so sanitize the config
@@ -67,53 +62,3 @@ class TracerConfig(Config):
("opentracing", "force_tracing_for_users", f"index {i}"),
)
self.force_tracing_for_users.add(u)
-
- def generate_config_section(cls, **kwargs: Any) -> str:
- return """\
- ## Opentracing ##
-
- # These settings enable opentracing, which implements distributed tracing.
- # This allows you to observe the causal chains of events across servers
- # including requests, key lookups etc., across any server running
- # synapse or any other other services which supports opentracing
- # (specifically those implemented with Jaeger).
- #
- opentracing:
- # tracing is disabled by default. Uncomment the following line to enable it.
- #
- #enabled: true
-
- # The list of homeservers we wish to send and receive span contexts and span baggage.
- # See https://matrix-org.github.io/synapse/latest/opentracing.html.
- #
- # This is a list of regexes which are matched against the server_name of the
- # homeserver.
- #
- # By default, it is empty, so no servers are matched.
- #
- #homeserver_whitelist:
- # - ".*"
-
- # A list of the matrix IDs of users whose requests will always be traced,
- # even if the tracing system would otherwise drop the traces due to
- # probabilistic sampling.
- #
- # By default, the list is empty.
- #
- #force_tracing_for_users:
- # - "@user1:server_name"
- # - "@user2:server_name"
-
- # Jaeger can be configured to sample traces at different rates.
- # All configuration options provided by Jaeger can be set here.
- # Jaeger's configuration is mostly related to trace sampling which
- # is documented here:
- # https://www.jaegertracing.io/docs/latest/sampling/.
- #
- #jaeger_config:
- # sampler:
- # type: const
- # param: 1
- # logging:
- # false
- """
|