better mehtod name
This commit is contained in:
parent
965d7303cf
commit
51656552a5
|
@ -91,7 +91,7 @@ public class MutableShardRouting extends ImmutableShardRouting {
|
|||
primary = true;
|
||||
}
|
||||
|
||||
public void moveToBackup() {
|
||||
public void moveFromPrimary() {
|
||||
if (!primary) {
|
||||
throw new IllegalShardRoutingStateException(this, "Already primary, can't move to backup");
|
||||
}
|
||||
|
|
|
@ -189,7 +189,7 @@ public class ShardsRoutingStrategy extends AbstractComponent {
|
|||
assert !shardEntry2.primary();
|
||||
|
||||
changed = true;
|
||||
shardEntry.moveToBackup();
|
||||
shardEntry.moveFromPrimary();
|
||||
shardEntry2.moveToPrimary();
|
||||
elected = true;
|
||||
break;
|
||||
|
|
Loading…
Reference in New Issue