+ boolean isVersionChanged = isVersionChanged(entity, swVersion, hwVersion);\r
+ if (isVersionChanged) {\r
+ LOG.debug("software version changed, stopping the the existing netconf instance");\r
+ boolean result = this.ncServerStarter.stopServer(deviceId);\r
+ if (result) {\r
+ LOG.debug(\r
+ "successfully stopped the netconf instance; trying to start with new version yang models");\r
+ entity.setSwVersion(swVersion);\r
+ entity.setHwVersion(hwVersion);\r
+ netconfDAO.save(entity);\r
+\r
+ boolean isSuccess = startNetConfServerInstance(entity);\r
+\r
+ if (!isSuccess) {\r
+ try {\r
+ restartServersHandler.restart(entity);\r
+ } catch (RetryFailedException e) {\r
+ LOG.debug("");\r
+ }\r
+ }\r
+ }\r
+ }\r
+ return getNetConfServerDetails(deviceId, entity);\r