- # DeleteSlice shall be handled before the actual method call;
- # after the call we won't be able to acess the slice.
- if api_method_name == "DeleteSlice":
- slice_name_or_id = args[1]
- else: # ignore the rest
- return
-
- slice = self.get_slice(wobj.api, slice_name_or_id)
- if not slice:
- return
-
- if api_method_name == "DeleteSlice":
- self.delete_slice(slice['name'])
-
- self.logit(wobj.name, args, kwargs, data, slice)
-
- # aspect method
- def after(self, wobj, data, *args, **kwargs):
- api_method_name = wobj.name
- slice_name_or_id = None
- node_ids = None