aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorseshukm <seshu.kumar.m@huawei.com>2018-08-20 21:32:51 +0800
committerSeshu Kumar M <seshu.kumar.m@huawei.com>2018-08-22 04:58:48 +0000
commiteb744cef4d81f9f88709d3ba8cdf81015b27106b (patch)
treef21f387348725b48aecdf041b461fc5f6895e458
parent591f278130ac54d136fad0c0256d2f50bdfb5f47 (diff)
call of the route app optmizer from osdfapp.py
Issue-ID: OPTFRA-310 Change-Id: I2b8512d89a1ea78f829d934f83931adf287e7fa9 Signed-off-by: seshukm <seshu.kumar.m@huawei.com>
-rwxr-xr-xosdfapp.py5
1 files changed, 4 insertions, 1 deletions
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)