X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=opendaylight%2Fmd-sal%2Fsal-distributed-datastore%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fcluster%2Fdatastore%2FShardManager.java;h=e51d49bff2aff8b6380081e0e772765d172246b0;hb=67d58d1ab50f3c3bbe19a96fb6f0d9d94211829f;hp=186f2cff41351a97f9d1852396a149047bd345cc;hpb=287b1d1ecec3264c192b1007019bfcadf6cb4311;p=controller.git diff --git a/opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/ShardManager.java b/opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/ShardManager.java index 186f2cff41..e51d49bff2 100644 --- a/opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/ShardManager.java +++ b/opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/ShardManager.java @@ -72,19 +72,19 @@ public class ShardManager extends AbstractUntypedActor { private ShardManagerInfoMBean mBean; - private final ShardContext shardContext; + private final DatastoreContext datastoreContext; /** * @param type defines the kind of data that goes into shards created by this shard manager. Examples of type would be * configuration or operational */ private ShardManager(String type, ClusterWrapper cluster, Configuration configuration, - ShardContext shardContext) { + DatastoreContext datastoreContext) { this.type = Preconditions.checkNotNull(type, "type should not be null"); this.cluster = Preconditions.checkNotNull(cluster, "cluster should not be null"); this.configuration = Preconditions.checkNotNull(configuration, "configuration should not be null"); - this.shardContext = shardContext; + this.datastoreContext = datastoreContext; // Subscribe this actor to cluster member events cluster.subscribeToMemberEvents(getSelf()); @@ -97,13 +97,13 @@ public class ShardManager extends AbstractUntypedActor { public static Props props(final String type, final ClusterWrapper cluster, final Configuration configuration, - final ShardContext shardContext) { + final DatastoreContext datastoreContext) { Preconditions.checkNotNull(type, "type should not be null"); Preconditions.checkNotNull(cluster, "cluster should not be null"); Preconditions.checkNotNull(configuration, "configuration should not be null"); - return Props.create(new ShardManagerCreator(type, cluster, configuration, shardContext)); + return Props.create(new ShardManagerCreator(type, cluster, configuration, datastoreContext)); } @Override @@ -245,7 +245,7 @@ public class ShardManager extends AbstractUntypedActor { ShardIdentifier shardId = getShardIdentifier(memberName, shardName); Map peerAddresses = getPeerAddresses(shardName); ActorRef actor = getContext() - .actorOf(Shard.props(shardId, peerAddresses, shardContext). + .actorOf(Shard.props(shardId, peerAddresses, datastoreContext). withMailbox(ActorContext.MAILBOX), shardId.toString()); localShardActorNames.add(shardId.toString()); @@ -354,19 +354,19 @@ public class ShardManager extends AbstractUntypedActor { final String type; final ClusterWrapper cluster; final Configuration configuration; - final ShardContext shardContext; + final DatastoreContext datastoreContext; ShardManagerCreator(String type, ClusterWrapper cluster, - Configuration configuration, ShardContext shardContext) { + Configuration configuration, DatastoreContext datastoreContext) { this.type = type; this.cluster = cluster; this.configuration = configuration; - this.shardContext = shardContext; + this.datastoreContext = datastoreContext; } @Override public ShardManager create() throws Exception { - return new ShardManager(type, cluster, configuration, shardContext); + return new ShardManager(type, cluster, configuration, datastoreContext); } } }