Skip to content

Commit

Permalink
if there is slot migrating, proxy online should be allowed
Browse files Browse the repository at this point in the history
  • Loading branch information
yangzhe1991 committed Aug 26, 2015
1 parent 0c6d4f1 commit 21044af
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkg/models/proxy.go
Original file line number Diff line number Diff line change
Expand Up @@ -160,8 +160,8 @@ func SetProxyStatus(zkConn zkhelper.Conn, productName string, proxyName string,
return errors.Trace(err)
}
for _, slot := range slots {
if slot.State.Status != SLOT_STATUS_ONLINE {
return errors.Errorf("slot %v is not online", slot)
if slot.State.Status != SLOT_STATUS_ONLINE && slot.State.Status != SLOT_STATUS_MIGRATE{
return errors.Errorf("slot %v is not online or migrate", slot)
}
if slot.GroupId == INVALID_ID {
return errors.Errorf("slot %v has invalid group id", slot)
Expand Down

0 comments on commit 21044af

Please sign in to comment.