Modify config Module impls to co-exist with blueprint
[controller.git] / opendaylight / md-sal / sal-distributed-datastore / src / main / java / org / opendaylight / controller / config / yang / config / cluster_admin_provider / ClusterAdminProviderModule.java
index 0d96368f1c68a0f22a6324303b4fb8dbb682ce72..facc07f11d121044a8c8d5d1299f95d38d315bad 100644 (file)
@@ -9,7 +9,7 @@
 package org.opendaylight.controller.config.yang.config.cluster_admin_provider;
 
 import com.google.common.base.Preconditions;
-import org.opendaylight.controller.cluster.datastore.DistributedDataStore;
+import org.opendaylight.controller.cluster.datastore.DistributedDataStoreInterface;
 import org.opendaylight.controller.cluster.datastore.admin.ClusterAdminRpcService;
 import org.opendaylight.controller.config.api.DependencyResolver;
 import org.opendaylight.controller.config.api.ModuleIdentifier;
@@ -31,13 +31,14 @@ public class ClusterAdminProviderModule extends AbstractClusterAdminProviderModu
 
     @Override
     public AutoCloseable createInstance() {
-        Preconditions.checkArgument(getConfigDataStoreDependency() instanceof DistributedDataStore,
-                "Injected config DOMStore must be an instance of DistributedDataStore");
-        Preconditions.checkArgument(getOperDataStoreDependency() instanceof DistributedDataStore,
-                "Injected operational DOMStore must be an instance of DistributedDataStore");
-        ClusterAdminRpcService service = new ClusterAdminRpcService((DistributedDataStore)getConfigDataStoreDependency(),
-                (DistributedDataStore)getOperDataStoreDependency());
+        Preconditions.checkArgument(getConfigDataStoreDependency() instanceof DistributedDataStoreInterface,
+                "Injected config DOMStore must be an instance of DistributedDataStoreInterface");
+        Preconditions.checkArgument(getOperDataStoreDependency() instanceof DistributedDataStoreInterface,
+                "Injected operational DOMStore must be an instance of DistributedDataStoreInterface");
+        ClusterAdminRpcService service = new ClusterAdminRpcService(
+                (DistributedDataStoreInterface)getConfigDataStoreDependency(),
+                (DistributedDataStoreInterface)getOperDataStoreDependency());
         service.start(getRpcRegistryDependency());
         return service;
     }
-}
+}
\ No newline at end of file