From 9b85da5f36a6dac9264ac65292de1b0c72c30ff8 Mon Sep 17 00:00:00 2001 From: Nikolay Stanchev <ns17@it-innovation.soton.ac.uk> Date: Tue, 29 May 2018 11:45:51 +0100 Subject: [PATCH] Updated routing in the pyramid configuration --- src/clmc-webservice/clmcservice/__init__.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/clmc-webservice/clmcservice/__init__.py b/src/clmc-webservice/clmcservice/__init__.py index 3dbd815..4cb9f81 100644 --- a/src/clmc-webservice/clmcservice/__init__.py +++ b/src/clmc-webservice/clmcservice/__init__.py @@ -24,7 +24,6 @@ from pyramid.config import Configurator from pyramid.settings import asbool -from clmcservice.views import AggregatorConfig, AggregatorController from clmcservice.utilities import RUNNING_FLAG, MALFORMED_FLAG @@ -45,12 +44,12 @@ def main(global_config, **settings): config = Configurator(settings=settings) config.add_route('aggregator_config', '/aggregator/config') - config.add_view(AggregatorConfig, attr='get', request_method='GET') - config.add_view(AggregatorConfig, attr='put', request_method='PUT') + config.add_view('clmcservice.views.AggregatorConfig', attr='get', request_method='GET') + config.add_view('clmcservice.views.AggregatorConfig', attr='put', request_method='PUT') config.add_route('aggregator_controller', '/aggregator/control') - config.add_view(AggregatorController, attr='get', request_method='GET') - config.add_view(AggregatorController, attr='put', request_method='PUT') + config.add_view('clmcservice.views.AggregatorController', attr='get', request_method='GET') + config.add_view('clmcservice.views.AggregatorController', attr='put', request_method='PUT') config.scan() return config.make_wsgi_app() -- GitLab