From: Shankaranarayanan Puzhavakath Narayanan Date: Tue, 28 Aug 2018 15:16:33 +0000 (+0000) Subject: Merge "call of the route app optmizer from osdfapp.py" X-Git-Tag: 1.2.1~5 X-Git-Url: https://gerrit.onap.org/r/gitweb?a=commitdiff_plain;h=e245dcdb2419299dc2388f66acb5c93f4df69b5c;hp=b10fb0f89dd06023ebc8d318813a49b57bda81a7;p=optf%2Fosdf.git Merge "call of the route app optmizer from osdfapp.py" --- diff --git a/osdfapp.py b/osdfapp.py index b1dde44..bd5efa7 100755 --- a/osdfapp.py +++ b/osdfapp.py @@ -46,6 +46,7 @@ from schematics.exceptions import DataError from osdf.logging.osdf_logging import MH, audit_log, error_log, debug_log from osdf.models.api.placementRequest import PlacementAPI from osdf.operation.responses import osdf_response_for_request_accept as req_accept +from osdf.optimizers.routeopt.simple_route_opt import RouteOpt ERROR_TEMPLATE = osdf.ERROR_TEMPLATE @@ -129,7 +130,9 @@ def do_route_calc(): """Perform the basic route calculations and returnn the vpn-bindings TODO:Need to add the new class for the route in the API and model to provide this function """ - return "OK" + request_json = request.get_json() + audit_log.info("Calculate Route request received!") + return RouteOpt.getRoute(request_json) @app.errorhandler(500)