Handle UNMODIFIED type in DataTreeCandidateInputOutput 35/50535/1
authorTom Pantelis <tpanteli@brocade.com>
Tue, 17 Jan 2017 09:23:02 +0000 (04:23 -0500)
committerTom Pantelis <tpanteli@brocade.com>
Tue, 17 Jan 2017 09:33:17 +0000 (04:33 -0500)
commit875679ec8a3aea94478ff2a106e4f9cb4f5fc884
tree569d5f3b8dad69c3b54981a9dc903f53d7e01792
parent8438f3659c2b70ecb66af27684781b34bcfa328f
Handle UNMODIFIED type in DataTreeCandidateInputOutput

We now replicate DataTreeCandidates with root node type UNMODIFIED
however the deserialization in DataTreeCandidateInputOutput throws
an ISE with "Unhandled node type 2". The writeDataTreeCandidate
method writes the UNMODIFIED type but readDataTreeCandidate needs
to handle that case as well.

In addition, writeDataTreeCandidate also handles APPEARED and
DISAPPEARED but readDataTreeCandidate does not so I made that
change as well.

Change-Id: I19932e545bbeb95fa10d5f57d43a5780af586285
Signed-off-by: Tom Pantelis <tpanteli@brocade.com>
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/persisted/DataTreeCandidateInputOutput.java
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/persisted/ModifiedDataTreeCandidateNode.java
opendaylight/md-sal/sal-distributed-datastore/src/test/java/org/opendaylight/controller/cluster/datastore/persisted/CommitTransactionPayloadTest.java