From d4e9417a5930e973ea770bb93e808b463fa0b980 Mon Sep 17 00:00:00 2001 From: Jordan Halterman Date: Tue, 21 Aug 2018 10:38:43 -0700 Subject: [PATCH] Always ignore root node when adding node to dynamic config store Change-Id: I8cb0021fc9098fb71743f64dfbf0733c794452fc --- .../onosproject/config/impl/DistributedDynamicConfigStore.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/config/src/main/java/org/onosproject/config/impl/DistributedDynamicConfigStore.java b/apps/config/src/main/java/org/onosproject/config/impl/DistributedDynamicConfigStore.java index 1ae8d46e89..a143fca681 100644 --- a/apps/config/src/main/java/org/onosproject/config/impl/DistributedDynamicConfigStore.java +++ b/apps/config/src/main/java/org/onosproject/config/impl/DistributedDynamicConfigStore.java @@ -145,7 +145,7 @@ public class DistributedDynamicConfigStore if (spath == null) { throw new FailedException("Invalid ResourceId, cannot create Node"); } - if (spath.equals(ResourceIdParser.ROOT) && node == null) { + if (spath.equals(ResourceIdParser.ROOT)) { return CompletableFuture.completedFuture(true); } else if (complete(keystore.get(DocumentPath.from(spath))) == null) { throw new FailedException("Node or parent does not exist for " + spath);