From a42d0d03016a3101d64271ad02d3733102b92f16 Mon Sep 17 00:00:00 2001 From: elajkat Date: Fri, 22 May 2020 17:01:28 +0200 Subject: [PATCH] Trivial: Change Health-check from filter to app_factory [1] added healthcheck url to neutron API, but in review it was noted that the used filter_factory is deprecated and app_factory is the suggested instead, as Akihiro commented in [1], in [2] filter is marked for removal. [1]: https://review.opendev.org/724676 [2]: https://opendev.org/openstack/oslo.middleware/src/branch/master/oslo_middleware/healthcheck/__init__.py#L409 Change-Id: I28c26d3357c21483b7642958564d675cd5feaa31 --- etc/api-paste.ini | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/etc/api-paste.ini b/etc/api-paste.ini index f31f6486de2..bfba30f5695 100644 --- a/etc/api-paste.ini +++ b/etc/api-paste.ini @@ -1,17 +1,18 @@ [composite:neutron] use = egg:Paste#urlmap /: neutronversions_composite +/healthcheck: healthcheck /v2.0: neutronapi_v2_0 [composite:neutronapi_v2_0] use = call:neutron.auth:pipeline_factory -noauth = healthcheck cors http_proxy_to_wsgi request_id catch_errors osprofiler extensions neutronapiapp_v2_0 -keystone = healthcheck cors http_proxy_to_wsgi request_id catch_errors osprofiler authtoken keystonecontext extensions neutronapiapp_v2_0 +noauth = cors http_proxy_to_wsgi request_id catch_errors osprofiler extensions neutronapiapp_v2_0 +keystone = cors http_proxy_to_wsgi request_id catch_errors osprofiler authtoken keystonecontext extensions neutronapiapp_v2_0 [composite:neutronversions_composite] use = call:neutron.auth:pipeline_factory -noauth = healthcheck cors http_proxy_to_wsgi neutronversions -keystone = healthcheck cors http_proxy_to_wsgi neutronversions +noauth = cors http_proxy_to_wsgi neutronversions +keystone = cors http_proxy_to_wsgi neutronversions [filter:request_id] paste.filter_factory = oslo_middleware:RequestId.factory @@ -44,5 +45,7 @@ paste.app_factory = neutron.api.v2.router:APIRouter.factory [filter:osprofiler] paste.filter_factory = osprofiler.web:WsgiMiddleware.factory -[filter:healthcheck] -paste.filter_factory = oslo_middleware:Healthcheck.factory +[app:healthcheck] +paste.app_factory = oslo_middleware:Healthcheck.app_factory +backends = disable_by_file +disable_by_file_path = /var/lib/neutron/healthcheck_disable