Loading src/device/service/drivers/oc_driver/templates/VPN/physical.py +7 −0 Original line number Diff line number Diff line Loading @@ -61,6 +61,13 @@ def create_optical_channel(resources): with tag('config'): for resource in config: with tag(resource['resource_key']):text(resource['value']) with tag('terminal-device', xmlns="http://openconfig.net/yang/terminal-device"): with tag('logical-channels'): with tag('channel'): with tag('index'):text("{}".format(port_val)) with tag('config'): with tag('index'):text("{}".format(port_val)) with tag('admin-state'):text("ENABLED") result = indent( doc.getvalue(), indentation = ' '*2, Loading src/opticalcontroller/OpticalController.py +2 −2 Original line number Diff line number Diff line Loading @@ -113,7 +113,7 @@ class DelFLightpath(Resource): # rsa.optical_bands[rev_ob_id]["served_lightpaths"].remove(flow_id) if debug: print(links_dict) print(rsa.links_dict) return "flow {} deleted".format(flow_id), 200 else: return "flow {} not matching".format(flow_id), 404 Loading Loading @@ -147,7 +147,7 @@ class DelLightpath(Resource): rsa.del_flow(flow) rsa.db_flows[flow_id]["is_active"] = False if debug: print(links_dict) print(rsa.links_dict) return "flow {} deleted".format(flow_id), 200 else: return "flow {} not matching".format(flow_id), 404 Loading Loading
src/device/service/drivers/oc_driver/templates/VPN/physical.py +7 −0 Original line number Diff line number Diff line Loading @@ -61,6 +61,13 @@ def create_optical_channel(resources): with tag('config'): for resource in config: with tag(resource['resource_key']):text(resource['value']) with tag('terminal-device', xmlns="http://openconfig.net/yang/terminal-device"): with tag('logical-channels'): with tag('channel'): with tag('index'):text("{}".format(port_val)) with tag('config'): with tag('index'):text("{}".format(port_val)) with tag('admin-state'):text("ENABLED") result = indent( doc.getvalue(), indentation = ' '*2, Loading
src/opticalcontroller/OpticalController.py +2 −2 Original line number Diff line number Diff line Loading @@ -113,7 +113,7 @@ class DelFLightpath(Resource): # rsa.optical_bands[rev_ob_id]["served_lightpaths"].remove(flow_id) if debug: print(links_dict) print(rsa.links_dict) return "flow {} deleted".format(flow_id), 200 else: return "flow {} not matching".format(flow_id), 404 Loading Loading @@ -147,7 +147,7 @@ class DelLightpath(Resource): rsa.del_flow(flow) rsa.db_flows[flow_id]["is_active"] = False if debug: print(links_dict) print(rsa.links_dict) return "flow {} deleted".format(flow_id), 200 else: return "flow {} not matching".format(flow_id), 404 Loading