BUG-650: improve transaction chaining performance 22/11122/2
authorRobert Varga <rovarga@cisco.com>
Fri, 12 Sep 2014 18:21:53 +0000 (20:21 +0200)
committerRobert Varga <rovarga@cisco.com>
Sat, 13 Sep 2014 00:49:59 +0000 (02:49 +0200)
commit33a59cd45d752e6d5a0b128307a18aa9020373c0
tree292533986d1050d0bcadf793e44abaaad2c616a0
parent5dd146fbce23afe3ed800484959601940856b19f
BUG-650: improve transaction chaining performance

Transaction chaining has mucked inside SnapshotBackedWriteTransaction to
get its state everytime a new transaction was allocated. Instead we
expose proper lifecycle hooks, so the chain handling logic can keep
track of state itself.

As an added feature, this fixes a bug, where a chain would become
unusable if the user closed a write transaction without actually calling
ready() on it.

Finally it fixes a synchronization bug, where a commit task would not be
properly synchronized with listener registrations.

Change-Id: Iebe4701f1712a95a9316ea8380fe12c8c5fe6b89
Signed-off-by: Robert Varga <rovarga@cisco.com>
opendaylight/md-sal/sal-inmemory-datastore/src/main/java/org/opendaylight/controller/md/sal/dom/store/impl/InMemoryDOMDataStore.java
opendaylight/md-sal/sal-inmemory-datastore/src/main/java/org/opendaylight/controller/md/sal/dom/store/impl/SnapshotBackedWriteTransaction.java