Code Review
/
controller.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
BUG-5280: move DataTreeCandidate serialization to its own class
[controller.git]
/
opendaylight
/
md-sal
/
sal-distributed-datastore
/
src
/
main
/
java
/
org
/
opendaylight
/
controller
/
cluster
/
datastore
/
ClusterWrapperImpl.java
diff --git
a/opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/ClusterWrapperImpl.java
b/opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/ClusterWrapperImpl.java
index df0128cb56ce32e3f3deca0545915acc89c45120..56229132f34c3dec9a61ea1ea4377831f2af3274 100644
(file)
--- a/
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/ClusterWrapperImpl.java
+++ b/
opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/ClusterWrapperImpl.java
@@
-14,10
+14,11
@@
import akka.actor.Address;
import akka.cluster.Cluster;
import akka.cluster.ClusterEvent;
import com.google.common.base.Preconditions;
import akka.cluster.Cluster;
import akka.cluster.ClusterEvent;
import com.google.common.base.Preconditions;
+import org.opendaylight.controller.cluster.access.concepts.MemberName;
public class ClusterWrapperImpl implements ClusterWrapper {
private final Cluster cluster;
public class ClusterWrapperImpl implements ClusterWrapper {
private final Cluster cluster;
- private final
String
currentMemberName;
+ private final
MemberName
currentMemberName;
private final Address selfAddress;
public ClusterWrapperImpl(ActorSystem actorSystem){
private final Address selfAddress;
public ClusterWrapperImpl(ActorSystem actorSystem){
@@
-32,7
+33,7
@@
public class ClusterWrapperImpl implements ClusterWrapper {
"member-3 here would be the name of the member"
);
"member-3 here would be the name of the member"
);
- currentMemberName =
cluster.getSelfRoles().iterator().next(
);
+ currentMemberName =
MemberName.forName(cluster.getSelfRoles().iterator().next()
);
selfAddress = cluster.selfAddress();
}
selfAddress = cluster.selfAddress();
}
@@
-47,7
+48,7
@@
public class ClusterWrapperImpl implements ClusterWrapper {
}
@Override
}
@Override
- public
String
getCurrentMemberName() {
+ public
MemberName
getCurrentMemberName() {
return currentMemberName;
}
return currentMemberName;
}