[ https://issues.apache.org/jira/browse/ZOOKEEPER-2680?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15853154#comment-15853154 ]
Hudson commented on ZOOKEEPER-2680: ----------------------------------- FAILURE: Integrated in Jenkins build ZooKeeper-trunk #3263 (See [https://builds.apache.org/job/ZooKeeper-trunk/3263/]) ZOOKEEPER-2680: Correct DataNode.getChildren() inconsistent behaviour. (hanm: rev 26aee2228451257f3b0b5093bc0c101822e06bc8) * (edit) src/java/main/org/apache/zookeeper/server/DataNode.java * (edit) src/java/main/org/apache/zookeeper/server/SnapshotFormatter.java * (add) src/java/test/org/apache/zookeeper/server/DataNodeTest.java * (edit) src/java/main/org/apache/zookeeper/server/DataTree.java * (edit) src/java/main/org/apache/zookeeper/server/ContainerManager.java * (edit) src/java/main/org/apache/zookeeper/server/PrepRequestProcessor.java > Correct DataNode.getChildren() inconsistent behaviour. > ------------------------------------------------------ > > Key: ZOOKEEPER-2680 > URL: https://issues.apache.org/jira/browse/ZOOKEEPER-2680 > Project: ZooKeeper > Issue Type: Bug > Components: server > Affects Versions: 3.4.9, 3.5.1 > Reporter: Mohammad Arshad > Assignee: Mohammad Arshad > Fix For: 3.4.10, 3.5.3, 3.6.0 > > Attachments: ZOOKEEPER-2680-01.patch > > > DataNode.getChildren() API returns null and empty set if there are no > children in it depending on when the API is called. DataNode.getChildren() > API behavior should be changed and it should always return empty set if the > node does not have any child > *DataNode.getChildren() API Current Behavior:* > # returns null initially > When DataNode is created and no children are added yet, > DataNode.getChildren() returns null > # returns empty set after all the children are deleted: > created a Node > add a child > delete the child > DataNode.getChildren() returns empty set. > After fix DataNode.getChildren() should return empty set in all the above > cases. -- This message was sent by Atlassian JIRA (v6.3.15#6346)