- ServicePathOutput output = this.deviceRenderer.setupServicePath(this.servicePathInputData.getServicePathInput(),
- this.direction);
- if (!output.isSuccess()) {
- LOG.warn("Device rendering not successfully finished.");
+ ServicePathOutput output;
+ String operation;
+ List<Nodes> olmList = null;
+ switch (this.servicePathInputData.getServicePathInput().getOperation()) {
+ case Create:
+ operation = "setup";
+ output = this.deviceRenderer.setupServicePath(this.servicePathInputData.getServicePathInput(),
+ this.direction);
+ olmList = this.servicePathInputData.getNodeLists().getOlmNodeList();
+ break;
+ case Delete:
+ operation = "delete";
+ output = this.deviceRenderer.deleteServicePath(this.servicePathInputData.getServicePathInput());
+ break;
+ default:
+ return DeviceRenderingResult.failed("Device rendering failed - unknown operation");
+ }
+ if (!output.getSuccess()) {
+ LOG.error("Device rendering {} service path failed.", operation);