Add some log messages in case controller failed to add connected node. 14/3914/2
authorJason Ye <yisye@cisco.com>
Tue, 24 Dec 2013 15:33:48 +0000 (07:33 -0800)
committerJason Ye <yisye@cisco.com>
Tue, 24 Dec 2013 15:43:03 +0000 (07:43 -0800)
Change-Id: Ia3df4dda32cc5e91ba862679712debbd68e11fdb
Signed-off-by: Jason Ye <yisye@cisco.com>
opendaylight/connectionmanager/implementation/src/main/java/org/opendaylight/controller/connectionmanager/scheme/AbstractScheme.java

index 5ba156e..718a3ff 100644 (file)
@@ -277,6 +277,11 @@ public abstract class AbstractScheme {
 
     public Status addNode (Node node, InetAddress controller) {
         if (node == null || controller == null) {
+            if (node == null) {
+                log.warn("addNode: node is null");
+            } else if (controller == null) {
+                log.error("Failed to add node {}. The controller address retrieved from clusterServices is null.", node);
+            }
             return new Status(StatusCode.BADREQUEST);
         }
         if (isLocal(node))  {

©2013 OpenDaylight, A Linux Foundation Collaborative Project. All Rights Reserved.
OpenDaylight is a registered trademark of The OpenDaylight Project, Inc.
Linux Foundation and OpenDaylight are registered trademarks of the Linux Foundation.
Linux is a registered trademark of Linus Torvalds.