Clarify DistributedDataStoreFactory 26/14426/1
authorRobert Varga <rovarga@cisco.com>
Fri, 23 Jan 2015 10:31:14 +0000 (11:31 +0100)
committerRobert Varga <rovarga@cisco.com>
Fri, 23 Jan 2015 11:13:51 +0000 (12:13 +0100)
commit00ceab3367dcacf1e39d84a977301fc7b81118dd
tree0dc5e43f8fbddc5389df36251bb20bdd7023af42
parent0b0ff8298bf54c54573c5758bd32b10516386e21
Clarify DistributedDataStoreFactory

DistributedDataStoreFactory used an atomic reference to manage a lazy
initialization of a singleton, which could fail to initialize. Use an
explicit volatile and lower synchronization requirements when the
singleton has already been initialized.

Change-Id: I10c38ca2441c6e7d8251560f9ea1218211490fc9
Signed-off-by: Robert Varga <rovarga@cisco.com>
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/DistributedDataStoreFactory.java