From: Tony Tkacik Date: Mon, 23 Feb 2015 11:18:23 +0000 (+0000) Subject: Merge "Serialize capabilities for notification properly" X-Git-Tag: release/lithium~470^2~7 X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?p=controller.git;a=commitdiff_plain;h=2510f61324167d667aa799101648965ea99325ee;hp=011999db87b0d657cba2974abdd8ec16466c7a14 Merge "Serialize capabilities for notification properly" --- diff --git a/opendaylight/md-sal/sal-netconf-connector/src/main/java/org/opendaylight/controller/sal/connect/netconf/NotificationHandler.java b/opendaylight/md-sal/sal-netconf-connector/src/main/java/org/opendaylight/controller/sal/connect/netconf/NotificationHandler.java index d340e4c1ad..bc3326e1ae 100644 --- a/opendaylight/md-sal/sal-netconf-connector/src/main/java/org/opendaylight/controller/sal/connect/netconf/NotificationHandler.java +++ b/opendaylight/md-sal/sal-netconf-connector/src/main/java/org/opendaylight/controller/sal/connect/netconf/NotificationHandler.java @@ -63,7 +63,7 @@ final class NotificationHandler { private CompositeNode transformNotification(final NetconfMessage cachedNotification) { final CompositeNode parsedNotification = messageTransformer.toNotification(cachedNotification); - Preconditions.checkNotNull(parsedNotification, "{}: Unable to parse received notification %s", id, cachedNotification); + Preconditions.checkNotNull(parsedNotification, "%s: Unable to parse received notification: %s", id, cachedNotification); return parsedNotification; } @@ -91,6 +91,7 @@ final class NotificationHandler { } synchronized void onRemoteSchemaDown() { + queue.clear(); passNotifications = false; } diff --git a/opendaylight/netconf/config-netconf-connector/src/main/java/org/opendaylight/controller/netconf/confignetconfconnector/osgi/YangStoreService.java b/opendaylight/netconf/config-netconf-connector/src/main/java/org/opendaylight/controller/netconf/confignetconfconnector/osgi/YangStoreService.java index 60b8b8f468..176800fb97 100644 --- a/opendaylight/netconf/config-netconf-connector/src/main/java/org/opendaylight/controller/netconf/confignetconfconnector/osgi/YangStoreService.java +++ b/opendaylight/netconf/config-netconf-connector/src/main/java/org/opendaylight/controller/netconf/confignetconfconnector/osgi/YangStoreService.java @@ -191,8 +191,7 @@ public class YangStoreService implements YangStoreContext { private static final Function MODULE_TO_URI = new Function() { @Override public Uri apply(final Module input) { - final QName qName = QName.cachedReference(QName.create(input.getQNameModule(), input.getName())); - return new Uri(qName.toString()); + return new Uri(new NetconfOperationServiceFactoryImpl.YangStoreCapability(input, input.getSource()).getCapabilityUri()); } };