@Override
    public void updateNode(OpenstackNode osNode) {
        checkNotNull(osNode, ERR_NULL_NODE);

        OpenstackNode updatedNode;

        OpenstackNode existingNode = osNodeStore.node(osNode.hostname());
        checkNotNull(existingNode, ERR_NULL_NODE);

        DeviceId existDeviceId = osNodeStore.node(osNode.hostname()).intgBridge();

        if (vlanIntfChanged(existingNode, osNode) ||
                physicalIntfChanged(existingNode, osNode) ||
                dpdkIntfChanged(existingNode, osNode)) {

            removeNode(osNode.hostname());

            //we wait 1 second for ovsdb client completely to do removal job
            try {
                TimeUnit.MILLISECONDS.sleep(1000);
            } catch (InterruptedException e) {
                log.error("Exception occurred because of {}", e);
            }

            if (!intfsRemovedFromExistNode(existingNode)) {
                log.error("Updated node failed because intfs of existingNode {} " +
                                "are not removed properly", existingNode.toString());
                return;
            }

            createNode(osNode);
            return;
        }

        if (osNode.intgBridge() == null && osNode.type() != CONTROLLER) {
            updatedNode = osNode.updateIntbridge(existDeviceId);
            checkArgument(!hasIntgBridge(updatedNode.intgBridge(), updatedNode.hostname()),
                    NOT_DUPLICATED_MSG, updatedNode.intgBridge());
        } else {
            updatedNode = osNode;
            checkArgument(!hasIntgBridge(updatedNode.intgBridge(), updatedNode.hostname()),
                    NOT_DUPLICATED_MSG, updatedNode.intgBridge());
        }

        osNodeStore.updateNode(updatedNode);

        log.info(String.format(MSG_NODE, osNode.hostname(), MSG_UPDATED));
    }
@Test(expected = NullPointerException.class)
    public void testUpdateNotExistingNode() {
        target.updateNode(COMPUTE_1);
    }