address PR comments
This commit is contained in:
parent
fb69e15d1d
commit
a7b90591bc
1 changed files with 1 additions and 4 deletions
|
@ -59,10 +59,7 @@ func (c *Client) SLADrainHosts(policy *aurora.SlaPolicy, timeout int64, hosts ..
|
|||
return nil, errors.New("no hosts provided to drain")
|
||||
}
|
||||
|
||||
if policy == nil ||
|
||||
(policy.PercentageSlaPolicy == nil &&
|
||||
policy.CountSlaPolicy == nil &&
|
||||
policy.CoordinatorSlaPolicy == nil) {
|
||||
if policy == nil || policy.CountSetFieldsSlaPolicy() == 0 {
|
||||
policy = &defaultSlaPolicy
|
||||
c.logger.Printf("Warning: start draining with default sla policy %v", policy)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue