X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=sfa%2Fmanagers%2Faggregate_manager_vini.py;h=d961443590d024c3c453ff3307443f3a077007cf;hb=5307e4e09dd0a7982f0c6dfdd13065425c802005;hp=b1a7044ec8b3f596d2aa16ad8608a7bc0c7329c6;hpb=4ff67c801ceeb1d0c7ca2863c2b7bf8152182b8f;p=sfa.git diff --git a/sfa/managers/aggregate_manager_vini.py b/sfa/managers/aggregate_manager_vini.py index b1a7044e..d9614435 100644 --- a/sfa/managers/aggregate_manager_vini.py +++ b/sfa/managers/aggregate_manager_vini.py @@ -36,8 +36,9 @@ def GetVersion(api): 'hrn':xrn.get_hrn(), }) -def delete_slice(api, xrn, creds): - hrn, type = urn_to_hrn(xrn) +def DeleteSliver(api, xrn, creds, call_id): + if Callids().already_handled(call_id): return "" + (hrn, type) = urn_to_hrn(xrn) slicename = hrn_to_pl_slicename(hrn) slices = api.plshell.GetSlices(api.plauth, {'name': slicename}) if not slices: @@ -52,7 +53,7 @@ def CreateSliver(api, xrn, creds, xml, users, call_id): Verify HRN and initialize the slice record in PLC if necessary. """ - if Callids().already_handled(call_id): return False + if Callids().already_handled(call_id): return "" hrn, type = urn_to_hrn(xrn) peer = None @@ -87,9 +88,8 @@ def CreateSliver(api, xrn, creds, xml, users, call_id): api.plshell.DeleteSliceFromNodes(api.plauth, slice.name, deleted_nodes) network.updateSliceTags() - # print network.toxml() - - return True + # xxx - check this holds enough data for the client to understand what's happened + return network.toxml() def ListResources(api, creds, options,call_id): if Callids().already_handled(call_id): return ""