Deprecate DCL in favor of DTCL 70/36970/2
authorRyan Goulding <ryandgoulding@gmail.com>
Thu, 31 Mar 2016 15:02:31 +0000 (11:02 -0400)
committerTony Tkacik <ttkacik@cisco.com>
Mon, 4 Apr 2016 08:23:18 +0000 (08:23 +0000)
The DataTreeChangeListener abstraction offers many performance and semantic
advantages over DataChangeListener.  Although there is no concrete date for DCL
removal, @Deprecated annotations are added to DCL API and impl classes to
dissuade their use.  An example of how to transition from DCL to DTCL is
included in this patch:

https://git.opendaylight.org/gerrit/#/c/35209/

Change-Id: Ie6d287224f572f157d41bf56c04b02e60ea8bf2a
Signed-off-by: Ryan Goulding <ryandgoulding@gmail.com>
opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/ClusteredDataChangeListener.java
opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataChangeListener.java
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/DataChangeListener.java

index 511910de62c417e90df9c5ea0b59a5493f427e74..d9f0e085513c13e7edf55510e6b8e9f54b2c994a 100644 (file)
@@ -19,7 +19,8 @@ package org.opendaylight.controller.md.sal.binding.api;
  * to data change notifications on any node of clustered datastore. DataChangeListener enables data change notifications
  * only at leader of the datastore shard.</p>
  *
+ * @Deprecated Replaced by {@link ClusteredDataTreeChangeListener}
  */
-
+@Deprecated
 public interface ClusteredDataChangeListener extends DataChangeListener{
 }
index 2833f41f6762be6cdc01ba752910feeb4749568a..f6a13a3a79f6ffa3be16be339e69b1b279f33032 100644 (file)
@@ -14,8 +14,10 @@ import org.opendaylight.yangtools.yang.binding.InstanceIdentifier;
 
 /*
  * DataChangeListener enables data change notifications only at leader of the datastore shard
+ *
+ * @Deprecated Replaced by {@link DataTreeChangeListener}
  */
-
+@Deprecated
 public interface DataChangeListener extends AsyncDataChangeListener<InstanceIdentifier<?>, DataObject> {
     @Override
     void onDataChanged(AsyncDataChangeEvent<InstanceIdentifier<?>, DataObject> change);
index 1bc835f1e3c6883196d4a9a6b1f334bb16f9dca7..cf3bdce331b21d5a3e2b9257cb809f3d87948567 100644 (file)
@@ -22,6 +22,10 @@ import org.opendaylight.yangtools.yang.data.api.schema.NormalizedNode;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
+/**
+ * @Deprecated Replaced by {@link DataTreeChangeListener}
+ */
+@Deprecated
 public class DataChangeListener extends AbstractUntypedActor {
     private static final Logger LOG = LoggerFactory.getLogger(DataChangeListener.class);