diff options
author | Amber Brown <hawkowl@atleastfornow.net> | 2018-05-21 17:02:20 -0500 |
---|---|---|
committer | Amber Brown <hawkowl@atleastfornow.net> | 2018-05-21 17:02:20 -0500 |
commit | 02c1d29133a2ce3cdb5d1b23ec5edde49d813da9 (patch) | |
tree | 83db02dc5415cda7a0f7bb1d369861462c447b2b /synapse/app | |
parent | remove old metrics libs (diff) | |
download | synapse-02c1d29133a2ce3cdb5d1b23ec5edde49d813da9.tar.xz |
look at the Prometheus metrics instead
Diffstat (limited to '')
-rwxr-xr-x | synapse/app/homeserver.py | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/synapse/app/homeserver.py b/synapse/app/homeserver.py index 75f40fd5a4..6393804a86 100755 --- a/synapse/app/homeserver.py +++ b/synapse/app/homeserver.py @@ -34,8 +34,7 @@ from synapse.module_api import ModuleApi from synapse.http.additional_resource import AdditionalResource from synapse.http.server import RootRedirect from synapse.http.site import SynapseSite -from synapse.metrics import register_memory_metrics -from synapse.metrics.resource import METRICS_PREFIX, MetricsResource +from synapse.metrics.resource import METRICS_PREFIX from synapse.python_dependencies import CONDITIONAL_REQUIREMENTS, \ check_requirements from synapse.replication.http import ReplicationRestResource, REPLICATION_PREFIX @@ -221,7 +220,8 @@ class SynapseHomeServer(HomeServer): resources[WEB_CLIENT_PREFIX] = build_resource_for_web_client(self) if name == "metrics" and self.get_config().enable_metrics: - resources[METRICS_PREFIX] = MetricsResource(self) + from prometheus_client.twisted import MetricsResource + resources[METRICS_PREFIX] = MetricsResource() if name == "replication": resources[REPLICATION_PREFIX] = ReplicationRestResource(self) @@ -353,8 +353,6 @@ def setup(config_options): hs.get_datastore().start_doing_background_updates() hs.get_federation_client().start_get_pdu_cache() - register_memory_metrics(hs) - reactor.callWhenRunning(start) return hs |