+ private boolean isUpdateNeeded(Port oldPort, Port newPort) {\r
+ //TODO fix this to better support update of ports for VPP\r
+ PortBindingExtension oldPortAugmentation = oldPort.getAugmentation(PortBindingExtension.class);\r
+ PortBindingExtension newPortAugmentation = newPort.getAugmentation(PortBindingExtension.class);\r
+\r
+ List<VifDetails> vifDetails = oldPortAugmentation.getVifDetails();\r
+\r
+ if (newPortAugmentation == null) {\r
+ LOG.trace("Port {} is no longer a vhost type port, updating port...");\r
+ return true;\r
+ }\r
+\r
+ if (!oldPortAugmentation.getHostId().equals(newPortAugmentation.getHostId()) ||\r
+ nullToEmpty(vifDetails).size() != nullToEmpty(newPortAugmentation.getVifDetails()).size()) {\r
+ return true;\r
+ }\r
+\r
+ for (VifDetails vifDetail : nullToEmpty(vifDetails)) {\r
+ //check if vhostuser_socket, vhostuser_mode and port_filter are changed\r
+ if (!newPortAugmentation.getVifDetails().contains(vifDetail))\r
+ return true;\r
+ }\r
+ return false;\r
+ }\r
+\r