Follow-up to protobuff deprecation 38/34638/11
authorRobert Varga <rovarga@cisco.com>
Sun, 14 Feb 2016 22:34:49 +0000 (23:34 +0100)
committerGerrit Code Review <gerrit@opendaylight.org>
Wed, 17 Feb 2016 10:28:59 +0000 (10:28 +0000)
Mark elements dealing with compatibility as @Deprecated. Reduces the
warning surface significantly.

Change-Id: I969c7b185cf6fbf570fe4d4d0332cff60eb0e4ca
Signed-off-by: Robert Varga <rovarga@cisco.com>
14 files changed:
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/messages/AbortTransaction.java
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/messages/AbortTransactionReply.java
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/messages/CanCommitTransaction.java
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/messages/CanCommitTransactionReply.java
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/messages/CloseTransaction.java
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/messages/CloseTransactionChain.java
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/messages/CommitTransaction.java
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/messages/CommitTransactionReply.java
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/messages/CreateTransaction.java
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/messages/CreateTransactionReply.java
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/messages/DataExists.java
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/messages/DataExistsReply.java
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/messages/ReadData.java
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/messages/VersionedExternalizableMessage.java

index e70ced8..ed4519b 100644 (file)
@@ -21,6 +21,7 @@ public class AbortTransaction extends AbstractThreePhaseCommitMessage {
         super(transactionID, version);
     }
 
+    @Deprecated
     @Override
     protected Object newLegacySerializedInstance() {
         return ThreePhaseCommitCohortMessages.AbortTransaction.newBuilder().
index ac65b5b..398f253 100644 (file)
@@ -12,6 +12,7 @@ import org.opendaylight.controller.cluster.datastore.DataStoreVersions;
 import org.opendaylight.controller.protobuff.messages.cohort3pc.ThreePhaseCommitCohortMessages;
 
 public class AbortTransactionReply extends VersionedExternalizableMessage {
+    @Deprecated
     private static final Object SERIALIZED_INSTANCE =
             ThreePhaseCommitCohortMessages.AbortTransactionReply.newBuilder().build();
 
@@ -24,6 +25,7 @@ public class AbortTransactionReply extends VersionedExternalizableMessage {
         super(version);
     }
 
+    @Deprecated
     @Override
     protected Object newLegacySerializedInstance() {
         return SERIALIZED_INSTANCE;
index 4aff686..e0bf448 100644 (file)
@@ -21,6 +21,7 @@ public class CanCommitTransaction extends AbstractThreePhaseCommitMessage {
         super(transactionID, version);
     }
 
+    @Deprecated
     @Override
     protected Object newLegacySerializedInstance() {
         return ThreePhaseCommitCohortMessages.CanCommitTransaction.newBuilder().
index d2cf5fd..6b88b96 100644 (file)
@@ -20,9 +20,11 @@ public class CanCommitTransactionReply extends VersionedExternalizableMessage {
     private static final CanCommitTransactionReply NO =
             new CanCommitTransactionReply(false, DataStoreVersions.CURRENT_VERSION);
 
+    @Deprecated
     private static final ThreePhaseCommitCohortMessages.CanCommitTransactionReply YES_SERIALIZED =
             ThreePhaseCommitCohortMessages.CanCommitTransactionReply.newBuilder().setCanCommit(true).build();
 
+    @Deprecated
     private static final ThreePhaseCommitCohortMessages.CanCommitTransactionReply NO_SERIALIZED =
             ThreePhaseCommitCohortMessages.CanCommitTransactionReply.newBuilder().setCanCommit(false).build();
 
@@ -52,6 +54,7 @@ public class CanCommitTransactionReply extends VersionedExternalizableMessage {
         out.writeBoolean(canCommit);
     }
 
+    @Deprecated
     @Override
     protected Object newLegacySerializedInstance() {
         return canCommit ? YES_SERIALIZED : NO_SERIALIZED;
index 69deff4..8cf5002 100644 (file)
@@ -13,6 +13,7 @@ import org.opendaylight.controller.protobuff.messages.transaction.ShardTransacti
 public class CloseTransaction extends VersionedExternalizableMessage {
     private static final long serialVersionUID = 1L;
 
+    @Deprecated
     private static final Object SERIALIZED_INSTANCE =
             ShardTransactionMessages.CloseTransaction.newBuilder().build();
 
@@ -23,6 +24,7 @@ public class CloseTransaction extends VersionedExternalizableMessage {
         super(version);
     }
 
+    @Deprecated
     @Override
     protected Object newLegacySerializedInstance() {
         return SERIALIZED_INSTANCE;
index f49394a..b93f94e 100644 (file)
@@ -43,6 +43,7 @@ public class CloseTransactionChain extends VersionedExternalizableMessage {
         out.writeUTF(transactionChainId);
     }
 
+    @Deprecated
     @Override
     protected Object newLegacySerializedInstance() {
         return ShardTransactionChainMessages.CloseTransactionChain.newBuilder().setTransactionChainId(transactionChainId)
index 495a00a..52ab643 100644 (file)
@@ -21,6 +21,7 @@ public class CommitTransaction extends AbstractThreePhaseCommitMessage {
         super(transactionID, version);
     }
 
+    @Deprecated
     @Override
     protected Object newLegacySerializedInstance() {
         return ThreePhaseCommitCohortMessages.CommitTransaction.newBuilder().setTransactionId(
index 4207cd5..b50bbcc 100644 (file)
@@ -12,6 +12,7 @@ import org.opendaylight.controller.cluster.datastore.DataStoreVersions;
 import org.opendaylight.controller.protobuff.messages.cohort3pc.ThreePhaseCommitCohortMessages;
 
 public class CommitTransactionReply extends VersionedExternalizableMessage {
+    @Deprecated
     private static final Object SERIALIZED_INSTANCE =
             ThreePhaseCommitCohortMessages.CommitTransactionReply.newBuilder().build();
 
@@ -24,6 +25,7 @@ public class CommitTransactionReply extends VersionedExternalizableMessage {
         super(version);
     }
 
+    @Deprecated
     @Override
     protected Object newLegacySerializedInstance() {
         return SERIALIZED_INSTANCE;
index cd94795..bad7cfa 100644 (file)
@@ -60,6 +60,7 @@ public class CreateTransaction extends VersionedExternalizableMessage {
         out.writeUTF(transactionChainId);
     }
 
+    @Deprecated
     @Override
     protected Object newLegacySerializedInstance() {
         return ShardTransactionMessages.CreateTransaction.newBuilder().setTransactionId(transactionId)
index 634d049..73b33d7 100644 (file)
@@ -50,6 +50,7 @@ public class CreateTransactionReply extends VersionedExternalizableMessage {
         out.writeUTF(transactionPath);
     }
 
+    @Deprecated
     @Override
     protected Object newLegacySerializedInstance() {
         return ShardTransactionMessages.CreateTransactionReply.newBuilder().setTransactionActorPath(transactionPath)
index 7eab816..b24b51b 100644 (file)
@@ -17,8 +17,10 @@ import org.opendaylight.controller.protobuff.messages.transaction.ShardTransacti
 public class DataExistsReply extends VersionedExternalizableMessage {
     private static final long serialVersionUID = 1L;
 
+    @Deprecated
     private static final ShardTransactionMessages.DataExistsReply SERIALIZABLE_TRUE =
             ShardTransactionMessages.DataExistsReply.newBuilder().setExists(true).build();
+    @Deprecated
     private static final ShardTransactionMessages.DataExistsReply SERIALIZABLE_FALSE =
             ShardTransactionMessages.DataExistsReply.newBuilder().setExists(false).build();
 
@@ -48,6 +50,7 @@ public class DataExistsReply extends VersionedExternalizableMessage {
         out.writeBoolean(exists);
     }
 
+    @Deprecated
     @Override
     protected Object newLegacySerializedInstance() {
         return exists ? SERIALIZABLE_TRUE : SERIALIZABLE_FALSE;
index 7837493..6a01f28 100644 (file)
@@ -29,6 +29,7 @@ public class ReadData extends AbstractRead<Optional<NormalizedNode<?, ?>>> {
         super(path, version);
     }
 
+    @Deprecated
     @Override
     protected Object newLegacySerializedInstance() {
         return ShardTransactionMessages.ReadData.newBuilder()

©2013 OpenDaylight, A Linux Foundation Collaborative Project. All Rights Reserved.
OpenDaylight is a registered trademark of The OpenDaylight Project, Inc.
Linux Foundation and OpenDaylight are registered trademarks of the Linux Foundation.
Linux is a registered trademark of Linus Torvalds.