@Override public void onDataTreeChanged( final Collection<DataTreeModification<KafkaProducerConfig>> changed) { if (LOG.isDebugEnabled()) { LOG.debug("in onDataTreeChanged()"); } DataTreeModification<KafkaProducerConfig> changedConfig = changed.iterator().next(); KafkaProducerConfig config = changedConfig.getRootNode().getDataAfter(); createOrReset(config); }
@Override public void onDataTreeChanged(@Nonnull final Collection<DataTreeModification<Node>> changes) { for (final DataTreeModification<Node> change : changes) { final DataObjectModification<Node> rootNode = change.getRootNode(); final NodeId nodeId = NetconfTopologyUtils.getNodeId(rootNode.getIdentifier()); switch (rootNode.getModificationType()) { case SUBTREE_MODIFIED: LOG.debug( "{}: Operational for node {} updated. Trying to register slave mount point", id, nodeId); handleSlaveMountPoint(rootNode); break; case WRITE: if (rootNode.getDataBefore() != null) { LOG.debug( "{}: Operational for node {} rewrited. Trying to register slave mount point", id, nodeId); } else { LOG.debug( "{}: Operational for node {} created. Trying to register slave mount point", id, nodeId); } handleSlaveMountPoint(rootNode); break; case DELETE: LOG.debug( "{}: Operational for node {} deleted. Trying to remove slave mount point", id, nodeId); closeActor(); break; default: LOG.debug("{}: Uknown operation for node: {}", id, nodeId); } } }