import static com.google.common.base.Verify.verifyNotNull;
import static java.util.Objects.requireNonNull;
+import com.google.common.base.VerifyException;
import java.util.ArrayDeque;
import java.util.ArrayList;
import java.util.Collection;
import java.util.Comparator;
import java.util.Deque;
+import org.eclipse.jdt.annotation.NonNull;
import org.eclipse.jdt.annotation.Nullable;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.controller.md.sal.remote.rev140114.data.changed.notification.DataChangeEvent;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.controller.md.sal.remote.rev140114.data.changed.notification.DataChangeEvent.Operation;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.controller.md.sal.remote.rev140114.data.changed.notification.data.change.event.Data;
import org.opendaylight.yangtools.yang.common.QName;
+import org.opendaylight.yangtools.yang.data.api.YangInstanceIdentifier.NodeIdentifier;
import org.opendaylight.yangtools.yang.data.api.YangInstanceIdentifier.NodeIdentifierWithPredicates;
import org.opendaylight.yangtools.yang.data.api.YangInstanceIdentifier.PathArgument;
import org.opendaylight.yangtools.yang.data.api.schema.LeafNode;
import org.opendaylight.yangtools.yang.data.impl.schema.ImmutableNodes;
import org.opendaylight.yangtools.yang.data.tree.api.DataTreeCandidate;
import org.opendaylight.yangtools.yang.data.tree.api.DataTreeCandidateNode;
-import org.opendaylight.yangtools.yang.data.tree.api.ModificationType;
import org.opendaylight.yangtools.yang.data.util.DataSchemaContext;
import org.opendaylight.yangtools.yang.data.util.DataSchemaContextTree;
import org.opendaylight.yangtools.yang.model.api.EffectiveModelContext;
abstract class AbstractWebsocketSerializer<T extends Exception> {
private static final Logger LOG = LoggerFactory.getLogger(AbstractWebsocketSerializer.class);
+ static final @NonNull QName PATH_QNAME = QName.create(DataChangeEvent.QNAME, "path").intern();
+ static final @NonNull NodeIdentifier PATH_NID = NodeIdentifier.create(PATH_QNAME);
+ static final @NonNull QName OPERATION_QNAME = QName.create(DataChangeEvent.QNAME, "operation").intern();
+ static final @NonNull NodeIdentifier OPERATION_NID = NodeIdentifier.create(OPERATION_QNAME);
+ static final @NonNull String DATA_NAME = Data.QNAME.getLocalName();
private final EffectiveModelContext context;
return before != null && after != null && before.body().equals(after.body());
}
- abstract void serializePath(Collection<PathArgument> pathArguments) throws T;
-
- abstract void serializeOperation(DataTreeCandidateNode candidate) throws T;
-
static final @Nullable NormalizedNode getDataAfter(final DataTreeCandidateNode candidate) {
final var data = candidate.dataAfter();
if (data instanceof MapEntryNode mapEntry) {
return sb.toString();
}
- @Deprecated
- static void appendQName(final StringBuilder sb, final QName qname) {
+ private static void appendQName(final StringBuilder sb, final QName qname) {
// FIXME: err: what?! what is this replacement?!
sb.append(qname.getNamespace().toString().replace(':', '-')).append(':').append(qname.getLocalName());
}
- static final String modificationTypeToOperation(final DataTreeCandidateNode candidate,
- final ModificationType modificationType) {
- return switch (modificationType) {
- case APPEARED, SUBTREE_MODIFIED, WRITE -> candidate.dataBefore() != null ? "updated" : "created";
- case DELETE, DISAPPEARED -> "deleted";
+ static final @NonNull String modificationTypeToOperation(final DataTreeCandidateNode candidate) {
+ final var operation = switch (candidate.modificationType()) {
+ case APPEARED, SUBTREE_MODIFIED, WRITE -> candidate.dataBefore() != null ? Operation.Updated
+ : Operation.Created;
+ case DELETE, DISAPPEARED -> Operation.Deleted;
case UNMODIFIED -> {
- // shouldn't ever happen since the root of a modification is only triggered by some event
- LOG.warn("DataTreeCandidate for a notification is unmodified. Candidate: {}", candidate);
- yield "none";
+ throw new VerifyException("DataTreeCandidate for a notification is unmodified. Candidate: "
+ + candidate);
}
};
+ return operation.getName();
}
}
import java.util.Collection;
import javax.xml.xpath.XPathExpressionException;
import org.eclipse.jdt.annotation.NonNull;
-import org.opendaylight.netconf.api.NamespaceURN;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.controller.md.sal.remote.rev140114.$YangModuleInfoImpl;
import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.controller.md.sal.remote.rev140114.DataChangedNotification;
import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.controller.md.sal.remote.rev140114.data.changed.notification.DataChangeEvent;
-import org.opendaylight.yangtools.yang.common.QName;
import org.opendaylight.yangtools.yang.data.codec.gson.JSONCodecFactorySupplier;
import org.opendaylight.yangtools.yang.data.tree.api.DataTreeCandidate;
import org.opendaylight.yangtools.yang.model.api.EffectiveModelContext;
public final class JSONDataTreeCandidateFormatter extends DataTreeCandidateFormatter {
- private static final @NonNull String NOTIFICATION_NAME;
+ private static final @NonNull String NOTIFICATION_NAME = "ietf-restconf:notification";
+
private static final @NonNull String DATA_CHANGED_NOTIFICATION_NAME;
private static final @NonNull String DATA_CHANGED_EVENT_NAME = DataChangeEvent.QNAME.getLocalName();
- // FIXME: JSON codec operating on XMLNamespace values?! This really should be module names, right?
static {
- final var sb = new StringBuilder();
- AbstractWebsocketSerializer.appendQName(sb, QName.create(NamespaceURN.NOTIFICATION, "notification"));
- NOTIFICATION_NAME = sb.toString();
-
- sb.setLength(0);
- AbstractWebsocketSerializer.appendQName(sb, DataChangedNotification.QNAME);
- DATA_CHANGED_NOTIFICATION_NAME = sb.toString();
+ final var salRemoteName = $YangModuleInfoImpl.getInstance().getName().getLocalName();
+ DATA_CHANGED_NOTIFICATION_NAME = salRemoteName + ":" + DataChangedNotification.QNAME.getLocalName();
}
private final JSONCodecFactorySupplier codecSupplier;
package org.opendaylight.restconf.nb.rfc8040.streams.listeners;
import static java.util.Objects.requireNonNull;
+import static org.opendaylight.yangtools.yang.data.codec.gson.JSONNormalizedNodeStreamWriter.createNestedWriter;
import com.google.gson.stream.JsonWriter;
import java.io.IOException;
import java.util.Collection;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.controller.md.sal.remote.rev140114.DataChangedNotification;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.controller.md.sal.remote.rev140114.data.changed.notification.DataChangeEvent;
+import org.opendaylight.yangtools.yang.common.XMLNamespace;
+import org.opendaylight.yangtools.yang.data.api.YangInstanceIdentifier;
import org.opendaylight.yangtools.yang.data.api.YangInstanceIdentifier.PathArgument;
import org.opendaylight.yangtools.yang.data.api.schema.stream.NormalizedNodeWriter;
import org.opendaylight.yangtools.yang.data.codec.gson.JSONCodecFactorySupplier;
-import org.opendaylight.yangtools.yang.data.codec.gson.JSONNormalizedNodeStreamWriter;
import org.opendaylight.yangtools.yang.data.tree.api.DataTreeCandidateNode;
+import org.opendaylight.yangtools.yang.data.tree.api.ModificationType;
import org.opendaylight.yangtools.yang.model.api.EffectiveModelContext;
+import org.opendaylight.yangtools.yang.model.api.stmt.SchemaNodeIdentifier.Absolute;
import org.opendaylight.yangtools.yang.model.util.SchemaInferenceStack.Inference;
final class JsonDataTreeCandidateSerializer extends AbstractWebsocketSerializer<IOException> {
+ private static final XMLNamespace SAL_REMOTE_NS = DataChangedNotification.QNAME.getNamespace();
+ private static final Absolute DATA_CHANGE_EVENT = Absolute.of(DataChangedNotification.QNAME, DataChangeEvent.QNAME);
+
private final JSONCodecFactorySupplier codecSupplier;
private final JsonWriter jsonWriter;
final DataTreeCandidateNode candidate, final boolean skipData) throws IOException {
jsonWriter.beginObject();
- final var codecs = codecSupplier.getShared(parent.getEffectiveModelContext());
- try (var nestedWriter = JSONNormalizedNodeStreamWriter.createNestedWriter(codecs, parent, null, jsonWriter)) {
- serializePath(dataPath);
+ final var modificationType = candidate.modificationType();
+ if (modificationType != ModificationType.UNMODIFIED) {
+ final var codecs = codecSupplier.getShared(parent.getEffectiveModelContext());
+ try (var writer = createNestedWriter(codecs, DATA_CHANGE_EVENT, SAL_REMOTE_NS, jsonWriter)) {
+ writer.startLeafNode(PATH_NID);
+ writer.scalarValue(YangInstanceIdentifier.of(dataPath));
+ writer.endNode();
+
+ writer.startLeafNode(OPERATION_NID);
+ writer.scalarValue(modificationTypeToOperation(candidate));
+ writer.endNode();
+ }
if (!skipData) {
final var dataAfter = getDataAfter(candidate);
if (dataAfter != null) {
jsonWriter.name("data").beginObject();
- NormalizedNodeWriter.forStreamWriter(nestedWriter).write(dataAfter).flush();
+ try (var writer = createNestedWriter(codecs, parent, SAL_REMOTE_NS, jsonWriter)) {
+ NormalizedNodeWriter.forStreamWriter(writer).write(dataAfter).flush();
+ }
jsonWriter.endObject();
}
}
-
- serializeOperation(candidate);
}
jsonWriter.endObject();
}
-
- @Override
- void serializeOperation(final DataTreeCandidateNode candidate)
- throws IOException {
- jsonWriter.name("operation").value(modificationTypeToOperation(candidate, candidate.modificationType()));
- }
-
- @Override
- void serializePath(final Collection<PathArgument> pathArguments)
- throws IOException {
- // FIXME: use proper JSON codec for YangInstanceIdentifier
- jsonWriter.name("path").value(convertPath(pathArguments));
- }
}
import static org.opendaylight.restconf.nb.rfc8040.streams.listeners.NotificationFormatter.DATA_CHANGE_EVENT_ELEMENT;
import java.util.Collection;
-import javax.xml.stream.XMLStreamException;
import javax.xml.stream.XMLStreamWriter;
import org.opendaylight.yangtools.yang.data.api.YangInstanceIdentifier.PathArgument;
-import org.opendaylight.yangtools.yang.data.api.schema.stream.NormalizedNodeStreamWriter;
import org.opendaylight.yangtools.yang.data.api.schema.stream.NormalizedNodeWriter;
import org.opendaylight.yangtools.yang.data.codec.xml.XMLStreamNormalizedNodeStreamWriter;
import org.opendaylight.yangtools.yang.data.tree.api.DataTreeCandidateNode;
+import org.opendaylight.yangtools.yang.data.tree.api.ModificationType;
import org.opendaylight.yangtools.yang.model.api.EffectiveModelContext;
import org.opendaylight.yangtools.yang.model.util.SchemaInferenceStack.Inference;
}
@Override
- void serializeData(final Inference parent, final Collection<PathArgument> nodePath,
+ void serializeData(final Inference parent, final Collection<PathArgument> dataPath,
final DataTreeCandidateNode candidate, final boolean skipData) throws Exception {
- NormalizedNodeStreamWriter nodeStreamWriter = XMLStreamNormalizedNodeStreamWriter.create(xmlWriter, parent);
- xmlWriter.writeStartElement(DATA_CHANGE_EVENT_ELEMENT);
- serializePath(nodePath);
-
- if (!skipData) {
- final var dataAfter = getDataAfter(candidate);
- if (dataAfter != null) {
- xmlWriter.writeStartElement("data");
- NormalizedNodeWriter nnWriter = NormalizedNodeWriter.forStreamWriter(nodeStreamWriter);
- nnWriter.write(dataAfter);
- nnWriter.flush();
- xmlWriter.writeEndElement();
+ final var modificationType = candidate.modificationType();
+ if (modificationType != ModificationType.UNMODIFIED) {
+ xmlWriter.writeStartElement(DATA_CHANGE_EVENT_ELEMENT);
+ xmlWriter.writeStartElement("path");
+ // FIXME: use proper XML codec for YangInstanceIdentifier
+ xmlWriter.writeCharacters(convertPath(dataPath));
+ xmlWriter.writeEndElement();
+
+ xmlWriter.writeStartElement("operation");
+ xmlWriter.writeCharacters(modificationTypeToOperation(candidate));
+ xmlWriter.writeEndElement();
+
+ if (!skipData) {
+ final var dataAfter = getDataAfter(candidate);
+ if (dataAfter != null) {
+ xmlWriter.writeStartElement("data");
+ final var nnWriter = NormalizedNodeWriter.forStreamWriter(
+ XMLStreamNormalizedNodeStreamWriter.create(xmlWriter, parent));
+ nnWriter.write(dataAfter);
+ nnWriter.flush();
+ xmlWriter.writeEndElement();
+ }
}
- }
- serializeOperation(candidate);
- xmlWriter.writeEndElement();
- }
-
- @Override
- public void serializePath(final Collection<PathArgument> pathArguments) throws XMLStreamException {
- xmlWriter.writeStartElement("path");
- // FIXME: use proper XML codec for YangInstanceIdentifier
- xmlWriter.writeCharacters(convertPath(pathArguments));
- xmlWriter.writeEndElement();
- }
-
- @Override
- public void serializeOperation(final DataTreeCandidateNode candidate) throws XMLStreamException {
- xmlWriter.writeStartElement("operation");
- xmlWriter.writeCharacters(modificationTypeToOperation(candidate, candidate.modificationType()));
- xmlWriter.writeEndElement();
+ xmlWriter.writeEndElement();
+ }
}
}
static String withFakeDate(final String in) throws JSONException {
final JSONObject doc = new JSONObject(in);
- final JSONObject notification =
- doc.getJSONObject("urn-ietf-params-xml-ns-netconf-notification-1.0:notification");
+ final JSONObject notification = doc.getJSONObject("ietf-restconf:notification");
if (notification == null) {
return in;
}
--- /dev/null
+module sal-remote {
+
+ yang-version 1;
+ namespace "urn:opendaylight:params:xml:ns:yang:controller:md:sal:remote";
+ prefix "sal-remote";
+
+ organization "Cisco Systems, Inc.";
+ contact "Martin Bobak <mbobak@cisco.com>";
+
+ description
+ "This module contains the definition of methods related to
+ sal remote model.
+
+ Copyright (c)2013 Cisco Systems, Inc. All rights reserved.
+
+ This program and the accompanying materials are made available
+ under the terms of the Eclipse Public License v1.0 which
+ accompanies this distribution, and is available at
+ http://www.eclipse.org/legal/epl-v10.html";
+
+ revision "2014-01-14" {
+ description "Initial revision";
+ }
+
+ typedef q-name {
+ type string;
+ reference "http://www.w3.org/TR/2004/REC-xmlschema-2-20041028/#QName";
+ }
+
+ rpc create-data-change-event-subscription {
+ input {
+ leaf path {
+ type instance-identifier;
+ description "Subtree path. ";
+ mandatory true;
+ }
+ }
+ output {
+ leaf stream-name {
+ type string;
+ description "Notification stream name.";
+ }
+ }
+ }
+
+ notification data-changed-notification {
+ description "Data change notification.";
+ list data-change-event {
+ key path;
+ leaf path {
+ type instance-identifier;
+ }
+ leaf store {
+ type enumeration {
+ enum config;
+ enum operation;
+ }
+ }
+ leaf operation {
+ type enumeration {
+ enum created;
+ enum updated;
+ enum deleted;
+ }
+ }
+ anyxml data{
+ description "DataObject ";
+ }
+ }
+ }
+
+ rpc create-notification-stream {
+ input {
+ leaf-list notifications {
+ type q-name;
+ description "Notification QNames";
+ min-elements 1;
+ }
+ }
+ output {
+ leaf notification-stream-identifier {
+ type string;
+ description "Unique notification stream identifier, in which notifications will be propagated";
+ }
+ }
+ }
+
+ rpc begin-transaction {
+ output {
+ anyxml data-modification-transaction {
+ description "DataModificationTransaction xml";
+ }
+ }
+ }
+}
{
- "urn-ietf-params-xml-ns-netconf-notification-1.0:notification": {
- "urn-opendaylight-params-xml-ns-yang-controller-md-sal-remote:data-changed-notification": {
- "data-change-event": [
- {
- "path": "/instance-identifier-patch-module:patch-cont/instance-identifier-patch-module:my-list1/instance-identifier-patch-module:my-list1[instance-identifier-patch-module:name='Althea']/instance-identifier-patch-module:my-leaf11",
- "data": {
- "instance-identifier-patch-module:my-leaf11": "Jed"
- },
- "operation": "created"
- },
- {
- "path": "/instance-identifier-patch-module:patch-cont/instance-identifier-patch-module:my-list1/instance-identifier-patch-module:my-list1[instance-identifier-patch-module:name='Althea']/instance-identifier-patch-module:name",
- "data": {
- "instance-identifier-patch-module:name": "Althea"
- },
- "operation": "created"
- },
- {
- "path": "/instance-identifier-patch-module:patch-cont/augment-instance-identifier-patch-module:leaf1",
- "data": {
- "augment-iip-module:leaf1": "AugmentLeaf"
- },
- "operation": "created"
- },
- {
- "path": "/instance-identifier-patch-module:patch-cont/augment-instance-identifier-patch-module:patch-choice2/augment-instance-identifier-patch-module:patch-sub-choice11/augment-instance-identifier-patch-module:patch-sub-sub-choice11/augment-instance-identifier-patch-module:case-leaf11",
- "data": {
- "augment-iip-module:case-leaf11": "ChoiceLeaf"
- },
- "operation": "created"
+ "ietf-restconf:notification" : {
+ "event-time": "2022-09-22T19:07:42.107085298+02:00",
+ "sal-remote:data-changed-notification" : {
+ "data-change-event" : [
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/my-list1[name='Althea']/my-leaf11",
+ "operation" : "created",
+ "data" : {
+ "instance-identifier-patch-module:my-leaf11" : "Jed"
+ }
+ },
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/my-list1[name='Althea']/name",
+ "operation" : "created",
+ "data" : {
+ "instance-identifier-patch-module:name" : "Althea"
+ }
+ },
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/augment-iip-module:leaf1",
+ "operation" : "created",
+ "data" : {
+ "augment-iip-module:leaf1" : "AugmentLeaf"
+ }
+ },
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/augment-iip-module:case-leaf11",
+ "operation" : "created",
+ "data" : {
+ "augment-iip-module:case-leaf11" : "ChoiceLeaf"
+ }
+ }
+ ]
}
- ]
- },
- "event-time": "2022-09-22T19:07:42.107085298+02:00"
- }
-}
\ No newline at end of file
+ }
+}
{
- "urn-ietf-params-xml-ns-netconf-notification-1.0:notification": {
- "urn-opendaylight-params-xml-ns-yang-controller-md-sal-remote:data-changed-notification": {
- "data-change-event": [
- {
- "path": "/instance-identifier-patch-module:patch-cont/instance-identifier-patch-module:my-list1/instance-identifier-patch-module:my-list1[instance-identifier-patch-module:name='Althea']/instance-identifier-patch-module:my-leaf11",
- "operation": "deleted"
- },
- {
- "path": "/instance-identifier-patch-module:patch-cont/instance-identifier-patch-module:my-list1/instance-identifier-patch-module:my-list1[instance-identifier-patch-module:name='Althea']/instance-identifier-patch-module:name",
- "operation": "deleted"
- },
- {
- "path": "/instance-identifier-patch-module:patch-cont/instance-identifier-patch-module:my-list1/instance-identifier-patch-module:my-list1[instance-identifier-patch-module:name='Althea']/instance-identifier-patch-module:my-leaf12",
- "operation": "deleted"
- },
- {
- "path": "/instance-identifier-patch-module:patch-cont/augment-instance-identifier-patch-module:leaf1",
- "operation": "deleted"
- },
- {
- "path": "/instance-identifier-patch-module:patch-cont/augment-instance-identifier-patch-module:patch-choice2/augment-instance-identifier-patch-module:patch-sub-choice11/augment-instance-identifier-patch-module:patch-sub-sub-choice11/augment-instance-identifier-patch-module:case-leaf11",
- "operation": "deleted"
+ "ietf-restconf:notification" : {
+ "event-time": "2022-09-22T19:09:08.564261906+02:00",
+ "sal-remote:data-changed-notification" : {
+ "data-change-event" : [
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/my-list1[name='Althea']/my-leaf11",
+ "operation" : "deleted"
+ },
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/my-list1[name='Althea']/name",
+ "operation" : "deleted"
+ },
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/my-list1[name='Althea']/my-leaf12",
+ "operation" : "deleted"
+ },
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/augment-iip-module:leaf1",
+ "operation" : "deleted"
+ },
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/augment-iip-module:case-leaf11",
+ "operation" : "deleted"
+ }
+ ]
}
- ]
- },
- "event-time": "2022-09-22T19:09:08.564261906+02:00"
- }
+ }
}
{
- "urn-ietf-params-xml-ns-netconf-notification-1.0:notification": {
- "urn-opendaylight-params-xml-ns-yang-controller-md-sal-remote:data-changed-notification": {
- "data-change-event": [
- {
- "path": "/instance-identifier-patch-module:patch-cont/instance-identifier-patch-module:my-list1/instance-identifier-patch-module:my-list1[instance-identifier-patch-module:name='Althea']/instance-identifier-patch-module:my-leaf12",
- "data": {
- "instance-identifier-patch-module:my-leaf12": "Bertha"
- },
- "operation": "created"
- },
- {
- "path": "/instance-identifier-patch-module:patch-cont/augment-instance-identifier-patch-module:patch-choice2/augment-instance-identifier-patch-module:patch-sub-choice11/augment-instance-identifier-patch-module:patch-sub-sub-choice11/augment-instance-identifier-patch-module:case-leaf11",
- "data": {
- "augment-iip-module:case-leaf11": "ChoiceUpdate"
- },
- "operation": "updated"
+ "ietf-restconf:notification" : {
+ "event-time" : "2022-09-22T19:08:32.400965352+02:00",
+ "sal-remote:data-changed-notification" : {
+ "data-change-event" : [
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/my-list1[name='Althea']/my-leaf12",
+ "operation" : "created",
+ "data" : {
+ "instance-identifier-patch-module:my-leaf12" : "Bertha"
+ }
+ },
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/augment-iip-module:case-leaf11",
+ "operation" : "updated",
+ "data" : {
+ "augment-iip-module:case-leaf11" : "ChoiceUpdate"
+ }
+ }
+ ]
}
- ]
- },
- "event-time": "2022-09-22T19:08:32.400965352+02:00"
- }
-}
\ No newline at end of file
+ }
+}
{
- "urn-ietf-params-xml-ns-netconf-notification-1.0:notification":{
- "urn-opendaylight-params-xml-ns-yang-controller-md-sal-remote:data-changed-notification":{
+ "ietf-restconf:notification":{
+ "event-time":"2020-10-14T11:16:51.111635+02:00",
+ "sal-remote:data-changed-notification":{
"data-change-event":[
{
"path":"/instance-identifier-patch-module:patch-cont",
}
}
]
- },
- "event-time":"2020-10-14T11:16:51.111635+02:00"
+ }
}
}
{
- "urn-ietf-params-xml-ns-netconf-notification-1.0:notification":{
- "urn-opendaylight-params-xml-ns-yang-controller-md-sal-remote:data-changed-notification":{
+ "ietf-restconf:notification":{
+ "event-time":"2020-10-14T11:20:33.271836+02:00",
+ "sal-remote:data-changed-notification":{
"data-change-event":[
{
"path":"/instance-identifier-patch-module:patch-cont",
"operation":"deleted"
}
]
- },
- "event-time":"2020-10-14T11:20:33.271836+02:00"
+ }
}
}
{
- "urn-ietf-params-xml-ns-netconf-notification-1.0:notification":{
- "urn-opendaylight-params-xml-ns-yang-controller-md-sal-remote:data-changed-notification":{
+ "ietf-restconf:notification":{
+ "event-time":"2020-10-14T11:16:51.111635+02:00",
+ "sal-remote:data-changed-notification":{
"data-change-event":[
{
- "path":"/instance-identifier-patch-module:patch-cont/instance-identifier-patch-module:my-list1/instance-identifier-patch-module:my-list1[instance-identifier-patch-module:name='Althea']",
+ "path":"/instance-identifier-patch-module:patch-cont/my-list1[name='Althea']",
"operation":"updated",
"data":{
"instance-identifier-patch-module:my-list1":[
}
}
]
- },
- "event-time":"2020-10-14T11:16:51.111635+02:00"
+ }
}
}
{
- "urn-ietf-params-xml-ns-netconf-notification-1.0:notification":{
- "urn-opendaylight-params-xml-ns-yang-controller-md-sal-remote:data-changed-notification":{
+ "ietf-restconf:notification":{
+ "event-time":"2020-10-14T11:19:34.549843+02:00",
+ "sal-remote:data-changed-notification":{
"data-change-event":[
{
- "path":"/instance-identifier-patch-module:patch-cont/instance-identifier-patch-module:my-list1/instance-identifier-patch-module:my-list1[instance-identifier-patch-module:name='Althea']/instance-identifier-patch-module:my-leaf11",
+ "path":"/instance-identifier-patch-module:patch-cont/my-list1[name='Althea']/my-leaf11",
"operation":"updated",
"data":{
"instance-identifier-patch-module:my-leaf11":"Jed"
}
}
]
- },
- "event-time":"2020-10-14T11:19:34.549843+02:00"
+ }
}
}
{
- "urn-ietf-params-xml-ns-netconf-notification-1.0:notification":{
- "urn-opendaylight-params-xml-ns-yang-controller-md-sal-remote:data-changed-notification":{
+ "ietf-restconf:notification":{
+ "sal-remote:data-changed-notification":{
"data-change-event":[
{
"path":"/instance-identifier-patch-module:patch-cont",
{
- "urn-ietf-params-xml-ns-netconf-notification-1.0:notification":{
- "urn-opendaylight-params-xml-ns-yang-controller-md-sal-remote:data-changed-notification":{
+ "ietf-restconf:notification":{
+ "sal-remote:data-changed-notification":{
"data-change-event":[
{
"path":"/instance-identifier-patch-module:patch-cont",
{
- "urn-ietf-params-xml-ns-netconf-notification-1.0:notification":{
- "urn-opendaylight-params-xml-ns-yang-controller-md-sal-remote:data-changed-notification":{
+ "ietf-restconf:notification":{
+ "sal-remote:data-changed-notification":{
"data-change-event":[
{
"path":"/instance-identifier-patch-module:patch-cont",
{
- "urn-ietf-params-xml-ns-netconf-notification-1.0:notification": {
- "urn-opendaylight-params-xml-ns-yang-controller-md-sal-remote:data-changed-notification": {
- "data-change-event": [
- {
- "path": "/instance-identifier-patch-module:patch-cont/instance-identifier-patch-module:my-list1/instance-identifier-patch-module:my-list1[instance-identifier-patch-module:name='Althea']/instance-identifier-patch-module:my-leaf11",
- "data": {
- "instance-identifier-patch-module:my-leaf11": "Jed"
- },
- "operation": "created"
- },
- {
- "path": "/instance-identifier-patch-module:patch-cont/instance-identifier-patch-module:my-list1/instance-identifier-patch-module:my-list1[instance-identifier-patch-module:name='Althea']/instance-identifier-patch-module:name",
- "data": {
- "instance-identifier-patch-module:name": "Althea"
- },
- "operation": "created"
- },
- {
- "path": "/instance-identifier-patch-module:patch-cont/augment-instance-identifier-patch-module:patch-choice1/augment-instance-identifier-patch-module:case-leaf1",
- "data": {
- "augment-iip-module:case-leaf1": "ChoiceLeaf"
- },
- "operation": "created"
- },
- {
- "path": "/instance-identifier-patch-module:patch-cont/augment-instance-identifier-patch-module:leaf1",
- "data": {
- "augment-iip-module:leaf1": "AugmentLeaf"
- },
- "operation": "created"
+ "ietf-restconf:notification" : {
+ "event-time" : "2022-02-18T18:04:25.177143+01:00",
+ "sal-remote:data-changed-notification" : {
+ "data-change-event" : [
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/my-list1[name='Althea']/name",
+ "operation" : "created",
+ "data" : {
+ "instance-identifier-patch-module:name" : "Althea"
+ }
+ },
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/my-list1[name='Althea']/my-leaf11",
+ "operation" : "created",
+ "data" : {
+ "instance-identifier-patch-module:my-leaf11" : "Jed"
+ }
+ },
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/augment-iip-module:leaf1",
+ "operation" : "created",
+ "data" : {
+ "augment-iip-module:leaf1" : "AugmentLeaf"
+ }
+ },
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/augment-iip-module:case-leaf1",
+ "operation":"created",
+ "data" : {
+ "augment-iip-module:case-leaf1" : "ChoiceLeaf"
+ }
+ }
+ ]
}
- ]
- },
- "event-time": "2022-02-18T18:04:25.177143+01:00"
- }
-}
\ No newline at end of file
+ }
+}
{
- "urn-ietf-params-xml-ns-netconf-notification-1.0:notification": {
- "urn-opendaylight-params-xml-ns-yang-controller-md-sal-remote:data-changed-notification": {
- "data-change-event": [
- {
- "path": "/instance-identifier-patch-module:patch-cont/instance-identifier-patch-module:my-list1/instance-identifier-patch-module:my-list1[instance-identifier-patch-module:name='Althea']/instance-identifier-patch-module:my-leaf11",
- "operation": "deleted"
- },
- {
- "path": "/instance-identifier-patch-module:patch-cont/instance-identifier-patch-module:my-list1/instance-identifier-patch-module:my-list1[instance-identifier-patch-module:name='Althea']/instance-identifier-patch-module:name",
- "operation": "deleted"
- },
- {
- "path": "/instance-identifier-patch-module:patch-cont/instance-identifier-patch-module:my-list1/instance-identifier-patch-module:my-list1[instance-identifier-patch-module:name='Althea']/instance-identifier-patch-module:my-leaf12",
- "operation": "deleted"
- },
- {
- "path": "/instance-identifier-patch-module:patch-cont/augment-instance-identifier-patch-module:patch-choice1/augment-instance-identifier-patch-module:case-leaf1",
- "operation": "deleted"
- },
- {
- "path": "/instance-identifier-patch-module:patch-cont/augment-instance-identifier-patch-module:leaf1",
- "operation": "deleted"
+ "ietf-restconf:notification" : {
+ "event-time": "2022-02-18T18:07:48.662524+01:00",
+ "sal-remote:data-changed-notification" : {
+ "data-change-event" : [
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/my-list1[name='Althea']/my-leaf11",
+ "operation" : "deleted"
+ },
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/my-list1[name='Althea']/name",
+ "operation" : "deleted"
+ },
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/my-list1[name='Althea']/my-leaf12",
+ "operation" : "deleted"
+ },
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/augment-iip-module:leaf1",
+ "operation" : "deleted"
+ },
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/augment-iip-module:case-leaf1",
+ "operation" : "deleted"
+ }
+ ]
}
- ]
- },
- "event-time": "2022-02-18T18:07:48.662524+01:00"
- }
-}
\ No newline at end of file
+ }
+}
{
- "urn-ietf-params-xml-ns-netconf-notification-1.0:notification": {
- "urn-opendaylight-params-xml-ns-yang-controller-md-sal-remote:data-changed-notification": {
- "data-change-event": [
- {
- "path": "/instance-identifier-patch-module:patch-cont/instance-identifier-patch-module:my-list1/instance-identifier-patch-module:my-list1[instance-identifier-patch-module:name='Althea']/instance-identifier-patch-module:name",
- "data": {
- "instance-identifier-patch-module:name": "Althea"
- },
- "operation": "updated"
- },
- {
- "path": "/instance-identifier-patch-module:patch-cont/instance-identifier-patch-module:my-list1/instance-identifier-patch-module:my-list1[instance-identifier-patch-module:name='Althea']/instance-identifier-patch-module:my-leaf12",
- "data": {
- "instance-identifier-patch-module:my-leaf12": "Bertha"
- },
- "operation": "created"
- },
- {
- "path": "/instance-identifier-patch-module:patch-cont/augment-instance-identifier-patch-module:patch-choice1/augment-instance-identifier-patch-module:case-leaf1",
- "data": {
- "augment-iip-module:case-leaf1": "ChoiceUpdate"
- },
- "operation": "updated"
- },
- {
- "path": "/instance-identifier-patch-module:patch-cont/augment-instance-identifier-patch-module:leaf1",
- "data": {
- "augment-iip-module:leaf1": "AugmentLeaf"
- },
- "operation": "updated"
+ "ietf-restconf:notification" : {
+ "event-time": "2022-02-18T18:04:25.214583+01:00",
+ "sal-remote:data-changed-notification" : {
+ "data-change-event" : [
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/my-list1[name='Althea']/name",
+ "operation" : "updated",
+ "data" : {
+ "instance-identifier-patch-module:name" : "Althea"
+ }
+ },
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/my-list1[name='Althea']/my-leaf12",
+ "operation" : "created",
+ "data" : {
+ "instance-identifier-patch-module:my-leaf12" : "Bertha"
+ }
+ },
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/augment-iip-module:leaf1",
+ "operation" : "updated",
+ "data" : {
+ "augment-iip-module:leaf1" : "AugmentLeaf"
+ }
+ },
+ {
+ "path" : "/instance-identifier-patch-module:patch-cont/augment-iip-module:case-leaf1",
+ "operation" : "updated",
+ "data" : {
+ "augment-iip-module:case-leaf1" : "ChoiceUpdate"
+ }
+ }
+ ]
}
- ]
- },
- "event-time": "2022-02-18T18:04:25.214583+01:00"
- }
-}
\ No newline at end of file
+ }
+}
{
- "urn-ietf-params-xml-ns-netconf-notification-1.0:notification":{
- "urn-opendaylight-params-xml-ns-yang-controller-md-sal-remote:data-changed-notification":{
- "data-change-event":[
+ "ietf-restconf:notification" : {
+ "event-time" : "2020-10-14T11:16:51.111635+02:00",
+ "sal-remote:data-changed-notification" : {
+ "data-change-event" : [
{
- "path":"/instance-identifier-patch-module:patch-cont/instance-identifier-patch-module:my-list1/instance-identifier-patch-module:my-list1[instance-identifier-patch-module:name='Althea']",
- "data":{
- "instance-identifier-patch-module:my-list1":[
+ "path" : "/instance-identifier-patch-module:patch-cont/my-list1[name='Althea']",
+ "operation" : "created",
+ "data" : {
+ "instance-identifier-patch-module:my-list1" : [
{
- "name":"Althea",
- "my-leaf11":"Jed"
+ "name" : "Althea",
+ "my-leaf11" : "Jed"
}
]
- },
- "operation":"created"
+ }
}
]
- },
- "event-time":"2020-10-14T11:16:51.111635+02:00"
+ }
}
}
{
- "urn-ietf-params-xml-ns-netconf-notification-1.0:notification":{
- "urn-opendaylight-params-xml-ns-yang-controller-md-sal-remote:data-changed-notification":{
- "data-change-event":[
+ "ietf-restconf:notification" : {
+ "event-time":"2020-10-14T11:20:33.271836+02:00",
+ "sal-remote:data-changed-notification" : {
+ "data-change-event" : [
{
- "path":"/instance-identifier-patch-module:patch-cont/instance-identifier-patch-module:my-list1/instance-identifier-patch-module:my-list1[instance-identifier-patch-module:name='Althea']",
- "operation":"deleted"
+ "path" : "/instance-identifier-patch-module:patch-cont/my-list1[name='Althea']",
+ "operation" : "deleted"
}
]
- },
- "event-time":"2020-10-14T11:20:33.271836+02:00"
+ }
}
}
{
- "urn-ietf-params-xml-ns-netconf-notification-1.0:notification":{
- "urn-opendaylight-params-xml-ns-yang-controller-md-sal-remote:data-changed-notification":{
- "data-change-event":[
+ "ietf-restconf:notification" : {
+ "event-time":"2020-10-14T11:19:34.549843+02:00",
+ "sal-remote:data-changed-notification" : {
+ "data-change-event" : [
{
- "path":"/instance-identifier-patch-module:patch-cont/instance-identifier-patch-module:my-list1/instance-identifier-patch-module:my-list1[instance-identifier-patch-module:name='Althea']",
- "data":{
- "instance-identifier-patch-module:my-list1":[
+ "path" : "/instance-identifier-patch-module:patch-cont/my-list1[name='Althea']",
+ "operation" : "updated",
+ "data" : {
+ "instance-identifier-patch-module:my-list1" : [
{
- "name":"Althea",
- "my-leaf11":"Jed",
- "my-leaf12":"Bertha"
+ "name" : "Althea",
+ "my-leaf11" : "Jed",
+ "my-leaf12" : "Bertha"
}
]
- },
- "operation":"updated"
+ }
}
]
- },
- "event-time":"2020-10-14T11:19:34.549843+02:00"
+ }
}
}
{
- "urn-ietf-params-xml-ns-netconf-notification-1.0:notification":{
- "urn-opendaylight-params-xml-ns-yang-controller-md-sal-remote:data-changed-notification":{
+ "ietf-restconf:notification":{
+ "sal-remote:data-changed-notification":{
"data-change-event":[
{
"path":"/instance-identifier-patch-module:patch-cont",
{
- "urn-ietf-params-xml-ns-netconf-notification-1.0:notification":{
- "urn-opendaylight-params-xml-ns-yang-controller-md-sal-remote:data-changed-notification":{
+ "ietf-restconf:notification":{
+ "sal-remote:data-changed-notification":{
"data-change-event":[
{
"path":"/instance-identifier-patch-module:patch-cont",
{
- "urn-ietf-params-xml-ns-netconf-notification-1.0:notification":{
- "urn-opendaylight-params-xml-ns-yang-controller-md-sal-remote:data-changed-notification":{
+ "ietf-restconf:notification":{
+ "sal-remote:data-changed-notification":{
"data-change-event":[
{
"path":"/instance-identifier-patch-module:patch-cont",
{
- "urn-ietf-params-xml-ns-netconf-notification-1.0:notification":{
- "urn-opendaylight-params-xml-ns-yang-controller-md-sal-remote:data-changed-notification":{
- "data-change-event":[
+ "ietf-restconf:notification" : {
+ "event-time":"2020-10-14T12:34:59.085525+02:00",
+ "sal-remote:data-changed-notification" : {
+ "data-change-event" : [
{
- "path":"/instance-identifier-patch-module:patch-cont/instance-identifier-patch-module:my-list1/instance-identifier-patch-module:my-list1[instance-identifier-patch-module:name='Althea']",
- "operation":"created"
+ "path" : "/instance-identifier-patch-module:patch-cont/my-list1[name='Althea']",
+ "operation" : "created"
}
]
- },
- "event-time":"2020-10-14T12:34:59.085525+02:00"
+ }
}
}
{
- "urn-ietf-params-xml-ns-netconf-notification-1.0:notification":{
- "urn-opendaylight-params-xml-ns-yang-controller-md-sal-remote:data-changed-notification":{
- "data-change-event":[
+ "ietf-restconf:notification" : {
+ "event-time":"2020-10-14T12:34:59.085525+02:00",
+ "sal-remote:data-changed-notification" : {
+ "data-change-event" : [
{
- "path":"/instance-identifier-patch-module:patch-cont/instance-identifier-patch-module:my-list1/instance-identifier-patch-module:my-list1[instance-identifier-patch-module:name='Althea']",
- "operation":"deleted"
+ "path" : "/instance-identifier-patch-module:patch-cont/my-list1[name='Althea']",
+ "operation" : "deleted"
}
]
- },
- "event-time":"2020-10-14T12:34:59.085525+02:00"
+ }
}
}
{
- "urn-ietf-params-xml-ns-netconf-notification-1.0:notification":{
- "urn-opendaylight-params-xml-ns-yang-controller-md-sal-remote:data-changed-notification":{
- "data-change-event":[
+ "ietf-restconf:notification" : {
+ "event-time":"2020-10-14T12:34:59.085525+02:00",
+ "sal-remote:data-changed-notification" : {
+ "data-change-event" : [
{
- "path":"/instance-identifier-patch-module:patch-cont/instance-identifier-patch-module:my-list1/instance-identifier-patch-module:my-list1[instance-identifier-patch-module:name='Althea']",
- "operation":"updated"
+ "path" : "/instance-identifier-patch-module:patch-cont/my-list1[name='Althea']",
+ "operation" : "updated"
}
]
- },
- "event-time":"2020-10-14T12:34:59.085525+02:00"
+ }
}
}