CDS: add backend support for local transactions 72/19072/7
authorRobert Varga <rovarga@cisco.com>
Sat, 25 Apr 2015 08:44:13 +0000 (10:44 +0200)
committerTony Tkacik <ttkacik@cisco.com>
Tue, 12 May 2015 08:30:27 +0000 (08:30 +0000)
commit0c2015c7fd5eeae79280c815b4836218929608e1
tree47599cb365764e8997076c5e16f8e586b5116bbd
parent8da5b805c9a27699677af56a8fd9926bd63909da
CDS: add backend support for local transactions

Add the message for submitting a DataTreeModification from the frontend
and the logic to apply it to the Shard's DataTree instance. This is
similar to BatchedModifications, except is is always considered ready.

The ReadyLocalTransaction is not directly serializable, but we create a
new serializer, which turns it into BatchedModifications when
serializing to byte stream.

Change-Id: I23a39c7b5997b48a355af73287d19bbf3ab0ae20
Signed-off-by: Robert Varga <rovarga@cisco.com>
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/Shard.java
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/ShardCommitCoordinator.java
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/messages/ReadyLocalTransaction.java [new file with mode: 0644]
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/messages/ReadyLocalTransactionSerializer.java [new file with mode: 0644]
opendaylight/md-sal/sal-distributed-datastore/src/main/resources/application.conf
opendaylight/md-sal/sal-distributed-datastore/src/test/java/org/opendaylight/controller/cluster/datastore/ShardTest.java
opendaylight/md-sal/sal-distributed-datastore/src/test/java/org/opendaylight/controller/cluster/datastore/messages/ReadyLocalTransactionSerializerTest.java [new file with mode: 0644]